Class Fog
A fog filter.
[DataContract("Fog")]
public class Fog : ImageEffect, IComponent, IReferencable, ICollectorHolder, IImageEffect, IGraphicsRenderer, IGraphicsRendererBase, IGraphicsRendererCore, IDisposable
- Inheritance
-
Fog
- Implements
- Inherited Members
- Extension Methods
Constructors
Fog()
Initializes a new instance of the Fog class.
public Fog()
Fog(string)
Initializes a new instance of the Fog class.
public Fog(string shaderName)
Parameters
shaderName
stringName of the fog shader.
Properties
Color
[DataMember(20)]
public Color3 Color { get; set; }
Property Value
Density
[DataMember(10)]
public float Density { get; set; }
Property Value
FogStart
[DataMember(30)]
public float FogStart { get; set; }
Property Value
SkipBackground
[DataMember(40)]
public bool SkipBackground { get; set; }
Property Value
Methods
DrawCore(RenderDrawContext)
Main drawing method for this renderer that must be implemented.
protected override void DrawCore(RenderDrawContext context)
Parameters
context
RenderDrawContextThe context.
InitializeCore()
protected override void InitializeCore()
SetColorDepthInput(Texture, Texture, float, float)
Provides a color buffer and a depth buffer to apply the fog to.
public void SetColorDepthInput(Texture colorBuffer, Texture depthBuffer, float zMin, float zMax)
Parameters
colorBuffer
TextureA color buffer to process.
depthBuffer
TextureThe depth buffer corresponding to the color buffer provided.
zMin
floatzMax
float
SetDefaultParameters()
Sets the default parameters (called at constructor time and if Reset() is called)
protected override void SetDefaultParameters()