diff options
author | Seungha Yang <seungha.yang@navercorp.com> | 2018-08-13 22:44:51 +0900 |
---|---|---|
committer | Nicolas Dufresne <nicolas.dufresne@collabora.com> | 2018-09-11 16:08:15 -0400 |
commit | 594246a6400e81007a7cccc2721b4d1a4b00729c (patch) | |
tree | 23be202aa1327fd2f0e0726477591d95efbcac06 | |
parent | 06367b4c86d7a059a48bb430e04f89a28f06c426 (diff) | |
download | gstreamer-plugins-bad-594246a6400e81007a7cccc2721b4d1a4b00729c.tar.gz |
h265parse: Fix periodic SPS/PPS sending work after a seek
Apply the commit ef71b61
See also https://bugzilla.gnome.org/show_bug.cgi?id=742212
https://bugzilla.gnome.org/show_bug.cgi?id=754124
-rw-r--r-- | gst/videoparsers/gsth265parse.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gst/videoparsers/gsth265parse.c b/gst/videoparsers/gsth265parse.c index d009409f8..775cd24cf 100644 --- a/gst/videoparsers/gsth265parse.c +++ b/gst/videoparsers/gsth265parse.c @@ -2098,10 +2098,12 @@ gst_h265_parse_pre_push_frame (GstBaseParse * parse, GstBaseParseFrame * frame) if (h265parse->interval > 0 || h265parse->push_codec) { GstClockTime timestamp = GST_BUFFER_TIMESTAMP (buffer); guint64 diff; + gboolean initial_frame = FALSE; /* init */ if (!GST_CLOCK_TIME_IS_VALID (h265parse->last_report)) { h265parse->last_report = timestamp; + initial_frame = TRUE; } if (h265parse->idr_pos >= 0) { @@ -2121,7 +2123,7 @@ gst_h265_parse_pre_push_frame (GstBaseParse * parse, GstBaseParseFrame * frame) GST_TIME_ARGS (diff)); if (GST_TIME_AS_SECONDS (diff) >= h265parse->interval || - h265parse->push_codec) { + initial_frame || h265parse->push_codec) { GstClockTime new_ts; /* avoid overwriting a perfectly fine timestamp */ @@ -2436,6 +2438,8 @@ gst_h265_parse_event (GstBaseParse * parse, GstEvent * event) break; case GST_EVENT_SEGMENT: { + h265parse->last_report = GST_CLOCK_TIME_NONE; + res = GST_BASE_PARSE_CLASS (parent_class)->sink_event (parse, event); break; } |