Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

This enumeration provides values used to identify actions that the Direct3D Mobile pixel pipeline will take as the result of a stencil test. For more information, see Stencil Operations.

Syntax

typedef enum _D3DMSTENCILOP {
  D3DMSTENCILOP_KEEP		= 1,
  D3DMSTENCILOP_ZERO		= 2,
  D3DMSTENCILOP_REPLACE	 = 3,
  D3DMSTENCILOP_INCRSAT	 = 4,
  D3DMSTENCILOP_DECRSAT	 = 5,
  D3DMSTENCILOP_INVERT	= 6,
  D3DMSTENCILOP_INCR		= 7,
  D3DMSTENCILOP_DECR		= 8,
  D3DMSTENCILOP_FORCE_ULONG = 0x7fffffff,
} D3DMSTENCILOP;

Elements

D3DMSTENCILOP_KEEP

Indicates that the stencil buffer will not be updated.

D3DMSTENCILOP_ZERO

Indicates that the stencil buffer value for the given pixel will be set to 0.

D3DMSTENCILOP_REPLACE

Indicates that the stencil buffer value for the given pixel will be set to the stencil reference value.

D3DMSTENCILOP_INCRSAT

Indicates that the stencil buffer value for the given pixel will be incremented by 1. The stencil buffer value is limited to 2^ n, where nis the number of bits in the stencil buffer channel.

D3DMSTENCILOP_DECRSAT

Indicates that the stencil buffer value for the given pixel will be decremented by 1. The stencil buffer value cannot be set to a value less than 0.

D3DMSTENCILOP_INVERT

Indicates that the bits of the stencil buffer value for the given pixel will all be inverted.

D3DMSTENCILOP_INCR

Indicates that the stencil buffer value for the given pixel will be incremented by 1 with all overflow bits thrown away. As a result the stencil buffer value will wrap around to 0.

D3DMSTENCILOP_DECR

Indicates that the stencil buffer value for the given pixel will be decremented by 1 with all underflow bits thrown away. As a result the stencil buffer value will wrap around to 2^ n, where nis the number of bits in the stencil channel.

D3DMSTENCILOP_FORCE_ULONG

Forces the compiler to interpret the enumeration as a ULONG value. This value is not used directly in Direct3D Mobile programming.

Remarks

Stencil-buffer entries are integer values ranging from 0 to 2 n–1, where nis the bit depth of the stencil buffer.

Requirements

Header d3dmtypes.h
Windows Embedded CE Windows CE 5.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also