decoder: h264: add support for NALU "alignment" optimization.
authorSreerenj Balachandran <sreerenj.balachandran@intel.com>
Thu, 6 Feb 2014 06:30:10 +0000 (08:30 +0200)
committerGwenole Beauchesne <gwenole.beauchesne@intel.com>
Thu, 19 Jun 2014 13:29:12 +0000 (15:29 +0200)
commitcb9f98f0d5501f7f700e33bbc969d0ce420c2601
tree94a7f82e6c326c7fef898d249b38478ea717581c
parent95c781c34fad757eb820429604fbd4e3d921960a
decoder: h264: add support for NALU "alignment" optimization.

We can avoid scanning for start codes again if the bitstream is fed
in NALU chunks. Currently, we always scan for start codes, and keep
track of remaining bits in a GstAdapter, even if, in practice, we
are likely receiving one GstBuffer per NAL unit. i.e. h264parse with
"nal" alignment.

https://bugzilla.gnome.org/show_bug.cgi?id=723284

[use gst_adapter_available_fast() to determine the top buffer size]
Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
gst-libs/gst/vaapi/gstvaapidecoder_h264.c
gst-libs/gst/vaapi/gstvaapidecoder_h264.h
gst/vaapi/gstvaapidecode.c