Is it possible to make the EXT-X-PROGRAM-DATE-TIME tag values in hlssink start from, and sync with, times that come from the gstreamer pipeline clock or other sources?
From what we can tell it always take the UTC time calculated from system clock, with some internal adjustment.
Thanks
Right now, there is no support for customization of the timezone used when calculating the date time tag used in writing the media segment. See hlssink3.
Can you raise an issue ticket regarding this?
We are not looking for timezone customization, but rather, complete control over the timestamps.
That is, the ability to make the timestamps obey a custom clock far in the future or the past (or one of the gst clocks), regardless of current UTC/timezone etc…
hlssink3
at the moment does not allow setting a custom clock for use in the calculation of date time tag. Support will have to be added for that.
Thanks @Sanchayan. Could you please clarify how the datetimes set in the manifest by the hlssink3 are currently calculated? Specifically, is it based on the time when the segment reached the plugin, or is it relative to the GST clock from the start of the pipeline?
It is based on the time when the segment first reached the plugin. Effectively, it is calculated as
Date time = First segment time + (Current segment running time - First segment running time)
This can be seen here.
There is also a pdt-follows-pipeline-clock
property which controls whether date time follows the pipeline clock or is allowed to match the wall clock. Former behaviour is the default.
Thanks @Sanchayan. I have added a feature to hlssink3 that supports using NTP timestamps from the buffer’s ReferenceTimestampMeta
property, if set in the Gst:Buffer.
This enhancement allows the use of the camera’s timestamp instead of the UTC timestamp calculated by the plugin.
To include the NTP timestamp in ReferenceTimestampMeta
, users can utilize a gst probe to copy this value from the Nvidia buffer, enabling the retrieval of the timestamp from each frame.
I issued a Merge Request to the gst-plugins-rs repo: hlssink3 - Add Support for NTP timestamp from buffer (!2017) · Merge requests · GStreamer / gst-plugins-rs · GitLab. I would appreciate your review.