Difference between revisions of "Geometry:flip"

(Created page with "{{newin|0.9.0|090|type=function}} Flip the vertex coordinates along a specified axis. == Function == === Synopsis === <source lang="lua"> Geometry:flip( x, y ) </source> ===...")
 
(Added formula note for flipping)
Line 1: Line 1:
 
{{newin|[[0.9.0]]|090|type=function}}
 
{{newin|[[0.9.0]]|090|type=function}}
 
Flip the vertex coordinates along a specified axis.
 
Flip the vertex coordinates along a specified axis.
 +
 +
The formula for flipping is '''coordinate = max_coordinate + min_coordinate - vertex_coordinate'''.
  
 
== Function ==
 
== Function ==

Revision as of 05:52, 20 May 2013

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

Flip the vertex coordinates along a specified axis.

The formula for flipping is coordinate = max_coordinate + min_coordinate - vertex_coordinate.

Function

Synopsis

Geometry:flip( x, y )

Arguments

boolean x
True if you want to flip along the x axis.
boolean y
True if you want to flip along the x axis.

Returns

Nothing.

See Also

Other Languages