D2D1_SPRITE_OPTIONS enumeration

Specifies additional aspects of how a sprite batch is to be drawn, as part of a call to ID2D1DeviceContext3::DrawSpriteBatch.

Syntax


typedef enum D2D1_SPRITE_OPTIONS { 
  D2D1_SPRITE_OPTIONS_NONE                       = 0,
  D2D1_SPRITE_OPTIONS_CLAMP_TO_SOURCE_RECTANGLE  = 1
} D2D1_SPRITE_OPTIONS;

Constants

D2D1_SPRITE_OPTIONS_NONE

Default value. No special drawing configuration. This option yields the best drawing performance.

D2D1_SPRITE_OPTIONS_CLAMP_TO_SOURCE_RECTANGLE

Interpolation of bitmap pixels will be clamped to the sprite’s source rectangle. If the sub-images in your source bitmap have no pixels separating them, then you may see color bleeding when drawing them with D2D1_SPRITE_OPTIONS_NONE. In that case, consider adding borders between them with your sprite-packing tool, or use this option. Note that drawing sprites with this option enabled is slower than using D2D1_SPRITE_OPTIONS_NONE.

Requirements

Header

D2d1_3.h

 

 

Show: