Curvy  4.0.0
CGShape Class Reference
+ Inheritance diagram for CGShape:
+ Collaboration diagram for CGShape:

Detailed Description

Rasterized Shape Data (Polyline)

Public Attributes

Bounds Bounds
 
bool Closed
 Whether the base spline is closed or not More...
 
float[] F = new float[0]
 Relative position (0..1) within the length More...
 
float Length
 Length in world units More...
 
float[] Map = new float[0]
 Arbitrary mapped value, usually U More...
 
List< SamplePointsMaterialGroupMaterialGroups = new List<SamplePointsMaterialGroup>()
 Groups/Patches More...
 
Vector3[] Normal = new Vector3[0]
 Normal More...
 
Vector3[] Position = new Vector3[0]
 Shape/Path Position More...
 
bool Seamless
 Whether the Shape/Path is seamless, i.e. Closed==true and the whole length is covered More...
 
float[] SourceF = new float[0]
 Relative position (0..1, NOT TF!) on the source spline (if any) More...
 
bool SourceIsManaged
 Whether the source is managed or not More...
 
- Public Attributes inherited from CGData
string Name
 

Properties

override int Count [get]
 Gets the number of sample points More...
 
- Properties inherited from CGData
virtual int Count [get]
 
DateTime Timestamp [get]
 Time of last change More...
 

Public Member Functions

 CGShape ()
 
 CGShape (CGShape source)
 
override T Clone< T > ()
 
float DistanceToF (float distance)
 Converts absolute (World Units) to relative (F) distance More...
 
float FToDistance (float f)
 Converts relative (F) to absolute distance (World Units) More...
 
int GetFIndex (float f, out float frag)
 Gets the index of a certain F More...
 
void Interpolate (float f, out Vector3 pos, out Vector3 up)
 Interpolates Position and Normal by F More...
 
Vector3 InterpolatePosition (float f)
 Interpolates Position by F More...
 
Vector3 InterpolateUp (float f)
 Interpolates Normal by F More...
 
void Move (ref float f, ref int direction, float speed, CurvyClamping clamping)
 
void MoveBy (ref float f, ref int direction, float speedDist, CurvyClamping clamping)
 
virtual void Recalculate ()
 Recalculate Length and F[] (by measuring a polyline built from all Position points) More...
 
void RecalculateNormals (List< int > softEdges)
 
- Public Member Functions inherited from CGData
 CGData ()
 
void Touch ()
 

Static Public Member Functions

static void Copy (CGShape dest, CGShape source)
 
- Static Public Member Functions inherited from CGData
static implicit operator bool (CGData a)
 

Additional Inherited Members

- Protected Member Functions inherited from CGData
int getGenericFIndex (ref float[] FMapArray, float fValue, out float frag)
 Searches FMapArray and returns the index that covers the fValue as well as the percentage between index and index+1 More...
 

Constructor & Destructor Documentation

CGShape ( )
CGShape ( CGShape  source)

Member Function Documentation

override T Clone< T > ( )
virtual

Reimplemented from CGData.

Reimplemented in CGVolume, and CGPath.

static void Copy ( CGShape  dest,
CGShape  source 
)
static
float DistanceToF ( float  distance)

Converts absolute (World Units) to relative (F) distance

Parameters
distancedistance in world units
Returns
Relative distance (0..1)
float FToDistance ( float  f)

Converts relative (F) to absolute distance (World Units)

Parameters
frelative distance (0..1)
Returns
Distance in World Units
int GetFIndex ( float  f,
out float  frag 
)

Gets the index of a certain F

Parameters
fF (0..1)
fragfragment between the resulting and the next index (0..1)
Returns
the resulting index
void Interpolate ( float  f,
out Vector3  pos,
out Vector3  up 
)

Interpolates Position and Normal by F

Parameters
f0..1
Vector3 InterpolatePosition ( float  f)

Interpolates Position by F

Parameters
f0..1
Returns
the interpolated position
Vector3 InterpolateUp ( float  f)

Interpolates Normal by F

Parameters
f0..1
Returns
the interpolated normal
void Move ( ref float  f,
ref int  direction,
float  speed,
CurvyClamping  clamping 
)
void MoveBy ( ref float  f,
ref int  direction,
float  speedDist,
CurvyClamping  clamping 
)
virtual void Recalculate ( )
virtual

Recalculate Length and F[] (by measuring a polyline built from all Position points)

Call this after TRS'ing a shape

Reimplemented in CGPath.

void RecalculateNormals ( List< int >  softEdges)

Member Data Documentation

Bounds Bounds
bool Closed

Whether the base spline is closed or not

float [] F = new float[0]

Relative position (0..1) within the length

float Length

Length in world units

float [] Map = new float[0]

Arbitrary mapped value, usually U

List<SamplePointsMaterialGroup> MaterialGroups = new List<SamplePointsMaterialGroup>()

Groups/Patches

Vector3 [] Normal = new Vector3[0]

Normal

Vector3 [] Position = new Vector3[0]

Shape/Path Position

bool Seamless

Whether the Shape/Path is seamless, i.e. Closed==true and the whole length is covered

float [] SourceF = new float[0]

Relative position (0..1, NOT TF!) on the source spline (if any)

bool SourceIsManaged

Whether the source is managed or not

This could be used to determine if values needs to be transformed into generator space or not

Property Documentation

override int Count
get

Gets the number of sample points


The documentation for this class was generated from the following file: