Rendering settings (engine-only)

Does anyone know how to access these settings in code (from the Render section of the settings in the editor)?

Screen Shot 2021-04-12 at 2.25.15 PM

They are the properties of a scene (API). You can find your scenes under this.app.scenes (API).

1 Like

And you can access the active scene like this:

// changing the scene exposure
this.app.scene.exposure = 2.0;
1 Like

Interesting. In the API, it looks like gammaCorrection can be one of two constants: GAMMA_NONE or GAMMA_SRGB. But then if you click on GAMMA_NONE, you can find two other constants listed in addition to the first two: GAMMA_SRGBFAST and GAMMA_SRGBHDR. Is there a reason only two are available in the Editor? Thanks for the help, as always.

Good point, I think the other two are used automatically by the engine when image based lighting is used, I may be wrong though.

@mvaligursky do you know why?

Not too sure, I’ve noticed that few days ago as well. The FAST version is deprecated, so that’s why it’s not exposed, but not sure about the HDR one - we wanted to investigate that but didn’t get to it … It might not be completely functional.

1 Like