VController
Controller
int
Current position of the Controller (in milliseconds).
int
Total length of the sequence (in milliseconds).
float
Speed of playback. A value > 0.0 will enable the Controller to play forwards, while a value < 0.0 will play backwards. If |TimeScale| > 1.0, then playback will be faster than normal, while |TimeScale| < 1.0 will be slower.
bool
Instead of stopping once playback is complete, the Controller will reset and resume play.
bool
When the sequence loops, reverse the direction of play.
int
The number of times the sequence loops before stopping. -1 will cause the sequence to loop indefinitely.
int
When the sequence loops, delay playback by this value (in milliseconds).
bool
When the sequence is completed, reset the state of the Controller.
Public Functions
void
addDataField(String fieldType, String fieldName)
Add a new data entry to the Data Table.
void
clear()
Detaches and deletes all of the child objects.
int
getCount()
Get the number of child objects.
int
Get the number of data elements in the Data Table.
string
getDataFieldName(int index)
Get the name of the field given by the passed index.
string
getDataFieldType(String fieldName)
Get the type of data for the given field.
string
getDataFieldValue(String fieldName)
Get the evaluated data from the data field.
int
getObject(int index)
Get the object corresponding to the given index.
float
Get the playback speed. A value > 0.0 will enable the Controller to play forwards, while a value < 0.0 will play backwards.
bool
isDataField(String fieldName)
Is the field a member of the Data Table?
bool
isPaused()
Is the sequence currently paused?
bool
Is the sequence currently playing?
bool
Is the sequence currently stopped?
void
pause()
Pause the sequence. Playback can resume by calling VController::play().
void
play(int time)
Play the sequence. If a value for pTime is specified, the Controller is reset and played from that time.
bool
readFile(String fileName)
Clears the object and loads the new data from the given filename.
bool
readTemplate(String fileName)
Load data from given filename.
void
removeDataField(String fieldName)
Remove a data entry from the Data Table.
void
removeObject(SimObject simObj)
Remove the target object from this node.
void
reset(int time)
Reset the Controller's and child object's state.
void
setTimeScale(float timeScale)
Set the playback speed. A value > 0.0 will enable the Controller to play forwards, while a value < 0.0 will play backwards. If |pTimeScale| > 1.0, then playback will be faster than normal, while |pTimeScale| < 1.0 will be slower.
void
Sort Groups by their Labels.
void
Sort Tracks by their Labels.
void
step()
Step forward one frame.
void
stop(bool reset)
Stop the sequence and optionally reset it.
bool
writeFile(String fileName)
Save to a given filename.
Detailed Description
UNDOCUMENTED!
Controller
int Time
Current position of the Controller (in milliseconds).
int Duration
Total length of the sequence (in milliseconds).
float TimeScale
Speed of playback. A value > 0.0 will enable the Controller to play forwards, while a value < 0.0 will play backwards. If |TimeScale| > 1.0, then playback will be faster than normal, while |TimeScale| < 1.0 will be slower.
bool Loop
Instead of stopping once playback is complete, the Controller will reset and resume play.
bool LoopBackwards
When the sequence loops, reverse the direction of play.
int LoopCount
The number of times the sequence loops before stopping. -1 will cause the sequence to loop indefinitely.
int LoopDelay
When the sequence loops, delay playback by this value (in milliseconds).
bool ResetOnCompletion
When the sequence is completed, reset the state of the Controller.
Public Functions
addDataField(String fieldType, String fieldName)
Add a new data entry to the Data Table.
Parameters:
pFieldType | The method of evaluating the field's data. |
pFieldName | The name of the field to be added to the Data Table. |
No return value.
addObject(SimObject simObj)
Add a child object to this node.
Parameters:
pObject | The SimObjectID of the object to be added to this node. |
No return value.
clear()
Detaches and deletes all of the child objects.
No return value.
getCount()
Get the number of child objects.
Returns the number of child objects.
getDataFieldCount()
Get the number of data elements in the Data Table.
Returns the size of the Data Table.
getDataFieldName(int index)
Get the name of the field given by the passed index.
Parameters:
pIndex | The index of the data field you wish to check. |
Returns the name of the field corresponding to the given index.
getDataFieldType(String fieldName)
Get the type of data for the given field.
Parameters:
pFieldName | The name of the field you wish to check. |
Returns the data type.
getDataFieldValue(String fieldName)
Get the evaluated data from the data field.
Parameters:
pFieldName | The name of the field you wish to evaluate. |
Returns the evaluated data from the field.
getObject(int index)
Get the object corresponding to the given index.
Parameters:
pIndex | The index of the object you wish to retrieve. |
Returns the SimObjectID for the object.
getTimeScale()
Get the playback speed. A value > 0.0 will enable the Controller to play forwards, while a value < 0.0 will play backwards.
Playback Speed.
isDataField(String fieldName)
Is the field a member of the Data Table?
Parameters:
pFieldName | The name of the dynamic field you wish to check. |
Returns true if the field is a member of the Data Table.
isPaused()
Is the sequence currently paused?
Returns true if the Controller is paused.
isPlaying()
Is the sequence currently playing?
Returns true if the Controller is playing.
isStopped()
Is the sequence currently stopped?
Returns true if the Controller is stopped.
pause()
Pause the sequence. Playback can resume by calling VController::play().
No return value.
play(int time)
Play the sequence. If a value for pTime is specified, the Controller is reset and played from that time.
Parameters:
pTime | The time to start playing the sequence from. |
No return value.
readFile(String fileName)
Clears the object and loads the new data from the given filename.
Parameters:
pFileName | The target file to read from. |
Returns true if the read was successful.
readTemplate(String fileName)
Load data from given filename.
Parameters:
pFileName | The target file to read from. |
Returns true if the read was successful.
removeDataField(String fieldName)
Remove a data entry from the Data Table.
Parameters:
pFieldName | The name of the field to be removed from the Data Table. |
No return value.
removeObject(SimObject simObj)
Remove the target object from this node.
Parameters:
pObject | The SimObjectID of the object to be removed from this node. |
No return value.
reset(int time)
Reset the Controller's and child object's state.
Parameters:
pTime | The target time to reset to. |
No return value.
setTimeScale(float timeScale)
Set the playback speed. A value > 0.0 will enable the Controller to play forwards, while a value < 0.0 will play backwards. If |pTimeScale| > 1.0, then playback will be faster than normal, while |pTimeScale| < 1.0 will be slower.
Parameters:
pTimeScale | Playback speed. |
No return value.
sortGroups()
Sort Groups by their Labels.
No return value.
sortTracks()
Sort Tracks by their Labels.
No return value.
step()
Step forward one frame.
No return value.
stop(bool reset)
Stop the sequence and optionally reset it.
Parameters:
pReset | Reset the Controller after stopping. |
No return value.
writeFile(String fileName)
Save to a given filename.
Parameters:
pFileName | The target file to write to. |
Returns true if the write was successful.