Castle Game EngineIntroduction Units Class Hierarchy Classes, Interfaces, Objects and Records Types Variables Constants Functions and Procedures Identifiers
|
Interface IAbstractTimeDependentNode
Unit
X3DNodes
Declaration
type IAbstractTimeDependentNode = interface(IAbstractChildNode)
Description
Interface from which all time-dependent nodes are derived.
Attributes
- GUID['{19D68914-F2BA-4CFA-90A1-F561DB264678}']
Hierarchy
Overview
Methods
Properties
Description
Methods
 |
function GetCycleInterval: TFloatTime; |
Final length (in seconds) of this animation. For a looping animation, this is the time it takes to make a single cycle. Should always be > 0.
This is not called "duration", as that word is reserved to mean "unscaled time length" for X3D AudioClip and MovieTexture nodes. The final length, returned here, is the AudioClip.duration divided by AudioClip.pitch, or MovieTexture.duration / MovieTexture.speed.
On TTimeSensorNode descendants, you can also get and set this by the property TTimeSensorNode.CycleInterval.
|
 |
function ElapsedTime: TFloatTime; |
Time in seconds since the sensor was activated and running, not counting any time while in pause state.
For non-looping animations, note that the sensor automatically stops when the animation finishes, so ElapsedTime will not grow beyond the "duration". If you want to observe when the animation ended, you probably do not want to use this property. Instead observe when IsActive changed to False , by registering a callback on EventIsActive.AddNotification . See the examples/3d_rendering_processing/listen_on_x3d_events.lpr .
BTW, the "duration" mentioned above is usually just GetCycleInterval, but sometimes it's a GetCycleInterval multiplied by some scaling factor, like in case of TAudioClipNode or TMovieTextureNode).
For a precise (and complicated:) specification of how this behaves, see the X3D TimeSensor.elapsedTime specification at http://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/time.html#TimeSensor
|
 |
function ElapsedTimeInCycle: TFloatTime; |
Time in seconds since the sensor was activated and running, in this cycle, not counting any time while in pause state.
This is like ike ElapsedTime, but counting only the current cycle. When GetCycleInterval = 0, this is always 0. When GetCycleInterval <> 0, this is always >= 0 and < CycleInterval .
|
Properties
Generated by PasDoc 0.15.0.
|