gstreamer/gst-libs/gst/video
George Kiagiadakis a4d97f49e2 videodecoder: In reverse playback, flush the output queue after decoding each keyframe chain
This fixes the reverse playback scenario when upstream is not fully
parsing the stream and does not send every keyframe chain separately
with the DISCONT flag on the keyframe.

To explain this, let's suppose we have this stream:
 0 1 2 3 4 5 6 7 8
 K     K     K

In most circumstances, the upstream parser will chain in the
decoder the buffers in the following order:

 6 7 8 3 4 5 0 1 2
 D     D     D

In this case, GstVideoDecoder will flush the parse queue every time
it receives discont (D) and we will eventually get in the output queue:

  (flush here) 8 7 6  (flush here) 5 4 3 (flush here) 2 1 0

In case the upstream parser doesn't do this work, though,
GstVideoDecoder will receive the whole stream at once and will flush
the parse queue afterwards:

 0 1 2 3 4 5 6 7 8
 D

During the flush, it will look backwards for keyframes and will
decode in this order:

 6 7 8 3 4 5 0 1 2

This is the same order that it would receive from upstream if
upstream was parsing and looking for the keyframes, only that now
there is no flushing of the output queue in between keyframes,
which will result in the output queue looking like this:

 2 1 0 6 5 3 8 7 6

This will confuse downstream obviously and will play incorrectly.
This patch forces the decoder to flush the output queue every time
it picks a new keyframe to decode, so it will end up decoding 6 7 8
and then flushing before picking 3 for decoding, so the output will
get 8 7 6 before 6 5 3 and the video will play back correctly.

https://bugzilla.gnome.org/show_bug.cgi?id=734441
2014-08-11 10:22:55 +02:00
..
.gitignore Update .gitignore 2012-08-08 09:06:30 +01:00
colorbalance.c docs: Fix argument and annotation typos 2014-03-02 23:22:51 +00:00
colorbalance.h Fix FSF address 2012-11-03 23:05:09 +00:00
colorbalancechannel.c Fix FSF address 2012-11-03 23:05:09 +00:00
colorbalancechannel.h Fix FSF address 2012-11-03 23:05:09 +00:00
convertframe.c convertframe: Fix indention 2013-12-09 16:34:22 +01:00
gstvideodecoder.c videodecoder: In reverse playback, flush the output queue after decoding each keyframe chain 2014-08-11 10:22:55 +02:00
gstvideodecoder.h docs: Fix argument and annotation typos 2014-03-02 23:22:51 +00:00
gstvideoencoder.c videoencoder: Don't delay set_format 2014-07-25 14:12:02 -04:00
gstvideoencoder.h videoencoder: Add sink_query() src_query() virtual functions 2013-12-09 16:34:19 +01:00
gstvideofilter.c videofilter: implement transform_meta virtual method. 2013-09-09 15:37:02 +02:00
gstvideofilter.h Fix FSF address 2012-11-03 23:05:09 +00:00
gstvideometa.c videometa: fix texture_type memcpy size 2014-04-10 12:35:03 +01:00
gstvideometa.h videometa: add GstVideoGLTextureUploadMeta buffer pool option 2013-11-26 14:04:38 +01:00
gstvideopool.c docs: add GstVideoPool to docs 2014-02-23 14:42:12 +00:00
gstvideopool.h Fix FSF address 2012-11-03 23:05:09 +00:00
gstvideosink.c Fix FSF address 2012-11-03 23:05:09 +00:00
gstvideosink.h Fix FSF address 2012-11-03 23:05:09 +00:00
gstvideoutils.c videoutils: add some debug 2014-01-13 17:24:01 +01:00
gstvideoutils.h docs: Fix argument and annotation typos 2014-03-02 23:22:51 +00:00
Makefile.am video: Generate types for tile enumeration 2014-01-13 10:47:23 -05:00
navigation.c docs: Fix argument and annotation typos 2014-03-02 23:22:51 +00:00
navigation.h Fix FSF address 2012-11-03 23:05:09 +00:00
TODO video: Base classes for video decoders and encoders 2012-04-24 17:03:40 +02:00
video-blend.c video: don't crash when blending onto video formats that unpack to 64 bits per pixel 2012-11-07 11:17:14 +00:00
video-blend.h Fix FSF address 2012-11-03 23:05:09 +00:00
video-chroma.c video-chroma: don't crash on NULL resamplers 2014-01-23 10:45:00 +01:00
video-chroma.h video: make direct includes work again 2013-08-16 14:14:15 +01:00
video-color.c docs: Fix argument and annotation typos 2014-03-02 23:22:51 +00:00
video-color.h Fix FSF address 2012-11-03 23:05:09 +00:00
video-event.c video-event: Update the running times in the force-keyunit events from the pad offsets 2014-04-10 09:18:05 +02:00
video-event.h Fix FSF address 2012-11-03 23:05:09 +00:00
video-format.c videoformat: Remove duplicate/incorrect section 2014-03-02 23:41:51 +00:00
video-format.h video: Don't use extra plane and componenent for tile format 2014-01-13 10:47:03 -05:00
video-frame.c videoframe: Initialise GstVideoFrame to zeroes if mapping fails 2014-04-16 19:53:46 +02:00
video-frame.h video: make direct includes work again 2013-08-16 14:14:15 +01:00
video-info.c video: avoid overflows when doing int operations for size 2014-06-09 23:38:39 -03:00
video-info.h Fix FSF address 2012-11-03 23:05:09 +00:00
video-orc-dist.c Release 1.3.1 2014-05-03 17:50:10 +02:00
video-orc-dist.h video: fix build without orc or older or versions 2013-09-06 13:28:00 +01:00
video-orc.orc video-format: fix NV24 pack/unpack function 2013-09-06 12:45:36 +02:00
video-overlay-composition.c video-overlay-composition: guard against NULL pointer dereference on error 2014-04-10 12:35:03 +01:00
video-overlay-composition.h video-overlay-composition: add GST_CAPS_FEATURE_META_GST_VIDEO_OVERLAY_COMPOSITION 2014-03-05 20:38:45 +01:00
video-tile.c docs: Assorted documentation and introspection fixes for new 1.4 API 2014-07-02 09:09:44 +02:00
video-tile.h video: Don't use extra plane and componenent for tile format 2014-01-13 10:47:03 -05:00
video.c Fix FSF address 2012-11-03 23:05:09 +00:00
video.h docs: fix some doc blocks 2013-09-09 15:52:05 +02:00
video.vcproj more working plugins 2004-07-27 21:41:30 +00:00
videoorientation.c Fix FSF address 2012-11-03 23:05:09 +00:00
videoorientation.h Fix FSF address 2012-11-03 23:05:09 +00:00
videooverlay.c videoverlay: Don't mention gconf elements and add a sentence about playbin/playsink 2014-01-14 13:20:48 +01:00
videooverlay.h Fix FSF address 2012-11-03 23:05:09 +00:00