Class FogSpaceComponent
Defined in File FogSpaceComponent.h
Inheritance Relationships
Base Types
public csp::multiplayer::ComponentBase(Class ComponentBase)public csp::multiplayer::IThirdPartyComponentRef(Class IThirdPartyComponentRef)public csp::multiplayer::ITransformComponent(Class ITransformComponent)public csp::multiplayer::IVisibleComponent(Class IVisibleComponent)
Class Documentation
-
class FogSpaceComponent : public csp::multiplayer::ComponentBase, public csp::multiplayer::IThirdPartyComponentRef, public csp::multiplayer::ITransformComponent, public csp::multiplayer::IVisibleComponent
Add a depth-based fog volume to your space.
Public Functions
-
FogSpaceComponent(csp::common::LogSystem *LogSystem, SpaceEntity *Parent)
Constructs the fog space component, and associates it with the specified Parent space entity.
- Parameters
Parent – The Space entity that owns this component.
-
FogMode GetFogMode() const
Retrieves the type of fog currently used by this fog component.
- Returns
The modality of fog currently used by this component.
-
void SetFogMode(FogMode Value)
Sets the type of fog to be used by this fog component.
- Parameters
Value – The modality of fog to be used by this component.
-
float GetStartDistance() const
Gets start distance.
Note
Distance from camera that the fog will start. 0 = this property has no effect.
- Returns
Current start distance.
-
void SetStartDistance(float Value)
Sets start distance.
Note
Distance from camera that the fog will start. 0 = this property has no effect.
- Parameters
Value – float : Start distance.
-
float GetEndDistance() const
Gets end distance.
Note
Objects passed this distance will not be affected by fog. 0 = this property has no effect.
- Returns
Current end distance.
-
void SetEndDistance(float Value)
Sets end distance.
Note
Objects passed this distance will not be affected by fog. 0 = this property has no effect.
- Parameters
Value – float : End distance.
-
void SetColor(const csp::common::Vector3 &Value)
Sets fog color.
- Parameters
Value – Vector3 : Fog color.
-
float GetDensity() const
Gets global density factor.
- Returns
Current global density factor.
-
void SetDensity(float Value)
Sets global density factor.
- Parameters
Value – float : Global density factor.
-
float GetHeightFalloff() const
Gets Height density factor.
Note
Controls how the density increases and height decreases. Smaller values make the visible transition larger.
- Returns
Current height density factor.
-
void SetHeightFalloff(float Value)
Sets Height density factor.
Note
Controls how the density increases and height decreases. Smaller values make the visible transition larger.
- Parameters
Value – float : Height density factor.
-
float GetMaxOpacity() const
Gets maximum opacity of the fog.
Note
1 = fog becomes fully opaque at a distance and replaces the scene colour completely. 0 = fog colour will have no impact.
- Returns
Current maximum opacity.
-
void SetMaxOpacity(float Value)
Sets maximum opacity of the fog.
Note
1 = fog becomes fully opaque at a distance and replaces the scene colour completely. 0 = fog colour will have no impact.
- Parameters
Value – float : Maximum opacity of the fog.
-
bool GetIsVolumetric() const
Gets IsFogVolumetric.
- Returns
Current fog volumetric flag.
-
void SetIsVolumetric(bool Value)
Sets IsFogVolumetric.
- Parameters
Value – boolean : Fog Volumetric Flag.
-
FogSpaceComponent(csp::common::LogSystem *LogSystem, SpaceEntity *Parent)