mirror of
https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git
synced 2024-12-01 07:51:01 +00:00
awstranscriber: post warning message with details when item is late
When the latency is configured to a value that is too low, items will be pushed out with an adjusted timestamp, thus affecting synchronization. It can be useful for the application to receive details about those adjustments. Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1793>
This commit is contained in:
parent
41ddbd8706
commit
79845fd99a
1 changed files with 12 additions and 0 deletions
|
@ -1436,6 +1436,18 @@ impl TranslationPadTask {
|
||||||
"Updating item PTS ({pts} < {last_position}), consider increasing latency",
|
"Updating item PTS ({pts} < {last_position}), consider increasing latency",
|
||||||
);
|
);
|
||||||
|
|
||||||
|
let details = gst::Structure::builder("awstranscriber/late-item")
|
||||||
|
.field("original-pts", pts)
|
||||||
|
.field("last-position", last_position)
|
||||||
|
.build();
|
||||||
|
|
||||||
|
gst::element_warning!(
|
||||||
|
self.pad.parent(),
|
||||||
|
gst::LibraryError::Settings,
|
||||||
|
["Late transcription item, updating PTS"],
|
||||||
|
details: details
|
||||||
|
);
|
||||||
|
|
||||||
pts = last_position;
|
pts = last_position;
|
||||||
// FIXME if the resulting duration is zero, we might as well not push it.
|
// FIXME if the resulting duration is zero, we might as well not push it.
|
||||||
duration = duration.saturating_sub(delta);
|
duration = duration.saturating_sub(delta);
|
||||||
|
|
Loading…
Reference in a new issue