次の方法で共有


RenderState.AlphaTestEnable Property

Gets or sets a render state that enables a per-pixel alpha test. The default value is false.

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

Syntax

public bool AlphaTestEnable { get; set; }

Property Value

true if per-pixel alpha blending is enabled; false otherwise.

Remarks

If the test passes, the pixel is processed by the frame buffer. Otherwise, all frame-buffer processing is skipped for the pixel. The test is done by comparing the incoming alpha value with the reference alpha value, using the comparison function provided by AlphaFunction. The reference alpha value is determined by the value set for ReferenceAlpha.

See Also

Reference

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

Platforms

Xbox 360, Windows XP SP2, Windows Vista