Difference between revisions of "StencilAction"

(Created page)
 
m
 
Line 1: Line 1:
 
{{newin|[[0.10.0]]|100|type=enum}}
 
{{newin|[[0.10.0]]|100|type=enum}}
How a [[love.graphics.stencil|stencil]] modifies stencil values of pixels it touches.
+
How a [[love.graphics.stencil|stencil function]] modifies the stencil values of pixels it touches.
 
== Constants ==
 
== Constants ==
 
;replace: The stencil value of a pixel will be replaced by the value specified in [[love.graphics.stencil]], if any object touches the pixel.
 
;replace: The stencil value of a pixel will be replaced by the value specified in [[love.graphics.stencil]], if any object touches the pixel.
Line 14: Line 14:
 
* [[love.graphics.setStencilTest]]
 
* [[love.graphics.setStencilTest]]
 
[[Category:Enums]]
 
[[Category:Enums]]
{{#set:Description=How a [[love.graphics.stencil|stencil]] modifies stencil values of pixels it touches.}}
+
{{#set:Description=How a [[love.graphics.stencil|stencil function]] modifies the stencil values of pixels it touches.}}
 
== Other Languages ==
 
== Other Languages ==
 
{{i18n|StencilAction}}
 
{{i18n|StencilAction}}

Latest revision as of 04:45, 15 December 2015

Available since LÖVE 0.10.0
This enum is not supported in earlier versions.

How a stencil function modifies the stencil values of pixels it touches.

Constants

replace
The stencil value of a pixel will be replaced by the value specified in love.graphics.stencil, if any object touches the pixel.
increment
The stencil value of a pixel will be incremented by 1 for each object that touches the pixel. If the stencil value reaches 255 it will stay at 255.
decrement
The stencil value of a pixel will be decremented by 1 for each object that touches the pixel. If the stencil value reaches 0 it will stay at 0.
incrementwrap
The stencil value of a pixel will be incremented by 1 for each object that touches the pixel. If a stencil value of 255 is incremented it will be set to 0.
decrementwrap
The stencil value of a pixel will be decremented by 1 for each object that touches the pixel. If the stencil value of 0 is decremented it will be set to 255.
invert
The stencil value of a pixel will be bitwise-inverted for each object that touches the pixel. If a stencil value of 0 is inverted it will become 255.

See Also

Other Languages