Skip to content

TextStudioWritingKnot

StructTextStudioTextStudio
public struct TextStudioWritingKnot

One cubic path knot. Control points are stored in the same coordinate space as the knot.

TextStudioWritingKnot(Vector2, Vector2, Vector2, float, float)

Section titled “TextStudioWritingKnot(Vector2, Vector2, Vector2, float, float)”
public TextStudioWritingKnot(Vector2 position, Vector2 incomingControl, Vector2 outgoingControl, float pressure = 1, float time = 0)

Creates a cubic path knot with absolute control points, clamping pressure and time to zero or greater.

Parameters

Name Type
position UnityEngine.Vector2
incomingControl UnityEngine.Vector2
outgoingControl UnityEngine.Vector2
pressure System.Single
time System.Single

public static TextStudioWritingKnot Corner(Vector2 position, float pressure = 1, float time = 0)

Creates a knot whose control points coincide with its position for a corner between adjoining curve segments.

Parameters

Name Type
position UnityEngine.Vector2
pressure System.Single
time System.Single

Returns

TextStudio.TextStudioWritingKnot

public Vector2 Position { get; }

Returns

UnityEngine.Vector2

public Vector2 IncomingControl { get; }

Returns

UnityEngine.Vector2

public Vector2 OutgoingControl { get; }

Returns

UnityEngine.Vector2

public float Pressure { get; }

Returns

System.Single

public float Time { get; }

Returns

System.Single