diff options
author | Ivan Kalvachev <ikalvachev@gmail.com> | 2007-09-28 20:38:32 +0000 |
---|---|---|
committer | Ivan Kalvachev <ikalvachev@gmail.com> | 2007-09-28 20:38:32 +0000 |
commit | 551109d48a16e6d8cbddbdb608bb2ddd36278b67 (patch) | |
tree | f2b4aa4b721951f3843bf4ea9c2f9ee3514d6225 | |
parent | a1748c6744d0ec582b8585cfaad0d233dbb4709a (diff) | |
download | ffmpeg-551109d48a16e6d8cbddbdb608bb2ddd36278b67.tar.gz |
On bitstream error is_intra_more_likely() could use dsp.sad[0]() that will segfault when xvmc is in use.
Originally committed as revision 10610 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavcodec/error_resilience.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libavcodec/error_resilience.c b/libavcodec/error_resilience.c index 3a15f267ef..1fd9474d74 100644 --- a/libavcodec/error_resilience.c +++ b/libavcodec/error_resilience.c @@ -563,6 +563,11 @@ static int is_intra_more_likely(MpegEncContext *s){ if(undamaged_count < 5) return 0; //allmost all MBs damaged -> use temporal prediction +#ifdef HAVE_XVMC + //prevent dsp.sad() check, that requires access to the image + if(s->avctx->xvmc_acceleration && s->pict_type==I_TYPE) return 1; +#endif + skip_amount= FFMAX(undamaged_count/50, 1); //check only upto 50 MBs is_intra_likely=0; |