Instance Property

writeMask

A bitmask that restricts which color channels are written into the texture.

Declaration

var writeMask: MTLColorWriteMask { get set }

Discussion

The default value of writeMask is all ones, all, which allows all color channels to be blended. The MTLColorWriteMask values MTLColorWriteMaskRed, MTLColorWriteMaskGreen, MTLColorWriteMaskBlue, and MTLColorWriteMaskAlpha limit blending to one color channel, and these values can be bitwise combined. MTLColorWriteMaskNone does not allow any color channels to be blended.

See Also

Specifying Render Pipeline State

var pixelFormat: MTLPixelFormat

The pixel format of the color attachment’s texture.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software