Partager via


What Is Antialiasing?

Antialiasing is a technique for softening or blurring sharp edges so they appear less jagged when rendered.

Antialiasing is accomplished by multisampling each pixel at multiple pixel locations and combining the samples to generate a final pixel color. Increasing the number of samples per pixel increases the amount of antialiasing which generates a smoother edge. 4x multisampling requires four samples per pixel and 2x multisampling requires two sampler per pixel. Use the MultiSampleCount property of the PresentationParameters class to set the number of samples for the back buffer.

In XNA Game Studio 3.1, use GraphicsAdapter.CheckDeviceMultiSampleType to query the hardware for multisample support. In XNA Game Studio 4.0 Refresh, set the PreferMultiSampling property on the GraphicsDeviceManager class to true to enable multisampling for the back buffer. This will be ignored if the hardware does not support multisampling.

See Also

Enabling Antialiasing (Multisampling)