Difference between revisions of "BezierCurve:render"

m (See Also: eval was renamed to evaluate)
Line 4: Line 4:
 
This function samples the Bézier curve using recursive subdivision. You can control the recursion depth using the depth parameter.
 
This function samples the Bézier curve using recursive subdivision. You can control the recursion depth using the depth parameter.
  
If you are just interested to know the position on the curve given a parameter, use [[BezierCurve:eval]].
+
If you are just interested to know the position on the curve given a parameter, use [[BezierCurve:evaluate]].
  
 
== Function ==
 
== Function ==

Revision as of 10:49, 24 September 2013

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

Get a list of coordinates to be used with love.graphics.line.

This function samples the Bézier curve using recursive subdivision. You can control the recursion depth using the depth parameter.

If you are just interested to know the position on the curve given a parameter, use BezierCurve:evaluate.

Function

Synopsis

coordinates = BezierCurve:render(depth)

Arguments

number depth (5)
Number of recursive subdivision steps.

Returns

table coordinates
List of x,y-coordinate pairs of points on the curve.

See Also


Other Languages