LuciadCPillar 2026.1.01
Loading...
Searching...
No Matches
luciad::AtmosphereEffect Class Referencefinal

Graphics effect which adds a sky/atmosphere background to a 3D view. More...

#include <luciad/maps/effects/AtmosphereEffect.h>

Public Member Functions

 AtmosphereEffect (const AtmosphereEffect &)=delete
const std::shared_ptr< AtmosphereModel > & getModel () const
 Returns the atmosphere model.
bool isEnabled () const
 Returns whether the atmosphere effect is enabled.
AtmosphereEffect & operator= (const AtmosphereEffect &)=delete
void setEnabled (bool enabled)
 Sets whether the atmosphere effect is enabled.
void setModel (std::shared_ptr< AtmosphereModel > model)
 Sets the atmosphere model.

Detailed Description

Graphics effect which adds a sky/atmosphere background to a 3D view.

The effect is enabled by default, but it is only applied to a 3D view. On a 2D view it has no visible effect.

The atmosphere is described by an immutable luciad::AtmosphereModel, of which there are two:

Gradient model (the default) on the left, physically based scattering model on the right
Scattering seen from space: aerial perspective disabled on the left, enabled on the right

The atmosphere describes the planet's sky and, optionally, tints distant terrain so it fades into the sky with distance (an effect known as aerial perspective). That tinting is physically derived from the sun position and the air, so it is realistic but not directly adjustable. If you want to control haze yourself, and set its color and the distance at which things fade from view, use FogEffect instead. See the map effects article for guidance on choosing between the two.

Read the active model with getModel and narrow it to its concrete type, and change it by building a new model and passing it to setModel.

You cannot create an AtmosphereEffect. Instead, you can retrieve it from luciad::GraphicsEffects::getAtmosphere.

Since
2023.1

Constructor & Destructor Documentation

◆ AtmosphereEffect()

luciad::AtmosphereEffect::AtmosphereEffect ( const AtmosphereEffect & )
delete

Member Function Documentation

◆ getModel()

const std::shared_ptr< AtmosphereModel > & luciad::AtmosphereEffect::getModel ( ) const

Returns the atmosphere model.

Returns
the atmosphere model.
Since
2026.1

◆ isEnabled()

bool luciad::AtmosphereEffect::isEnabled ( ) const

Returns whether the atmosphere effect is enabled.

Returns
whether the atmosphere effect is enabled.

◆ operator=()

AtmosphereEffect & luciad::AtmosphereEffect::operator= ( const AtmosphereEffect & )
delete

◆ setEnabled()

void luciad::AtmosphereEffect::setEnabled ( bool enabled)

Sets whether the atmosphere effect is enabled.

The default is true.

Parameters
enabledtrue to enable the atmosphere effect or false to disable it.

◆ setModel()

void luciad::AtmosphereEffect::setModel ( std::shared_ptr< AtmosphereModel > model)

Sets the atmosphere model.

The default is a luciad::GradientAtmosphereModel with default parameters.

Parameters
modelthe atmosphere model.
Exceptions
luciad::NullArgumentExceptionwhen the model is a nullptr value.
Since
2026.1