CascadeStudio icon indicating copy to clipboard operation
CascadeStudio copied to clipboard

Scene - Edit Defaults

Open kmavridis opened this issue 3 years ago • 1 comments

Hello, how can i remove fog from the scene, add more light to it and make bigger the view frustum so my whole model to be visible?

Thank you in advanced

kmavridis avatar Dec 18 '21 10:12 kmavridis

I agree that the settings of the fog are not always ideal. It depends on the size of your object, but if the size of your object becomes too large the fog will cover smaller parts.

fog-cs

To change this you would have to download install the code locally on your computer as described in https://github.com/raydeleu/CascadeStudioManual#22-local-installation

In https://github.com/raydeleu/CascadeStudioManual#133-modifying-the-3d-view I have described how you can change some default values of the 3D window. I guess you would need to tinker around in the code of https://github.com/zalo/CascadeStudio/blob/master/js/MainPage/CascadeView.js to see what the effect is. The following lines describe some of the behaviour of the fog in the scene.


    // Expand fog distance to enclose the current object; always expand
    //  otherwise you can lose the object if it gets smaller again)
    this.boundingBox = new THREE.Box3().setFromObject(this.mainObject);
    this.fogDist = Math.max(this.fogDist, this.boundingBox.min.distanceTo(this.boundingBox.max)*1.5);
    this.environment.scene.fog = new THREE.Fog(this.environment.backgroundColor, this.fogDist, this.fogDist + 400);

Recently there was a change to the code that allows to remove the grid and the ground plane from the scene. Perhaps the author https://github.com/drb3st could add this option to the interface as well?

raydeleu avatar Jun 11 '22 23:06 raydeleu