* key unit event. See gst_video_event_new_downstream_force_key_unit() for a
* full description of the downstream force key unit event.
*
+ * @running_time will be adjusted for any pad offsets of pads it was passing through.
+ *
* Returns: %TRUE if the event is a valid downstream force key unit event.
*/
gboolean
if (stream_time)
*stream_time = ev_stream_time;
- if (running_time)
+ if (running_time) {
+ gint64 offset = gst_event_get_running_time_offset (event);
+
*running_time = ev_running_time;
+ /* Catch underflows */
+ if (*running_time > -offset)
+ *running_time += offset;
+ else
+ *running_time = 0;
+ }
if (all_headers)
*all_headers = ev_all_headers;
*
* Create an upstream force key unit event using gst_video_event_new_upstream_force_key_unit()
*
+ * @running_time will be adjusted for any pad offsets of pads it was passing through.
+ *
* Returns: %TRUE if the event is a valid upstream force-key-unit event. %FALSE if not
*/
gboolean
if (!gst_structure_get_uint (s, "count", &ev_count))
ev_count = 0;
- if (running_time)
+
+ if (running_time) {
+ gint64 offset = gst_event_get_running_time_offset (event);
+
*running_time = ev_running_time;
+ /* Catch underflows */
+ if (*running_time > -offset)
+ *running_time += offset;
+ else
+ *running_time = 0;
+ }
if (all_headers)
*all_headers = ev_all_headers;