BrightSign HD2000 Object Reference Manual User Manual
Page 14
![background image](https://www.manualsdir.com/files/776470/content/doc014.png)
Users can add events which trigger messages of the roVideoEvent “Timecode Hit” at the specified
millisecond times in a video file. The data field of the roVideoEvent holds the userdata passed in with
AddEvent.
Here is an example script that uses timecode events. The script prints out 2, 5 and 10 at 2 seconds, 5
seconds and 10 seconds into the video. The msg is approaching frame accurate.
10 v = CreateObject("roVideoPlayer")
20 p = CreateObject("roMessagePort")
30 v.SetPort(p)
40 ok = v.AddEvent(2, 2000) ' Add timed events to video
50 ok = v.AddEvent(5, 5000)
60 ok = v.AddEvent(10, 10000)
70 ok = v.AddEvent(100, 100000)
80 ok = v.PlayFile("ATA:/C5_d5_phil.vob")
90 msg = wait(0,p)
' Wait for all events
95 if msg.GetInt() = 8 then stop
' End of file
100 if msg.GetInt() <> 12 goto 90
' I only care about time events
110 print msg.GetData()
' Print out index when the time event happens
120 goto 90
14