Unigine::SplinePoint Class
Header: | #include <UnigineWorlds.h> |
This class is used to manage individual points of the world spline graph.
SplinePoint Class
Members
void setEnabled( int enable, int with_segments = 1 )
Sets a value indicating whether the spline point is enabled.Arguments
- int enable - 1 to enable the spline point, 0 to disable.
- int with_segments - Use 1 to enable all segments, to which the point belongs as well, 0 to enable the spline point only.
int isEnabled( )
Returns a value indicating whether the spline point is enabled.Return value
1 if the spline point is enabled; otherwise, 0.void setPosition( const Math::Vec3 & position )
Sets a new position of the spline point.Arguments
- const Math::Vec3 & position - New position to be set.
Math::Vec3 getPosition( )
Returns the current position of the spline point.Return value
Current spline point position.void getSplineSegments( Vector< Ptr<SplineSegment> > & segments )
Returns the list of segments, to which the spline point belongs, and puts them to the specified vector of SplineSegment elements.Arguments
- Vector< Ptr<SplineSegment> > & segments - Vector to store the list of segments, to which the spline point belongs.
void clearSources( )
Clears the list of source nodes for the spline point.void assignSource( const char * name )
Assigns a source node with the given name to the spline point.Arguments
- const char * name - Source node name.
void removeSource( const char * name )
Removes the source node with the given name.Arguments
- const char * name - Name of the source node to be removed.
void getSources( Vector< String > & sources )
Returns a list of source nodes assigned to the spline point and puts it to the specified vector.Arguments
- Vector< String > & sources - List of source nodes assigned to the spline point.
void copy( const Ptr<SplinePoint> & src )
Copies all parameters from the specified source spline point.Arguments
- const Ptr<SplinePoint> & src - Source spline point.
Ptr<SplinePoint> clone( )
Returns a clone of the spline point.Return value
Clone of the spline point.Ptr<WorldSplineGraph> getParent( )
Returns the WorldSplineGraph node to which the spline point belongs.Return value
WorldSplineGraph node to which the spline point belongs.int getNumSegments( )
Returns the total number of segments sharing this spline point.Return value
Total number of segments sharing this spline point.int getNumSources( )
Returns the total number of source nodes assigned to this spline point.Return value
Total number of source nodes assigned to this spline point.int getSourceNodeType( const char * name )
Returns the type of the source node with the specified name.Arguments
- const char * name - Source node name.
Return value
Source node type.void setLinkVariant( const char * name, int variant )
Sets a link variant for the junction source node with the specified name.Arguments
- const char * name - Source node name.
- int variant - Link variant number for the junction source node.
int getLinkVariant( const char * name )
Returns the current link variant for the junction source node with the specified name.Arguments
- const char * name - Source node name.
Return value
Link variant number for the junction source node.Last update:
2019-01-16
Help improve this article
Was this article helpful?
(or select a word/phrase and press Ctrl+Enter)