Click or drag to resize
DigitalRuneEffectParameterBindingUpdate Method
Updates the value of the binding.

Namespace: DigitalRune.Graphics.Effects
Assembly: DigitalRune.Graphics (in DigitalRune.Graphics.dll) Version: 1.2.0.0 (1.2.1.14562)
Syntax
public void Update(
	RenderContext context
)

Parameters

context
Type: DigitalRune.GraphicsRenderContext
The render context.
Remarks

This method is called usually once per frame to update the parameter value. Update(RenderContext) calls OnUpdate(RenderContext) which needs to be implemented in derived classes. When the effect parameter is dynamic and needs to be recalculated each frame before rendering, OnUpdate(RenderContext) can be used to compute the new parameter value. When the effect parameter is static then OnUpdate(RenderContext) can be empty.

The method Update(RenderContext) only calculates the new value and stores it internally. The Apply(RenderContext) then sets the value in the target parameter (see Parameter).

Update(RenderContext) needs to be called before Apply(RenderContext).

See Also