Skip to content

NTP time of IP cameras

If the camera streams expose the NTP time, the NTP time of the current frame being displayed can be obtained in 100 ns units:

  • at any time by invoking int64 NTPTime = VideoGrabber.GetFrameInfo (0, fi_NTPFrameTime)

  • through the TFrameInfo structure pointer of the OnFrameBitmap event: FrameInfo->NTPFrameTime

Note:

  • if the NTP server is configured on the IP camera, the typical time value should look like the current Unix epoch time .

  • if the NTP server is not configured the value may start from an arbitrary value, but the NTP time of the current frame minus the NTP time of the first frame received can still be used to calculate the current stream duration since the preview started.