aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/h263dec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-08-17 15:31:14 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-08-17 22:17:49 +0200
commita0c6c8e53ebc32cebcc0182e514cecc6eb30c8a7 (patch)
treeadd4728a4e1bbc762e5c058259103e659455217a /libavcodec/h263dec.c
parent0a141b0e49ba3989a28f5f006a978bdab92a9217 (diff)
downloadffmpeg-a0c6c8e53ebc32cebcc0182e514cecc6eb30c8a7.tar.gz
Revert "Merge commit of 'vdpau: remove old-style decoders'"
This reverts commit bf36dc50ea448999c8f8c7a35f6139a7040f6275, reversing changes made to b7fc2693c70fe72936e4ce124c802ac23857c476. Conflicts: libavcodec/h264.c Keeping support for the old VDPAU API has been requested by our VDPAU maintainer Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/h263dec.c')
-rw-r--r--libavcodec/h263dec.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/libavcodec/h263dec.c b/libavcodec/h263dec.c
index 07e697fd2c..bf9e072546 100644
--- a/libavcodec/h263dec.c
+++ b/libavcodec/h263dec.c
@@ -36,6 +36,7 @@
#include "h263_parser.h"
#include "mpeg4video_parser.h"
#include "msmpeg4.h"
+#include "vdpau_internal.h"
#include "thread.h"
#include "flv.h"
#include "mpeg4video.h"
@@ -651,6 +652,11 @@ retry:
if (!s->divx_packed && !avctx->hwaccel)
ff_thread_finish_setup(avctx);
+ if (CONFIG_MPEG4_VDPAU_DECODER && (s->avctx->codec->capabilities & CODEC_CAP_HWACCEL_VDPAU)) {
+ ff_vdpau_mpeg4_decode_picture(s, s->gb.buffer, s->gb.buffer_end - s->gb.buffer);
+ goto frame_end;
+ }
+
if (avctx->hwaccel) {
if ((ret = avctx->hwaccel->start_frame(avctx, s->gb.buffer, s->gb.buffer_end - s->gb.buffer)) < 0)
return ret;
@@ -695,6 +701,7 @@ retry:
}
av_assert1(s->bitstream_buffer_size==0);
+frame_end:
/* divx 5.01+ bitstream reorder stuff */
if(s->codec_id==AV_CODEC_ID_MPEG4 && s->divx_packed){
int current_pos= s->gb.buffer == s->bitstream_buffer ? 0 : (get_bits_count(&s->gb)>>3);