lovr.graphics.setColorMask

Enables and disables individual color channels. When a color channel is enabled, it will be affected by drawing commmands and clear commands.

lovr.graphics.setColorMask(r, g, b, a)

Arguments

NameTypeDescription
rbooleanWhether the red color channel should be enabled.
gbooleanWhether the green color channel should be enabled.
bbooleanWhether the blue color channel should be enabled.
abooleanWhether the alpha color channel should be enabled.

Returns

Nothing

Notes

By default, all color channels are enabled.

Disabling all of the color channels can be useful if you only want to write to the depth buffer or the stencil buffer.

See also