Share via


RenderState.MultiSampleMask Property

Gets or sets a bitmask controlling modification of the samples in a multisample render target. The default is 0xffffffff.

Namespace: Microsoft.Xna.Framework.Graphics
Assembly: Microsoft.Xna.Framework (in microsoft.xna.framework.dll)

Syntax

public int MultiSampleMask { get; set; }

Property Value

A bitmask value controlling write enables for the samples. Each bit in this mask, starting at the least-significant bit, controls modification of one of the samples in a multisample render target. Thus, for an 8-sample render target, the low byte contains the eight write enables for each of the eight samples. This render state has no effect when rendering to a single sample buffer.

Remarks

This render state enables use of a multisample buffer as an accumulation buffer, doing multipass rendering of geometry where each pass updates a subset of samples.

Given n multisamples and k enabled samples, the resulting intensity of the rendered image should be k/n. Each component RGB of every pixel is factored by k/n.

See Also

Reference

RenderState Class
RenderState Members
Microsoft.Xna.Framework.Graphics Namespace

Platforms

Xbox 360, Windows XP SP2, Windows Vista