The settings that affect the environment in which a scene is displayed. More...
| Header | #include <Scene |
| Since | Esri |
| Inherits | Esri |
Public Functions
| Scene | |
| Scene | |
| virtual | ~ |
| bool | are |
| QColor | background |
| bool | is |
| Esri | lighting() const |
| void | set |
| void | set |
| void | set |
| void | set |
Detailed Description
This includes rendering of the atmosphere effect, stars, and background color. If all three of these effects are set, they are rendered in the following order: background color, stars, then atmosphere.
Some scene environment effects will change depending on the position of the camera relative to the surface. Atmosphere effect is disabled when too far from the surface. Lighting and shadows are most accurate when closer to the surface and are disabled further from the surface.
Relevant samples:
- Configure scene environment: Configure the environment settings in a local scene to change the lighting conditions and background appearance.
See also Scene::environment.
Member Function Documentation
[explicit] SceneEnvironment::SceneEnvironment (QObject *parent = nullptr)
Creates a default environment object.
- parent - The optional parent QObject.
The defaults are: opaque black background, VirtualLighting lighting, and atmosphere and stars enabled.
SceneEnvironment::SceneEnvironment (bool isAtmosphereEnabled , bool areStarsEnabled , Esri::ArcGISRuntime::SceneLighting *lighting, const QColor &backgroundColor , QObject *parent = nullptr)
Creates an environment object.
- isAtmosphereEnabled -
trueif the atmosphere should be visualized,falseotherwise. This includes sky and haze effects. - areStarsEnabled -
trueif stars should be visualized,falseotherwise. - lighting - The lighting object containing information on how the scene is lit.
- backgroundColor - The background color displayed behind any scene objects.
- parent - The optional parent QObject.
[override virtual noexcept] SceneEnvironment::~SceneEnvironment ()
Destructor.
bool SceneEnvironment::areStarsEnabled () const
Returns true if stars should be visualized, false otherwise.
QColor SceneEnvironment::backgroundColor () const
Returns the color of the background that is displayed behind any scene objects.
See also setBackgroundColor().
bool SceneEnvironment::isAtmosphereEnabled () const
Returns true if the atmosphere should be visualized, false otherwise. This includes sky and haze effects.
Esri::ArcGISRuntime::SceneLighting *SceneEnvironment::lighting() const
Returns the lighting object that controls how the scene is lit.
See also setLighting().
void SceneEnvironment::setAtmosphereEnabled (bool atmosphereEnabled )
Sets the atmosphereEnabled to atmosphereEnabled.
See also isAtmosphereEnabled.
void SceneEnvironment::setBackgroundColor (const QColor &backgroundColor )
Sets the backgroundColor to backgroundColor.
See also backgroundColor.
void SceneEnvironment::setLighting (Esri::ArcGISRuntime::SceneLighting *lighting)
Sets the lighting to lighting.
See also lighting.
void SceneEnvironment::setStarsEnabled (bool areStarsEnabled )
Sets the areStarsEnabled to areStarsEnabled.
See also areStarsEnabled.