aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/utils.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2002-10-31 12:11:53 +0000
committerMichael Niedermayer <michaelni@gmx.at>2002-10-31 12:11:53 +0000
commit6bb925f47dbcb073ee505ed71231c6662aec5ed1 (patch)
tree632a125acfd279103dbda2a230f4fb889908d60e /libavcodec/utils.c
parent0aa7875a730d98f912820e7032d1fc323e1432bb (diff)
downloadffmpeg-6bb925f47dbcb073ee505ed71231c6662aec5ed1.tar.gz
dont call emms_c() for each MB
Originally committed as revision 1127 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/utils.c')
-rw-r--r--libavcodec/utils.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/libavcodec/utils.c b/libavcodec/utils.c
index fcd65364b6..f7449d3b13 100644
--- a/libavcodec/utils.c
+++ b/libavcodec/utils.c
@@ -120,6 +120,9 @@ int avcodec_encode_video(AVCodecContext *avctx, UINT8 *buf, int buf_size,
int ret;
ret = avctx->codec->encode(avctx, buf, buf_size, (void *)pict);
+
+ emms_c(); //needed to avoid a emms_c() call before every return;
+
avctx->frame_number++;
return ret;
}
@@ -135,6 +138,9 @@ int avcodec_decode_video(AVCodecContext *avctx, AVPicture *picture,
ret = avctx->codec->decode(avctx, picture, got_picture_ptr,
buf, buf_size);
+
+ emms_c(); //needed to avoid a emms_c() call before every return;
+
if (*got_picture_ptr)
avctx->frame_number++;
return ret;