mirror of
https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git
synced 2025-02-20 14:46:24 +00:00
onvifmetadataparse: use NTP epoch everywhere instead of mixing UNIX/NTP epochs
This commit is contained in:
parent
23098a98ab
commit
be56991b73
1 changed files with 9 additions and 2 deletions
|
@ -56,7 +56,13 @@ impl OnvifMetadataParse {
|
||||||
element: &super::OnvifMetadataParse,
|
element: &super::OnvifMetadataParse,
|
||||||
buffer: gst::Buffer,
|
buffer: gst::Buffer,
|
||||||
) -> Result<gst::FlowSuccess, gst::FlowError> {
|
) -> Result<gst::FlowSuccess, gst::FlowError> {
|
||||||
gst::log!(CAT, obj: element, "Handling buffer {:?}", buffer);
|
gst::log!(
|
||||||
|
CAT,
|
||||||
|
obj: element,
|
||||||
|
"Handling buffer {:?} with UTC time {}",
|
||||||
|
buffer,
|
||||||
|
crate::lookup_reference_timestamp(&buffer).display()
|
||||||
|
);
|
||||||
|
|
||||||
let mut state = self.state.lock().unwrap();
|
let mut state = self.state.lock().unwrap();
|
||||||
|
|
||||||
|
@ -151,7 +157,8 @@ impl OnvifMetadataParse {
|
||||||
gst::FlowError::Error
|
gst::FlowError::Error
|
||||||
})?;
|
})?;
|
||||||
|
|
||||||
let dt_unix_ns = gst::ClockTime::from_nseconds(dt.timestamp_nanos() as u64);
|
let dt_unix_ns = gst::ClockTime::from_nseconds(dt.timestamp_nanos() as u64)
|
||||||
|
+ crate::PRIME_EPOCH_OFFSET;
|
||||||
|
|
||||||
gst::trace!(
|
gst::trace!(
|
||||||
CAT,
|
CAT,
|
||||||
|
|
Loading…
Reference in a new issue