From 7eb6ed78ea191c48279fc208f676807cfd3d732d Mon Sep 17 00:00:00 2001 From: Carl Eugen Hoyos Date: Fri, 9 Jan 2009 22:22:40 +0000 Subject: Move VDPAU check, make future VDPAU patches smaller. Originally committed as revision 16508 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/error_resilience.c | 1 + libavcodec/h264.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/libavcodec/error_resilience.c b/libavcodec/error_resilience.c index 55bd716c54..bdd3a663d5 100644 --- a/libavcodec/error_resilience.c +++ b/libavcodec/error_resilience.c @@ -681,6 +681,7 @@ void ff_er_frame_end(MpegEncContext *s){ Picture *pic= s->current_picture_ptr; if(!s->error_recognition || s->error_count==0 || s->avctx->lowres || + s->avctx->codec->capabilities&CODEC_CAP_HWACCEL_VDPAU || s->error_count==3*s->mb_width*(s->avctx->skip_top + s->avctx->skip_bottom)) return; if(s->current_picture.motion_val[0] == NULL){ diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 53cb83890d..a8bd0622a4 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -7647,7 +7647,7 @@ static int decode_frame(AVCodecContext *avctx, * past end by one (callers fault) and resync_mb_y != 0 * causes problems for the first MB line, too. */ - if (avctx->codec_id != CODEC_ID_H264_VDPAU && !FIELD_PICTURE) + if (!FIELD_PICTURE) ff_er_frame_end(s); MPV_frame_end(s); -- cgit v1.2.3