Skip to content

LinearExtrusionPath

ClassTextStudio.ThreeDTextStudio.3D
public sealed class LinearExtrusionPath : IExtrusionPath, IExtrusionPathCacheIdentity

Identity path: reproduces the original straight-Z extrusion. Useful as a default and for tests.

public LinearExtrusionPath(float depth)

Creates a straight renderer-local path along negative Z with non-negative depth.

Parameters

Name Type
depth System.Single

Sample(float, out Vector3, out Vector3, out Vector3)

Section titled “Sample(float, out Vector3, out Vector3, out Vector3)”
public void Sample(float t, out Vector3 position, out Vector3 forward, out Vector3 up)

Sample the path at normalised parameter t. t = 0 corresponds to the back face (z = 0 in Standard mode); t = 1 corresponds to the front face (z = −depth in Standard mode).

Parameters

Name Type Description
t System.Single Normalised parameter in [0, 1].
position UnityEngine.Vector3 Renderer-local position of the sampled frame.
forward UnityEngine.Vector3 Unit vector pointing along the path (replaces +Z).
up UnityEngine.Vector3 Unit vector orthogonal to forward (replaces +Y).

public float ArcLength { get; }

Total arc length of the path in local units. Consumed by the generator to scale per-ring Z spacing so body steps are uniform along curved paths. Return 0 for an “infinitely” short path (collapsed to a single point).

Returns

System.Single

public int SampleCount { get; }

Minimum axial segment count required to represent this path.

Returns

System.Int32

public int Revision { get; }

Monotonic content revision owned by the path provider.

Returns

System.Int32

public int CacheIdentity { get; }

Deterministic identity for the current immutable path snapshot.

Returns

System.Int32