CINEMA 4D gives you a generous number of predefined curves. Add to this the possibility to convert vector based artwork files from other programs and to add graphic characters and you have a large number of spline primitives at your fingertips. All of these spline primitives are parameterized. This means that the spline is merely the graphical representation of a mathematical formula built controlled by parameters you can edit the Attribute Manager.
To get more information on this topic, check out this chapter on Wikipedia.
See also
Parameters: |
|
||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Return type: | |||||||||||
Returns: |
The new object. |
Get the type of spline.
Return type: | int | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Returns: |
The type of spline. Check out Spline Types.
|
Checks if spline is closed.
Return type: | bool |
---|---|
Returns: | True if the spline is closed. |
Get the spline point at a position along the given segment.
Parameters: |
|
---|---|
Raises IndexError: | |
If the segment index is out of range : 0<=segment<GetSegmentCount(). |
|
Return type: | |
Returns: |
The spline point. |
Get the spline tangent at a position along the given segment.
Parameters: |
|
---|---|
Raises IndexError: | |
If the segment index is out of range : 0<=segment<GetSegmentCount(). |
|
Return type: | |
Returns: |
The spline point. |
Returns information about the segment.
segment = spline.GetSegment(0) print segment[“cnt”], segment[“closed”] #is int, bool
Parameters: | id (int) – The segment. |
---|---|
Raises IndexError: | |
If the segment index id is out of range : 0<=id<GetSegmentCount(). | |
Return type: | dict{cnt: int, closed: bool} |
Returns: | The segment. |
Set properties of the segment.
Parameters: |
|
---|---|
Raises IndexError: | |
If the segment index is out of range : 0<=segment<GetSegmentCount(). |
Returns the count of segments.
Return type: | int |
---|---|
Returns: | The count. |
Change the number of segments and points for this spline. If scnt is -1 or not set, the method PointObject.ResizeObject() of PointObject is used.
Parameters: |
|
---|---|
Return type: |
bool |
Returns: |
Success of changing the number of points and segments. |
Initialise the spline with default coefficients.
Return type: | bool |
---|---|
Returns: | True if successful, otherwise False. |
Returns the count of tangents.
Return type: | int |
---|---|
Returns: | The count. |
Return a tangent:
tangent = spline.GetTangent()
print tangent["vl"], tangent["vr"]
Parameters: | id (int) – The tangent index. |
---|---|
Raises IndexError: | |
If the tangent index id is out of range : 0<=segment<GetTangentCount(). | |
Return type: | dict{vl: Vector, vr: Vector} |
Returns: | Left and right part that defines the tangent. |