aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/ffv1.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2010-10-26 23:00:57 +0000
committerMichael Niedermayer <michaelni@gmx.at>2010-10-26 23:00:57 +0000
commit2a317c6be4d73a679e66c3e8633a289dd890cf5e (patch)
tree2a89849c4709e88094d30a932e7fdfded9962cf6 /libavcodec/ffv1.c
parent349d72870f403b884aba08da7be1ce66e72ad39f (diff)
downloadffmpeg-2a317c6be4d73a679e66c3e8633a289dd890cf5e.tar.gz
Factorize litteral constents in ffv1 into STATS_OUT_SIZE.
Originally committed as revision 25578 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/ffv1.c')
-rw-r--r--libavcodec/ffv1.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/libavcodec/ffv1.c b/libavcodec/ffv1.c
index 0f1433b1d5..e9d6796ded 100644
--- a/libavcodec/ffv1.c
+++ b/libavcodec/ffv1.c
@@ -944,7 +944,8 @@ static av_cold int encode_init(AVCodecContext *avctx)
if(init_slice_state(s) < 0)
return -1;
- avctx->stats_out= av_mallocz(1024*30);
+#define STATS_OUT_SIZE 1024*30
+ avctx->stats_out= av_mallocz(STATS_OUT_SIZE);
return 0;
}
@@ -1082,7 +1083,7 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size,
if((avctx->flags&CODEC_FLAG_PASS1) && (f->picture_number&31)==0){
int j;
char *p= avctx->stats_out;
- char *end= p + 1024*30;
+ char *end= p + STATS_OUT_SIZE;
memset(f->rc_stat, 0, sizeof(f->rc_stat));
for(j=0; j<f->slice_count; j++){