namespace: CurveArchitect.Objects
file: Segment.cs
Description:
Contains all information for one segment on an Architect Curve.
Public variables
Mesh deformation:
float zRotation
- Sets the z rotation for the specific segment.
float contrast
- Sets the contrast for the specific segment.
Vector2 saddleSkew
- Sets the saddle skew for the specific segment.
Vector2 scale
- Sets the scale for the specific segment.
Terrain deformation:
float terrainZRotation
- Sets the terrain z rotation for the specific segment.
float terrainSaddleSkewY
- Sets the terrain saddle skew y for the specific segment.
float terrainScaleWidth
- Sets the terrain scale width for the specific segment.
float terrainScaleBlendWidth
- Sets the terrain scale blend width for the specific segment.
Property's:
Transform Parent
- Get the Architect Curve transform.
Other:
float roughLengthEstimation
- Rough length estimation for the segment.
Public functions
Vector3 GetPosition(Type type)
Description:
Gets the world position of the specified point type (anchor, tangentA, or tangentB) by transforming the local position.
Returns:
The world position of the specified point.
Vector3 GetLocalPosition(Type type)
Description:
Gets the local position of the specified point type (anchor, tangentA, or tangentB).
Returns:
The local position of the specified point.
void SetPosition(Type type, Vector3 newPosition)
Description:
Sets the world position of the specified point type (anchor, tangentA, or tangentB) by transforming the world position to local space.
void Translate(Type type, Vector3 value)
Description:
Translates the specified point type (anchor, tangentA, or tangentB) by a given value in world space.
void SetContrast(float value)
Description:
Sets the contrast value, clamping it within the specified minimum and maximum range.