Click or drag to resize
DigitalRuneWaterFlowFlowMap Property
Gets or sets the texture which defines the flow direction and speed.

Namespace: DigitalRune.Graphics
Assembly: DigitalRune.Graphics (in DigitalRune.Graphics.dll) Version: 1.2.0.0 (1.2.1.14562)
Syntax
public Texture2D FlowMap { get; set; }

Property Value

Type: Texture2D
The texture which defines the flow direction and speed.
Remarks

The RG channels stores horizontal flow direction. The B channel stores the flow speed. The water pixel shader will apply the flow map flow like this:

Given a flow map value f = (r, g, b), the 3D flow velocity is flowVelocity.xz = (f.rg * 2 - 1) * f.b * FlowMapSpeed. (The component flowVelocity.y is always 0.)

The FlowMap is also relative to the WaterNode; it is aligned with the local axes of the node. It fills the local AABB, and the map is always projected top-down.

See Also