comparison mjpegdec.c @ 6517:48759bfbd073 libavcodec

Apply 'cold' attribute to init/uninit functions in libavcodec
author zuxy
date Fri, 21 Mar 2008 03:11:20 +0000
parents 7fa807dd7958
children 22cca5d3173a
comparison
equal deleted inserted replaced
6516:dbb902bb2347 6517:48759bfbd073
71 ff_mjpeg_val_ac_luminance, 251, 0, 1); 71 ff_mjpeg_val_ac_luminance, 251, 0, 1);
72 build_vlc(&s->vlcs[1][1], ff_mjpeg_bits_ac_chrominance, 72 build_vlc(&s->vlcs[1][1], ff_mjpeg_bits_ac_chrominance,
73 ff_mjpeg_val_ac_chrominance, 251, 0, 1); 73 ff_mjpeg_val_ac_chrominance, 251, 0, 1);
74 } 74 }
75 75
76 int ff_mjpeg_decode_init(AVCodecContext *avctx) 76 av_cold int ff_mjpeg_decode_init(AVCodecContext *avctx)
77 { 77 {
78 MJpegDecodeContext *s = avctx->priv_data; 78 MJpegDecodeContext *s = avctx->priv_data;
79 79
80 s->avctx = avctx; 80 s->avctx = avctx;
81 dsputil_init(&s->dsp, avctx); 81 dsputil_init(&s->dsp, avctx);
1336 av_log(avctx, AV_LOG_DEBUG, "mjpeg decode frame unused %td bytes\n", buf_end - buf_ptr); 1336 av_log(avctx, AV_LOG_DEBUG, "mjpeg decode frame unused %td bytes\n", buf_end - buf_ptr);
1337 // return buf_end - buf_ptr; 1337 // return buf_end - buf_ptr;
1338 return buf_ptr - buf; 1338 return buf_ptr - buf;
1339 } 1339 }
1340 1340
1341 int ff_mjpeg_decode_end(AVCodecContext *avctx) 1341 av_cold int ff_mjpeg_decode_end(AVCodecContext *avctx)
1342 { 1342 {
1343 MJpegDecodeContext *s = avctx->priv_data; 1343 MJpegDecodeContext *s = avctx->priv_data;
1344 int i, j; 1344 int i, j;
1345 1345
1346 av_free(s->buffer); 1346 av_free(s->buffer);