WaterRenderer Class |
Namespace: DigitalRune.Graphics.Rendering
The WaterRenderer type exposes the following members.
Name | Description | |
---|---|---|
WaterRenderer |
Initializes a new instance of the WaterRenderer class.
|
Name | Description | |
---|---|---|
CanRender |
Determines whether this renderer can handle the specified scene node.
(Overrides SceneNodeRendererCanRender(SceneNode, RenderContext).) | |
Dispose |
Releases all resources used by an instance of the SceneNodeRenderer class.
(Inherited from SceneNodeRenderer.) | |
Dispose(Boolean) |
Releases the unmanaged resources used by an instance of the SceneNodeRenderer
class and optionally releases the managed resources.
(Overrides SceneNodeRendererDispose(Boolean).) | |
Equals | (Inherited from Object.) | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) | |
GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
Render(SceneNode, RenderContext) |
Renders the specified scene node.
(Inherited from SceneNodeRenderer.) | |
Render(IListSceneNode, RenderContext) |
Renders the specified scene nodes.
(Inherited from SceneNodeRenderer.) | |
Render(IListSceneNode, RenderContext, RenderOrder) |
Renders the specified scene nodes.
(Overrides SceneNodeRendererRender(IListSceneNode, RenderContext, RenderOrder).) | |
ToString | Returns a string that represents the current object. (Inherited from Object.) |
Name | Description | |
---|---|---|
IsDisposed |
Gets a value indicating whether this instance has been disposed of.
(Inherited from SceneNodeRenderer.) | |
Order |
Gets the draw order of this scene node renderer.
(Inherited from SceneNodeRenderer.) | |
ProjectedGridParameters |
Gets the projected grid parameters.
|
Water is rendered using a refraction effect. Therefore, the renderer needs a texture which contains the current scene. This texture should be set in RenderContext.SourceTexture. If no such texture is provided, the renderer uses the current render target, sets a new RenderContext.RenderTarget and restores the depth buffer.
Currently, vertex displacement from WaterWaves and water flow from WaterFlow are mutually exclusive. Only one of those effects is rendered.
If the WaterNode represents an infinite plane with waves, the renderer uses a "projected grid" to render the water surface. The grid parameters can be changed in ProjectedGridParameters.
Render Target and Viewport:
This renderer renders into the current render target and viewport of the graphics device.