SpriteFlags Enumeration (Microsoft.DirectX.Direct3D)

Defines flags used to specify sprite rendering options.

Definition

Visual Basic Public Enum SpriteFlags
C# public enum SpriteFlags
C++ public enum class SpriteFlags
JScript public enum SpriteFlags

Members

Member Value Description
AlphaBlend 16 Enables alpha blending with RenderStateManager.AlphaTestEnable set to true (for nonzero alpha). SourceAlpha is the source blend state, and InvSourceAlpha is the destination blend state in calls to RenderStateManager. The Font class requires this flag to be set when drawing text.
SortDepthBackToFront 128 Sorts sprites by depth in back-to-front order prior to drawing. This option is recommended when drawing transparent sprites of varying depths. You may combine SortDepthBackToFront with SortTexture to sort first by depth, and second by texture.
SortDepthFrontToBack 64 Sorts sprites by depth in front-to-back order prior to drawing. This option is recommended when drawing opaque sprites of varying depths. You may combine SortDepthFrontToBack with SortTexture to sort first by depth, and second by texture.
SortTexture 32 Sorts sprites by texture prior to drawing. This option is recommended when drawing non-overlapping sprites of uniform depth; for example, drawing screen-aligned text with Font. You may also combine SortTexture with either SortDepthFrontToBack or SortDepthBackToFront. This will sort the list of sprites by depth first and texture second.
Billboard 8 Rotates each sprite around its center so that it is facing the viewer. Sprite.SetWorldViewLH or Sprite.SetWorldViewRH must be called first.
ObjectSpace 4 Specifies no modification of the world, view, and projection transforms. The transforms currently set to the device are used to transform sprites when the batched sprites are drawn (that is, when Sprite.Flush or Sprite.End is called). If this option is not specified, the world, view, and projection transforms are modified so that sprites are drawn in screen-space coordinates.
DoNotModifyRenderState 2 Specifies no changes to the device render state when Sprite.Begin is called. The device is assumed to be in a valid state to draw vertices when the VertexElement.UsageIndex property equals 0 and VertexElement.DeclarationUsage is set to DeclarationUsage.Position, DeclarationUsage.TextureCoordinate, or DeclarationUsage.Color.
DoNotSaveState 1 Prevents the device state from being saved or restored when Sprite.Begin or Sprite.End is called.
None 0 Resolves the value to 0.

Enumeration Information

Namespace Microsoft.DirectX.Direct3D
Assembly Microsoft.DirectX.Direct3DX (microsoft.directx.direct3dx.dll)
Strong Name Microsoft.DirectX.Direct3DX,  Version=1.0.900.0,  Culture=neutral,  PublicKeyToken=d3231b57b74a1492