Sets the elements of the MFTime event-in slot.
C# |
---|
public abstract void SetValue (
double[] value
) |
The following example demonstrates how to write two
timestamps into a "set_timestamps" field of a
Script node:
C# |
---|
Vrml.EAI.Node script = ...;
Vrml.EAI.Field.EventInMFTime set_timestamps = (Vrml.EAI.Field.EventInMFTime)script.GetEventIn("set_timestamps");
System.DateTime baseTime = new System.DateTime(1970, 1, 1, 0, 0, 0, 0, System.DateTimeKind.Utc);
System.TimeSpan deltaTime = System.DateTime.UtcNow.Subtract(baseTime);
double currentTime = deltaTime.TotalSeconds;
set_timestamps.SetValue(new double[] { currentTime + 5.0, currentTime + 10.0 });
|