Click or drag to resize
DigitalRuneEffectParameterDescription Class
Describes a parameter of an effect.
Inheritance Hierarchy
SystemObject
  DigitalRune.Graphics.EffectsEffectParameterDescription

Namespace: DigitalRune.Graphics.Effects
Assembly: DigitalRune.Graphics (in DigitalRune.Graphics.dll) Version: 1.2.0.0 (1.2.1.14562)
Syntax
public class EffectParameterDescription

The EffectParameterDescription type exposes the following members.

Constructors
  NameDescription
Public methodEffectParameterDescription
Initializes a new instance of the EffectParameterDescription class.
Top
Methods
  NameDescription
Public methodEquals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetHashCode
Serves as a hash function for a particular type.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
Properties
  NameDescription
Public propertyHint
Gets a value indicating how the effect parameter should be treated during state sorting.
Public propertyIndex
Gets the zero-based index.
Public propertyParameter
Gets the effect parameter.
Public propertySemantic
Gets the standard semantic (case-sensitive).
Top
Remarks

EffectParameterDescriptions provide additional information for effect parameters. This information is used by the graphics engine to understand effects and apply them properly during rendering.

The standard semantic (see Semantic) is a unique, case-sensitive string (such as "World", "Diffuse", "PointLightPosition", etc.) that defines how the parameter should be interpreted and used by the engine. User-defined strings can be used, as long as they do not conflict with any of the existing semantics. Existing semantics are defined by the following types: DefaultEffectParameterSemantics, SceneEffectParameterSemantics.

The index (see Index) defines the object to which the parameter needs to be bound if multiple objects of the same type exist. The description (Semantic = "PointLightPosition", Index = 3, Hint = Local) means that the parameter stores the position of 4th point light near the object that is being rendered.

Additionally, the sort hint (see Hint) indicates how the parameter should be treated during state sorting.

The descriptions are created automatically by effect interpreters (see IEffectInterpreter) when an effect is initialized. The graphics service manages a list of effect interpreters. Custom interpreters can be added to the graphics service to support new types of effects.

See Also