vaapidecode: Always keep a copy of input codec state
authorSreerenj Balachandran <sreerenj.balachandran@intel.com>
Fri, 28 Aug 2015 20:43:47 +0000 (23:43 +0300)
committerSreerenj Balachandran <sreerenj.balachandran@intel.com>
Fri, 28 Aug 2015 20:43:47 +0000 (23:43 +0300)
commitba8fcf54356d84ec5794a14892c263ae9a870ded
tree83556e2107a998a49c1aa42324f70f5f3f553264
parent11716efdd3cf6a47e78a2f33245854a0ba6df995
vaapidecode: Always keep a copy of input codec state

Currently we are sharing the input GstVideoCodecState with
GstVaapiDecoder(gst-libs/gst/vaapi) by just doing ref and unref for
each caps change. This is troublesome in many cases, for eg: if
resoultion changes with in a singe stream. Because, when ever there
is a resolution change, GstVideoDecoder will first change the Codec_state->caps
fields with new resolution, but since we are using the same codecstate (ref)
in gstvaapidecode.c, the caps check for input caps change will always fail.

https://bugzilla.gnome.org/show_bug.cgi?id=753914
gst/vaapi/gstvaapidecode.c