GNOME Bugzilla – Bug 697548
avviddec: Setting same caps resets decoder
Last modified: 2013-04-09 18:42:48 UTC
Inside gst_ffmpegviddec_set_format function of gstavviddec.c file, we attempt to make sure that the new caps is not the same one we already have and we avoid draining and closing/resetting the decoder. But because we set the 'last_caps' to the new caps before we close/reset the decoder, the last_caps is reset to NULL immediately after we setting it to the new caps. Due to this we are not able to detect whether the given caps is new one or the one the decoder is already configured for. This makes the decoder to get reset every time we set the caps even if the decoder is already configured for the given caps.
Created attachment 240938 [details] [review] Fix for the issue The fix for the issue is attached
commit 77edec961b5bd4ffb6cf254fb040925b524a27d0 Author: Siva Chandran P <siva.chandran.p@gmail.com> Date: Tue Apr 9 20:40:06 2013 +0200 avvidec: Make sure to store newly set caps after resetting the decoder Otherwise we'll just set the to NULL while resetting the decoder and don't have them available anymore later. https://bugzilla.gnome.org/show_bug.cgi?id=697548