Difference between revisions of "love.graphics.setScissor"

m (Undo revision 14857 by Slime (talk))
m (Variant descriptions)
Line 6: Line 6:
 
The dimensions of the scissor is unaffected by graphical transformations (translate, scale, ...).
 
The dimensions of the scissor is unaffected by graphical transformations (translate, scale, ...).
 
== Function ==
 
== Function ==
 +
Limits the drawing area to a specified rectangle.
 
=== Synopsis ===
 
=== Synopsis ===
 
<source lang="lua">
 
<source lang="lua">
Line 18: Line 19:
 
Nothing.
 
Nothing.
 
== Function ==
 
== Function ==
 +
Disables scissor.
 
=== Synopsis ===
 
=== Synopsis ===
 
<source lang="lua">
 
<source lang="lua">
Line 26: Line 28:
 
=== Returns ===
 
=== Returns ===
 
Nothing.
 
Nothing.
=== Notes ===
 
Disables scissor.
 
 
== See Also ==
 
== See Also ==
 
* [[parent::love.graphics]]
 
* [[parent::love.graphics]]

Revision as of 16:57, 12 April 2015

Available since LÖVE 0.4.0
This function is not supported in earlier versions.

Sets or disables scissor.

The scissor limits the drawing area to a specified rectangle. This affects all graphics calls, including love.graphics.clear.

The dimensions of the scissor is unaffected by graphical transformations (translate, scale, ...).

Function

Limits the drawing area to a specified rectangle.

Synopsis

love.graphics.setScissor( x, y, width, height )

Arguments

number x
x coordinate of upper left corner.
number y
y coordinate of upper left corner.
number width
width of clipping rectangle.
number height
height of clipping rectangle.

Returns

Nothing.

Function

Disables scissor.

Synopsis

love.graphics.setScissor( )

Arguments

None.

Returns

Nothing.

See Also


Other Languages