A mathematic curve.
A curve that can be saved and re-used for other objects. By default, it ranges between [code]0[/code] and [code]1[/code] on the Y axis and positions points relative to the [code]0.5[/code] Y position.
Adds a point to the curve. For each side, if the [code]*_mode[/code] is [constant TANGENT_LINEAR], the [code]*_tangent[/code] angle (in degrees) uses the slope of the curve halfway to the adjacent point. Allows custom assignments to the [code]*_tangent[/code] angle if [code]*_mode[/code] is set to [constant TANGENT_FREE].
Recomputes the baked cache of points for the curve.
Removes points that are closer than [code]CMP_EPSILON[/code] (0.00001) units to their neighbor on the curve.
Removes all points from the curve.
Returns the number of points describing the curve.
Returns the left [enum TangentMode] for the point at [code]index[/code].
Returns the left tangent angle (in degrees) for the point at [code]index[/code].
Returns the curve coordinates for the point at [code]index[/code].
Returns the right [enum TangentMode] for the point at [code]index[/code].
Returns the right tangent angle (in degrees) for the point at [code]index[/code].
Returns the Y value for the point that would exist at the X position [code]offset[/code] along the curve.
Returns the Y value for the point that would exist at the X position [code]offset[/code] along the curve using the baked cache. Bakes the curve's points if not already baked.
Removes the point at [code]index[/code] from the curve.
Sets the left [enum TangentMode] for the point at [code]index[/code] to [code]mode[/code].
Sets the left tangent angle for the point at [code]index[/code] to [code]tangent[/code].
Sets the offset from [code]0.5[/code].
Sets the right [enum TangentMode] for the point at [code]index[/code] to [code]mode[/code].
Sets the right tangent angle for the point at [code]index[/code] to [code]tangent[/code].
Assigns the vertical position [code]y[/code] to the point at [code]index[/code].
The number of points to include in the baked (i.e. cached) curve data.
The maximum value the curve can reach. Default value: [code]1[/code].
The minimum value the curve can reach. Default value: [code]0[/code].
Emitted when [member max_value] or [member min_value] is changed.
The tangent on this side of the point is user-defined.
The curve calculates the tangent on this side of the point as the slope halfway towards the adjacent point.
The total number of available tangent modes.