H3D API  2.4.1
Public Member Functions | Public Attributes | List of all members
H3D::X3DFogObject Class Reference

X3DFogObject is the abstract type that describes a node that influences the lighting equation through the use of fog semantics. More...

#include <H3D/X3DFogObject.h>

Inheritance diagram for H3D::X3DFogObject:
Inheritance graph

Public Member Functions

 X3DFogObject (Inst< SFColor > _color=0, Inst< SFString > _fogType=0, Inst< SFFloat > _visibilityRange=0)
 Constructor.
 

Public Attributes

H3DUniquePtr< SFColorcolor
 The color of the fog. More...
 
H3DUniquePtr< SFStringfogType
 The fogType field controls how much of the fog colour is blended with the object as a function of distance. More...
 
H3DUniquePtr< SFFloatvisibilityRange
 The visibilityRange specifies the distance in metres (in the local coordinate system) at which objects are totally obscured by the fog. More...
 

Detailed Description

X3DFogObject is the abstract type that describes a node that influences the lighting equation through the use of fog semantics.


Member Data Documentation

◆ color

H3DUniquePtr< SFColor > H3D::X3DFogObject::color

The color of the fog.

Access type: inputOutput
Default value: 1 1 1

Referenced by H3D::LocalFog::enableGraphicsState(), H3D::Fog::renderFog(), and X3DFogObject().

◆ fogType

H3DUniquePtr< SFString > H3D::X3DFogObject::fogType

The fogType field controls how much of the fog colour is blended with the object as a function of distance.

If fogType is "LINEAR", the amount of blending is a linear function of the distance, resulting in a depth cueing effect. If fogType is "EXPONENTIAL," an exponential increase in blending is used, resulting in a more natural fog appearance.

Access type: inputOutput
Default value: "LINEAR"
Valid values: "LINEAR" | "EXPONENTIAL"

Referenced by H3D::LocalFog::enableGraphicsState(), H3D::Fog::renderFog(), and X3DFogObject().

◆ visibilityRange

H3DUniquePtr< SFFloat > H3D::X3DFogObject::visibilityRange

The visibilityRange specifies the distance in metres (in the local coordinate system) at which objects are totally obscured by the fog.

Objects located outside the visibilityRange from the viewer are drawn with a constant colour of color. Objects very close to the viewer are blended very little with the fog color. A visibilityRange of 0.0 disables the fog.

Access type: inputOutput
Default value: 0

Referenced by H3D::LocalFog::enableGraphicsState(), and H3D::Fog::renderFog().


The documentation for this class was generated from the following files: