GNOME Bugzilla – Bug 619817
[matroskademux] Reverse playback doesn't work
Last modified: 2010-06-21 22:45:40 UTC
I try to reverse playback a mkv file but it doesn't work. Software versions used: gst core/base 0.10.29 gst good 0.10.22.3 gst ffmpeg 0.10.10 python bindings 0.10.18 Running on a Ubuntu 9.10 Source code + video: http://pastebin.com/Jh1sgshU http://www.megaupload.com/?d=A6YD0EOR
Could you attach a debug log for the failure? Does seeking with rate > work?
Here is the debug http://www.megaupload.com/?d=4QOBJHFD With rate > 0.0 it works. I think that the problem is related to matroskademux not marking buffers as 'discont'.
Created attachment 162231 [details] [review] Improve reverse playback Seems problems are caused (a.o.) by keyframes not being where one would expect from cue entries. Attached patched modifies implementation a bit to handle such cases also.
Looks good :)
I have tested the patch and now it does reverse playback but my test still have problems. The reverse playback starts after a bit of consuming high cpu, i suppose it is because of decoding/buffering to begin the reverse playback. But also, the reverse playback doesn't play all the file. It stops before reaching the beginning of the file. Anyway, thanks for the patch.
Created attachment 162364 [details] Log (just the end) when using reverse playback patch
Using some pipeline as follows: filesrc ... ! decodebin2 name=dec ! audio/x-raw-int ! fakesink dec. ! video/x-raw-yuv ! fakesink and then issuing a reverse seek (that extends all the way to 0 of course) show that it does reach the beginning of the file. So: commit 44fa95d5cbde7fbffb6d31174af7ccd7c6edd943 Author: Mark Nauwelaerts <mark.nauwelaerts@collabora.co.uk> Date: Fri May 28 16:37:32 2010 +0200 matroskademux: improve reverse playback Slightly modify approach to also handle cases where cue entries do not reliably lead to initial keyframes. Fixes #619817.