Draw XXL documentation


enum DrawBasics.BezierPosInterpretation

When drawing bezier splines the supplied control points can be interpreted in different ways Those ways are possible:

Name Description
start_control1_control2_endIsNextStart A Chain of cubic bezier spline segments. Only the position of the transform is regarded. The positions that are specified via the pointsArray are interpreted as groups of three: i=0 is the startPos of the first segment. i=1 is the first control pos of the first segment, i=2 is the second control pos of the first segment. i=3 is the shared postion between the first segment (where it acts as endPos) and the second segment (where it acts as startPos). This pattern of three points per segment then repeats and continues as 'i' is counted upwards. The spline can be continuous or kinked at segment transitions, depending on the supplied points.
start_control1_endIsNextStart A Chain of quadratic bezier spline segments. Only the position of the transform is regarded. The positions that are specified via the pointsArray are interpreted as groups of two: i=0 is the startPos of the first segment. i=1 is the single control pos of the first segment, i=2 is the shared postion between the first segment (where it acts as endPos) and the second segment (where it acts as startPos). This pattern of three points per segment then repeats and continues as 'i' is counted upwards. The spline can be continuous or kinked at segment transitions, depending on the supplied points.
onlySegmentStartPoints_backwardForwardIsAligned A Chain of cubic bezier spline segments. Every transform counts as start of a new bezier segment, and acts as both: the start point of the new bezier segment and the end point of the preceding bezier segment. The curve direction at the points is defined by the transform.forward (/transform.right for the 2D-version). The curve direction at these points is aligned, meaning without kink, but can have different weights to both sides: the forward weight is defined by transform.localScale.z (transform.localScale.x for the 2D version) and the backward weight is defined by transform.localScale.y (both for the 2D and the 3D version)
onlySegmentStartPoints_backwardForwardIsMirrored A Chain of cubic bezier spline segments. Same as "onlySegmentStartPoints_backwardForwardIsAligned" but with the difference that there is no different weight for the forward and backward spline direction, but instead both get controlled by transform.localScale.z (transform.localScale.x for the 2D version)
onlySegmentStartPoints_backwardForwardIsKinked A Chain of quadratic bezier spline segments, that may have kinks at each segment start point. The outgoing direction is defined by transform.forward (/transform.right for the 2D-version) and can be weighted with transform.localScale.z (transform.localScale.x for the 2D version). The incoming direction is independent from that and is defined by the preceding segment. Although the name of this "BezierPosInterpretation" contains "Kinked" it can be continuous at segment transitions if the supplied points take care of it. "Kinked" here just means that that draw function does not automatically ensure continuous unkinked transitions as it does for "onlySegmentStartPoints_backwardForwardIsAligned" and "onlySegmentStartPoints_backwardForwardIsMirrored".