Originally committed as revision 12525 to svn://svn.ffmpeg.org/ffmpeg/trunktags/v0.5
| @@ -235,7 +235,7 @@ static void idct(DCTELEM block[64]){ | |||||
| } | } | ||||
| } | } | ||||
| static void init_vlcs(FourXContext *f){ | |||||
| static av_cold void init_vlcs(FourXContext *f){ | |||||
| int i; | int i; | ||||
| for(i=0; i<8; i++){ | for(i=0; i<8; i++){ | ||||
| @@ -792,7 +792,7 @@ static void common_init(AVCodecContext *avctx){ | |||||
| f->avctx= avctx; | f->avctx= avctx; | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int decode_init(AVCodecContext *avctx){ | |||||
| FourXContext * const f = avctx->priv_data; | FourXContext * const f = avctx->priv_data; | ||||
| if(avctx->extradata_size != 4 || !avctx->extradata) { | if(avctx->extradata_size != 4 || !avctx->extradata) { | ||||
| @@ -811,7 +811,7 @@ static int decode_init(AVCodecContext *avctx){ | |||||
| } | } | ||||
| static int decode_end(AVCodecContext *avctx){ | |||||
| static av_cold int decode_end(AVCodecContext *avctx){ | |||||
| FourXContext * const f = avctx->priv_data; | FourXContext * const f = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -148,7 +148,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, const | |||||
| * Init 8BPS decoder | * Init 8BPS decoder | ||||
| * | * | ||||
| */ | */ | ||||
| static int decode_init(AVCodecContext *avctx) | |||||
| static av_cold int decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| EightBpsContext * const c = avctx->priv_data; | EightBpsContext * const c = avctx->priv_data; | ||||
| @@ -208,7 +208,7 @@ static int decode_init(AVCodecContext *avctx) | |||||
| * Uninit 8BPS decoder | * Uninit 8BPS decoder | ||||
| * | * | ||||
| */ | */ | ||||
| static int decode_end(AVCodecContext *avctx) | |||||
| static av_cold int decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| EightBpsContext * const c = avctx->priv_data; | EightBpsContext * const c = avctx->priv_data; | ||||
| @@ -81,7 +81,7 @@ static int aac_sync(const uint8_t *buf, int *channels, int *sample_rate, | |||||
| return size; | return size; | ||||
| } | } | ||||
| static int aac_parse_init(AVCodecParserContext *s1) | |||||
| static av_cold int aac_parse_init(AVCodecParserContext *s1) | |||||
| { | { | ||||
| AACAC3ParseContext *s = s1->priv_data; | AACAC3ParseContext *s = s1->priv_data; | ||||
| s->inbuf_ptr = s->inbuf; | s->inbuf_ptr = s->inbuf; | ||||
| @@ -44,7 +44,7 @@ typedef struct AascContext { | |||||
| } \ | } \ | ||||
| stream_byte = buf[stream_ptr++]; | stream_byte = buf[stream_ptr++]; | ||||
| static int aasc_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int aasc_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| AascContext *s = avctx->priv_data; | AascContext *s = avctx->priv_data; | ||||
| @@ -150,7 +150,7 @@ static int aasc_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int aasc_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int aasc_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| AascContext *s = avctx->priv_data; | AascContext *s = avctx->priv_data; | ||||
| @@ -223,7 +223,7 @@ void ac3_parametric_bit_allocation(AC3BitAllocParameters *s, uint8_t *bap, | |||||
| * note: This function must remain thread safe because it is called by the | * note: This function must remain thread safe because it is called by the | ||||
| * AVParser init code. | * AVParser init code. | ||||
| */ | */ | ||||
| void ac3_common_init(void) | |||||
| av_cold void ac3_common_init(void) | |||||
| { | { | ||||
| int i, j, k, l, v; | int i, j, k, l, v; | ||||
| /* compute bndtab and masktab from bandsz */ | /* compute bndtab and masktab from bandsz */ | ||||
| @@ -137,7 +137,7 @@ static int ac3_sync(const uint8_t *buf, int *channels, int *sample_rate, | |||||
| return hdr.frame_size; | return hdr.frame_size; | ||||
| } | } | ||||
| static int ac3_parse_init(AVCodecParserContext *s1) | |||||
| static av_cold int ac3_parse_init(AVCodecParserContext *s1) | |||||
| { | { | ||||
| AACAC3ParseContext *s = s1->priv_data; | AACAC3ParseContext *s = s1->priv_data; | ||||
| s->inbuf_ptr = s->inbuf; | s->inbuf_ptr = s->inbuf; | ||||
| @@ -207,7 +207,7 @@ symmetric_dequant(int code, int levels) | |||||
| /* | /* | ||||
| * Initialize tables at runtime. | * Initialize tables at runtime. | ||||
| */ | */ | ||||
| static void ac3_tables_init(void) | |||||
| static av_cold void ac3_tables_init(void) | |||||
| { | { | ||||
| int i; | int i; | ||||
| @@ -260,7 +260,7 @@ static void ac3_tables_init(void) | |||||
| /** | /** | ||||
| * AVCodec initialization | * AVCodec initialization | ||||
| */ | */ | ||||
| static int ac3_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int ac3_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| AC3DecodeContext *s = avctx->priv_data; | AC3DecodeContext *s = avctx->priv_data; | ||||
| s->avctx = avctx; | s->avctx = avctx; | ||||
| @@ -1209,7 +1209,7 @@ static int ac3_decode_frame(AVCodecContext * avctx, void *data, int *data_size, | |||||
| /** | /** | ||||
| * Uninitialize the AC-3 decoder. | * Uninitialize the AC-3 decoder. | ||||
| */ | */ | ||||
| static int ac3_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int ac3_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| AC3DecodeContext *s = avctx->priv_data; | AC3DecodeContext *s = avctx->priv_data; | ||||
| ff_mdct_end(&s->imdct_512); | ff_mdct_end(&s->imdct_512); | ||||
| @@ -608,7 +608,7 @@ static int compute_bit_allocation(AC3EncodeContext *s, | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int AC3_encode_init(AVCodecContext *avctx) | |||||
| static av_cold int AC3_encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| int freq = avctx->sample_rate; | int freq = avctx->sample_rate; | ||||
| int bitrate = avctx->bit_rate; | int bitrate = avctx->bit_rate; | ||||
| @@ -1255,7 +1255,7 @@ static int AC3_encode_frame(AVCodecContext *avctx, | |||||
| return output_frame_end(s); | return output_frame_end(s); | ||||
| } | } | ||||
| static int AC3_encode_close(AVCodecContext *avctx) | |||||
| static av_cold int AC3_encode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| av_freep(&avctx->coded_frame); | av_freep(&avctx->coded_frame); | ||||
| return 0; | return 0; | ||||
| @@ -663,7 +663,7 @@ static int adpcm_encode_frame(AVCodecContext *avctx, | |||||
| } | } | ||||
| #endif //CONFIG_ENCODERS | #endif //CONFIG_ENCODERS | ||||
| static int adpcm_decode_init(AVCodecContext * avctx) | |||||
| static av_cold int adpcm_decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| ADPCMContext *c = avctx->priv_data; | ADPCMContext *c = avctx->priv_data; | ||||
| unsigned int max_channels = 2; | unsigned int max_channels = 2; | ||||
| @@ -110,7 +110,7 @@ static int adx_encode_header(AVCodecContext *avctx,unsigned char *buf,size_t buf | |||||
| return 0x20+4; | return 0x20+4; | ||||
| } | } | ||||
| static int adx_encode_init(AVCodecContext *avctx) | |||||
| static av_cold int adx_encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| if (avctx->channels > 2) | if (avctx->channels > 2) | ||||
| return -1; /* only stereo or mono =) */ | return -1; /* only stereo or mono =) */ | ||||
| @@ -126,7 +126,7 @@ static int adx_encode_init(AVCodecContext *avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int adx_encode_close(AVCodecContext *avctx) | |||||
| static av_cold int adx_encode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| av_freep(&avctx->coded_frame); | av_freep(&avctx->coded_frame); | ||||
| @@ -624,7 +624,7 @@ static int alac_decode_frame(AVCodecContext *avctx, | |||||
| return input_buffer_size; | return input_buffer_size; | ||||
| } | } | ||||
| static int alac_decode_init(AVCodecContext * avctx) | |||||
| static av_cold int alac_decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| ALACContext *alac = avctx->priv_data; | ALACContext *alac = avctx->priv_data; | ||||
| alac->avctx = avctx; | alac->avctx = avctx; | ||||
| @@ -637,7 +637,7 @@ static int alac_decode_init(AVCodecContext * avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int alac_decode_close(AVCodecContext *avctx) | |||||
| static av_cold int alac_decode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| ALACContext *alac = avctx->priv_data; | ALACContext *alac = avctx->priv_data; | ||||
| @@ -185,7 +185,7 @@ static inline int32_t scalarproduct(int16_t * v1, int16_t * v2, int order) | |||||
| return res; | return res; | ||||
| } | } | ||||
| static int ape_decode_init(AVCodecContext * avctx) | |||||
| static av_cold int ape_decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| APEContext *s = avctx->priv_data; | APEContext *s = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -224,7 +224,7 @@ static int ape_decode_init(AVCodecContext * avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int ape_decode_close(AVCodecContext * avctx) | |||||
| static av_cold int ape_decode_close(AVCodecContext * avctx) | |||||
| { | { | ||||
| APEContext *s = avctx->priv_data; | APEContext *s = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -113,7 +113,7 @@ static VLC dc_ccp_vlc; | |||||
| static VLC ac_ccp_vlc; | static VLC ac_ccp_vlc; | ||||
| static VLC asv2_level_vlc; | static VLC asv2_level_vlc; | ||||
| static void init_vlcs(ASV1Context *a){ | |||||
| static av_cold void init_vlcs(ASV1Context *a){ | |||||
| static int done = 0; | static int done = 0; | ||||
| if (!done) { | if (!done) { | ||||
| @@ -521,7 +521,7 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size, | |||||
| } | } | ||||
| #endif /* CONFIG_ENCODERS */ | #endif /* CONFIG_ENCODERS */ | ||||
| static void common_init(AVCodecContext *avctx){ | |||||
| static av_cold void common_init(AVCodecContext *avctx){ | |||||
| ASV1Context * const a = avctx->priv_data; | ASV1Context * const a = avctx->priv_data; | ||||
| dsputil_init(&a->dsp, avctx); | dsputil_init(&a->dsp, avctx); | ||||
| @@ -535,7 +535,7 @@ static void common_init(AVCodecContext *avctx){ | |||||
| a->avctx= avctx; | a->avctx= avctx; | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int decode_init(AVCodecContext *avctx){ | |||||
| ASV1Context * const a = avctx->priv_data; | ASV1Context * const a = avctx->priv_data; | ||||
| AVFrame *p= (AVFrame*)&a->picture; | AVFrame *p= (AVFrame*)&a->picture; | ||||
| int i; | int i; | ||||
| @@ -570,7 +570,7 @@ static int decode_init(AVCodecContext *avctx){ | |||||
| } | } | ||||
| #ifdef CONFIG_ENCODERS | #ifdef CONFIG_ENCODERS | ||||
| static int encode_init(AVCodecContext *avctx){ | |||||
| static av_cold int encode_init(AVCodecContext *avctx){ | |||||
| ASV1Context * const a = avctx->priv_data; | ASV1Context * const a = avctx->priv_data; | ||||
| int i; | int i; | ||||
| const int scale= avctx->codec_id == CODEC_ID_ASV1 ? 1 : 2; | const int scale= avctx->codec_id == CODEC_ID_ASV1 ? 1 : 2; | ||||
| @@ -595,7 +595,7 @@ static int encode_init(AVCodecContext *avctx){ | |||||
| } | } | ||||
| #endif | #endif | ||||
| static int decode_end(AVCodecContext *avctx){ | |||||
| static av_cold int decode_end(AVCodecContext *avctx){ | |||||
| ASV1Context * const a = avctx->priv_data; | ASV1Context * const a = avctx->priv_data; | ||||
| av_freep(&a->bitstream_buffer); | av_freep(&a->bitstream_buffer); | ||||
| @@ -142,7 +142,7 @@ avs_decode_frame(AVCodecContext * avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int avs_decode_init(AVCodecContext * avctx) | |||||
| static av_cold int avs_decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| avctx->pix_fmt = PIX_FMT_PAL8; | avctx->pix_fmt = PIX_FMT_PAL8; | ||||
| return 0; | return 0; | ||||
| @@ -36,7 +36,7 @@ typedef struct BethsoftvidContext { | |||||
| AVFrame frame; | AVFrame frame; | ||||
| } BethsoftvidContext; | } BethsoftvidContext; | ||||
| static int bethsoftvid_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int bethsoftvid_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| BethsoftvidContext *vid = avctx->priv_data; | BethsoftvidContext *vid = avctx->priv_data; | ||||
| vid->frame.reference = 1; | vid->frame.reference = 1; | ||||
| @@ -120,7 +120,7 @@ static int bethsoftvid_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int bethsoftvid_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int bethsoftvid_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| BethsoftvidContext * vid = avctx->priv_data; | BethsoftvidContext * vid = avctx->priv_data; | ||||
| if(vid->frame.data[0]) | if(vid->frame.data[0]) | ||||
| @@ -23,7 +23,7 @@ | |||||
| #include "bytestream.h" | #include "bytestream.h" | ||||
| #include "bmp.h" | #include "bmp.h" | ||||
| static int bmp_decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int bmp_decode_init(AVCodecContext *avctx){ | |||||
| BMPContext *s = avctx->priv_data; | BMPContext *s = avctx->priv_data; | ||||
| avcodec_get_frame_defaults((AVFrame*)&s->picture); | avcodec_get_frame_defaults((AVFrame*)&s->picture); | ||||
| @@ -231,7 +231,7 @@ static int bmp_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int bmp_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int bmp_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| BMPContext* c = avctx->priv_data; | BMPContext* c = avctx->priv_data; | ||||
| @@ -23,7 +23,7 @@ | |||||
| #include "bytestream.h" | #include "bytestream.h" | ||||
| #include "bmp.h" | #include "bmp.h" | ||||
| static int bmp_encode_init(AVCodecContext *avctx){ | |||||
| static av_cold int bmp_encode_init(AVCodecContext *avctx){ | |||||
| BMPContext *s = avctx->priv_data; | BMPContext *s = avctx->priv_data; | ||||
| avcodec_get_frame_defaults((AVFrame*)&s->picture); | avcodec_get_frame_defaults((AVFrame*)&s->picture); | ||||
| @@ -45,13 +45,13 @@ typedef enum { | |||||
| #define C93_HAS_PALETTE 0x01 | #define C93_HAS_PALETTE 0x01 | ||||
| #define C93_FIRST_FRAME 0x02 | #define C93_FIRST_FRAME 0x02 | ||||
| static int decode_init(AVCodecContext *avctx) | |||||
| static av_cold int decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| avctx->pix_fmt = PIX_FMT_PAL8; | avctx->pix_fmt = PIX_FMT_PAL8; | ||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int decode_end(AVCodecContext *avctx) | |||||
| static av_cold int decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| C93DecoderContext * const c93 = avctx->priv_data; | C93DecoderContext * const c93 = avctx->priv_data; | ||||
| @@ -668,7 +668,7 @@ void ff_cavs_init_top_lines(AVSContext *h) { | |||||
| h->block = av_mallocz(64*sizeof(DCTELEM)); | h->block = av_mallocz(64*sizeof(DCTELEM)); | ||||
| } | } | ||||
| int ff_cavs_init(AVCodecContext *avctx) { | |||||
| av_cold int ff_cavs_init(AVCodecContext *avctx) { | |||||
| AVSContext *h = avctx->priv_data; | AVSContext *h = avctx->priv_data; | ||||
| MpegEncContext * const s = &h->s; | MpegEncContext * const s = &h->s; | ||||
| @@ -699,7 +699,7 @@ int ff_cavs_init(AVCodecContext *avctx) { | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| int ff_cavs_end(AVCodecContext *avctx) { | |||||
| av_cold int ff_cavs_end(AVCodecContext *avctx) { | |||||
| AVSContext *h = avctx->priv_data; | AVSContext *h = avctx->priv_data; | ||||
| av_free(h->top_qp); | av_free(h->top_qp); | ||||
| @@ -385,7 +385,7 @@ static int cinepak_decode (CinepakContext *s) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int cinepak_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int cinepak_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| CinepakContext *s = avctx->priv_data; | CinepakContext *s = avctx->priv_data; | ||||
| @@ -443,7 +443,7 @@ static int cinepak_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int cinepak_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int cinepak_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| CinepakContext *s = avctx->priv_data; | CinepakContext *s = avctx->priv_data; | ||||
| @@ -105,14 +105,14 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size, | |||||
| } | } | ||||
| #endif | #endif | ||||
| static void common_init(AVCodecContext *avctx){ | |||||
| static av_cold void common_init(AVCodecContext *avctx){ | |||||
| CLJRContext * const a = avctx->priv_data; | CLJRContext * const a = avctx->priv_data; | ||||
| avctx->coded_frame= (AVFrame*)&a->picture; | avctx->coded_frame= (AVFrame*)&a->picture; | ||||
| a->avctx= avctx; | a->avctx= avctx; | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int decode_init(AVCodecContext *avctx){ | |||||
| common_init(avctx); | common_init(avctx); | ||||
| @@ -122,7 +122,7 @@ static int decode_init(AVCodecContext *avctx){ | |||||
| } | } | ||||
| #if 0 | #if 0 | ||||
| static int encode_init(AVCodecContext *avctx){ | |||||
| static av_cold int encode_init(AVCodecContext *avctx){ | |||||
| common_init(avctx); | common_init(avctx); | ||||
| @@ -212,7 +212,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx) { | |||||
| static av_cold int decode_init(AVCodecContext *avctx) { | |||||
| CamStudioContext *c = avctx->priv_data; | CamStudioContext *c = avctx->priv_data; | ||||
| if (avcodec_check_dimensions(avctx, avctx->height, avctx->width) < 0) { | if (avcodec_check_dimensions(avctx, avctx->height, avctx->width) < 0) { | ||||
| return 1; | return 1; | ||||
| @@ -240,7 +240,7 @@ static int decode_init(AVCodecContext *avctx) { | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int decode_end(AVCodecContext *avctx) { | |||||
| static av_cold int decode_end(AVCodecContext *avctx) { | |||||
| CamStudioContext *c = avctx->priv_data; | CamStudioContext *c = avctx->priv_data; | ||||
| av_freep(&c->decomp_buf); | av_freep(&c->decomp_buf); | ||||
| if (c->pic.data[0]) | if (c->pic.data[0]) | ||||
| @@ -43,7 +43,7 @@ typedef struct CyuvDecodeContext { | |||||
| AVFrame frame; | AVFrame frame; | ||||
| } CyuvDecodeContext; | } CyuvDecodeContext; | ||||
| static int cyuv_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int cyuv_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| CyuvDecodeContext *s = avctx->priv_data; | CyuvDecodeContext *s = avctx->priv_data; | ||||
| @@ -163,7 +163,7 @@ static int cyuv_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int cyuv_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int cyuv_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| /* CyuvDecodeContext *s = avctx->priv_data;*/ | /* CyuvDecodeContext *s = avctx->priv_data;*/ | ||||
| @@ -178,7 +178,7 @@ typedef struct { | |||||
| DSPContext dsp; | DSPContext dsp; | ||||
| } DCAContext; | } DCAContext; | ||||
| static void dca_init_vlcs(void) | |||||
| static av_cold void dca_init_vlcs(void) | |||||
| { | { | ||||
| static int vlcs_initialized = 0; | static int vlcs_initialized = 0; | ||||
| int i, j; | int i, j; | ||||
| @@ -1200,7 +1200,7 @@ static int dca_decode_frame(AVCodecContext * avctx, | |||||
| * @param s pointer to the DCAContext | * @param s pointer to the DCAContext | ||||
| */ | */ | ||||
| static void pre_calc_cosmod(DCAContext * s) | |||||
| static av_cold void pre_calc_cosmod(DCAContext * s) | |||||
| { | { | ||||
| int i, j, k; | int i, j, k; | ||||
| static int cosmod_initialized = 0; | static int cosmod_initialized = 0; | ||||
| @@ -1230,7 +1230,7 @@ static void pre_calc_cosmod(DCAContext * s) | |||||
| * @param avctx pointer to the AVCodecContext | * @param avctx pointer to the AVCodecContext | ||||
| */ | */ | ||||
| static int dca_decode_init(AVCodecContext * avctx) | |||||
| static av_cold int dca_decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| DCAContext *s = avctx->priv_data; | DCAContext *s = avctx->priv_data; | ||||
| @@ -84,7 +84,7 @@ static int dca_find_frame_end(DCAParseContext * pc1, const uint8_t * buf, | |||||
| return END_NOT_FOUND; | return END_NOT_FOUND; | ||||
| } | } | ||||
| static int dca_parse_init(AVCodecParserContext * s) | |||||
| static av_cold int dca_parse_init(AVCodecParserContext * s) | |||||
| { | { | ||||
| DCAParseContext *pc1 = s->priv_data; | DCAParseContext *pc1 = s->priv_data; | ||||
| @@ -47,7 +47,7 @@ typedef struct { | |||||
| #define DNXHD_VLC_BITS 9 | #define DNXHD_VLC_BITS 9 | ||||
| #define DNXHD_DC_VLC_BITS 7 | #define DNXHD_DC_VLC_BITS 7 | ||||
| static int dnxhd_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int dnxhd_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| DNXHDContext *ctx = avctx->priv_data; | DNXHDContext *ctx = avctx->priv_data; | ||||
| @@ -320,7 +320,7 @@ static int dnxhd_decode_frame(AVCodecContext *avctx, void *data, int *data_size, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int dnxhd_decode_close(AVCodecContext *avctx) | |||||
| static av_cold int dnxhd_decode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| DNXHDContext *ctx = avctx->priv_data; | DNXHDContext *ctx = avctx->priv_data; | ||||
| @@ -110,7 +110,7 @@ static const int sol_table_16[128] = { | |||||
| static int dpcm_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int dpcm_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| DPCMContext *s = avctx->priv_data; | DPCMContext *s = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -86,7 +86,7 @@ static const int16_t cinaudio_delta16_table[256] = { | |||||
| }; | }; | ||||
| static int cinvideo_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int cinvideo_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| CinVideoContext *cin = avctx->priv_data; | CinVideoContext *cin = avctx->priv_data; | ||||
| unsigned int i; | unsigned int i; | ||||
| @@ -284,7 +284,7 @@ static int cinvideo_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int cinvideo_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int cinvideo_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| CinVideoContext *cin = avctx->priv_data; | CinVideoContext *cin = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -298,7 +298,7 @@ static int cinvideo_decode_end(AVCodecContext *avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int cinaudio_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int cinaudio_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| CinAudioContext *cin = avctx->priv_data; | CinAudioContext *cin = avctx->priv_data; | ||||
| @@ -107,7 +107,7 @@ static void dv_build_unquantize_tables(DVVideoContext *s, uint8_t* perm) | |||||
| } | } | ||||
| } | } | ||||
| static int dvvideo_init(AVCodecContext *avctx) | |||||
| static av_cold int dvvideo_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| DVVideoContext *s = avctx->priv_data; | DVVideoContext *s = avctx->priv_data; | ||||
| DSPContext dsp; | DSPContext dsp; | ||||
| @@ -38,7 +38,7 @@ typedef struct DVBSubParseContext { | |||||
| int in_packet; | int in_packet; | ||||
| } DVBSubParseContext; | } DVBSubParseContext; | ||||
| static int dvbsub_parse_init(AVCodecParserContext *s) | |||||
| static av_cold int dvbsub_parse_init(AVCodecParserContext *s) | |||||
| { | { | ||||
| DVBSubParseContext *pc = s->priv_data; | DVBSubParseContext *pc = s->priv_data; | ||||
| pc->packet_buf = av_malloc(PARSE_BUF_SIZE); | pc->packet_buf = av_malloc(PARSE_BUF_SIZE); | ||||
| @@ -181,7 +181,7 @@ static int dvbsub_parse(AVCodecParserContext *s, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static void dvbsub_parse_close(AVCodecParserContext *s) | |||||
| static av_cold void dvbsub_parse_close(AVCodecParserContext *s) | |||||
| { | { | ||||
| DVBSubParseContext *pc = s->priv_data; | DVBSubParseContext *pc = s->priv_data; | ||||
| av_freep(&pc->packet_buf); | av_freep(&pc->packet_buf); | ||||
| @@ -338,7 +338,7 @@ static void delete_state(DVBSubContext *ctx) | |||||
| av_log(0, AV_LOG_ERROR, "Memory deallocation error!\n"); | av_log(0, AV_LOG_ERROR, "Memory deallocation error!\n"); | ||||
| } | } | ||||
| static int dvbsub_init_decoder(AVCodecContext *avctx) | |||||
| static av_cold int dvbsub_init_decoder(AVCodecContext *avctx) | |||||
| { | { | ||||
| int i, r, g, b, a = 0; | int i, r, g, b, a = 0; | ||||
| DVBSubContext *ctx = (DVBSubContext*) avctx->priv_data; | DVBSubContext *ctx = (DVBSubContext*) avctx->priv_data; | ||||
| @@ -411,7 +411,7 @@ static int dvbsub_init_decoder(AVCodecContext *avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int dvbsub_close_decoder(AVCodecContext *avctx) | |||||
| static av_cold int dvbsub_close_decoder(AVCodecContext *avctx) | |||||
| { | { | ||||
| DVBSubContext *ctx = (DVBSubContext*) avctx->priv_data; | DVBSubContext *ctx = (DVBSubContext*) avctx->priv_data; | ||||
| DVBSubRegionDisplay *display; | DVBSubRegionDisplay *display; | ||||
| @@ -285,7 +285,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, const | |||||
| return orig_buf_size; | return orig_buf_size; | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx) | |||||
| static av_cold int decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| DxaDecContext * const c = avctx->priv_data; | DxaDecContext * const c = avctx->priv_data; | ||||
| @@ -305,7 +305,7 @@ static int decode_init(AVCodecContext *avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int decode_end(AVCodecContext *avctx) | |||||
| static av_cold int decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| DxaDecContext * const c = avctx->priv_data; | DxaDecContext * const c = avctx->priv_data; | ||||
| @@ -530,7 +530,7 @@ static void write_header(FFV1Context *f){ | |||||
| } | } | ||||
| #endif /* CONFIG_ENCODERS */ | #endif /* CONFIG_ENCODERS */ | ||||
| static int common_init(AVCodecContext *avctx){ | |||||
| static av_cold int common_init(AVCodecContext *avctx){ | |||||
| FFV1Context *s = avctx->priv_data; | FFV1Context *s = avctx->priv_data; | ||||
| int width, height; | int width, height; | ||||
| @@ -548,7 +548,7 @@ static int common_init(AVCodecContext *avctx){ | |||||
| } | } | ||||
| #ifdef CONFIG_ENCODERS | #ifdef CONFIG_ENCODERS | ||||
| static int encode_init(AVCodecContext *avctx) | |||||
| static av_cold int encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| FFV1Context *s = avctx->priv_data; | FFV1Context *s = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -694,7 +694,7 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size, | |||||
| } | } | ||||
| #endif /* CONFIG_ENCODERS */ | #endif /* CONFIG_ENCODERS */ | ||||
| static int common_end(AVCodecContext *avctx){ | |||||
| static av_cold int common_end(AVCodecContext *avctx){ | |||||
| FFV1Context *s = avctx->priv_data; | FFV1Context *s = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -927,7 +927,7 @@ static int read_header(FFV1Context *f){ | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx) | |||||
| static av_cold int decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| // FFV1Context *s = avctx->priv_data; | // FFV1Context *s = avctx->priv_data; | ||||
| @@ -98,7 +98,7 @@ static void metadata_streaminfo(FLACContext *s); | |||||
| static void allocate_buffers(FLACContext *s); | static void allocate_buffers(FLACContext *s); | ||||
| static int metadata_parse(FLACContext *s); | static int metadata_parse(FLACContext *s); | ||||
| static int flac_decode_init(AVCodecContext * avctx) | |||||
| static av_cold int flac_decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| FLACContext *s = avctx->priv_data; | FLACContext *s = avctx->priv_data; | ||||
| s->avctx = avctx; | s->avctx = avctx; | ||||
| @@ -737,7 +737,7 @@ end: | |||||
| return i; | return i; | ||||
| } | } | ||||
| static int flac_decode_close(AVCodecContext *avctx) | |||||
| static av_cold int flac_decode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| FLACContext *s = avctx->priv_data; | FLACContext *s = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -169,7 +169,7 @@ static int select_blocksize(int samplerate, int block_time_ms) | |||||
| return blocksize; | return blocksize; | ||||
| } | } | ||||
| static int flac_encode_init(AVCodecContext *avctx) | |||||
| static av_cold int flac_encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| int freq = avctx->sample_rate; | int freq = avctx->sample_rate; | ||||
| int channels = avctx->channels; | int channels = avctx->channels; | ||||
| @@ -1486,7 +1486,7 @@ static int flac_encode_frame(AVCodecContext *avctx, uint8_t *frame, | |||||
| return out_bytes; | return out_bytes; | ||||
| } | } | ||||
| static int flac_encode_close(AVCodecContext *avctx) | |||||
| static av_cold int flac_encode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| av_freep(&avctx->extradata); | av_freep(&avctx->extradata); | ||||
| avctx->extradata_size = 0; | avctx->extradata_size = 0; | ||||
| @@ -79,7 +79,7 @@ static void copy_region(uint8_t *sptr, uint8_t *dptr, | |||||
| } | } | ||||
| static int flashsv_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int flashsv_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| FlashSVContext *s = avctx->priv_data; | FlashSVContext *s = avctx->priv_data; | ||||
| int zret; // Zlib return code | int zret; // Zlib return code | ||||
| @@ -228,7 +228,7 @@ static int flashsv_decode_frame(AVCodecContext *avctx, | |||||
| } | } | ||||
| static int flashsv_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int flashsv_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| FlashSVContext *s = avctx->priv_data; | FlashSVContext *s = avctx->priv_data; | ||||
| inflateEnd(&(s->zstream)); | inflateEnd(&(s->zstream)); | ||||
| @@ -97,7 +97,7 @@ static int copy_region_enc(uint8_t *sptr, uint8_t *dptr, | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int flashsv_encode_init(AVCodecContext *avctx) | |||||
| static av_cold int flashsv_encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| FlashSVContext *s = avctx->priv_data; | FlashSVContext *s = avctx->priv_data; | ||||
| @@ -271,7 +271,7 @@ static int flashsv_encode_frame(AVCodecContext *avctx, uint8_t *buf, int buf_siz | |||||
| return res; | return res; | ||||
| } | } | ||||
| static int flashsv_encode_end(AVCodecContext *avctx) | |||||
| static av_cold int flashsv_encode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| FlashSVContext *s = avctx->priv_data; | FlashSVContext *s = avctx->priv_data; | ||||
| @@ -76,7 +76,7 @@ typedef struct FlicDecodeContext { | |||||
| int fli_type; /* either 0xAF11 or 0xAF12, affects palette resolution */ | int fli_type; /* either 0xAF11 or 0xAF12, affects palette resolution */ | ||||
| } FlicDecodeContext; | } FlicDecodeContext; | ||||
| static int flic_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int flic_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| FlicDecodeContext *s = avctx->priv_data; | FlicDecodeContext *s = avctx->priv_data; | ||||
| unsigned char *fli_header = (unsigned char *)avctx->extradata; | unsigned char *fli_header = (unsigned char *)avctx->extradata; | ||||
| @@ -726,7 +726,7 @@ static int flic_decode_frame(AVCodecContext *avctx, | |||||
| } | } | ||||
| static int flic_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int flic_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| FlicDecodeContext *s = avctx->priv_data; | FlicDecodeContext *s = avctx->priv_data; | ||||
| @@ -55,7 +55,7 @@ typedef struct FrapsContext{ | |||||
| * @param avctx codec context | * @param avctx codec context | ||||
| * @return 0 on success or negative if fails | * @return 0 on success or negative if fails | ||||
| */ | */ | ||||
| static int decode_init(AVCodecContext *avctx) | |||||
| static av_cold int decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| FrapsContext * const s = avctx->priv_data; | FrapsContext * const s = avctx->priv_data; | ||||
| @@ -343,7 +343,7 @@ static int decode_frame(AVCodecContext *avctx, | |||||
| * @param avctx codec context | * @param avctx codec context | ||||
| * @return 0 on success or negative if fails | * @return 0 on success or negative if fails | ||||
| */ | */ | ||||
| static int decode_end(AVCodecContext *avctx) | |||||
| static av_cold int decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| FrapsContext *s = (FrapsContext*)avctx->priv_data; | FrapsContext *s = (FrapsContext*)avctx->priv_data; | ||||
| @@ -266,7 +266,7 @@ static inline int16_t g726_iterate(G726Context* c, int16_t I) | |||||
| return av_clip(re_signal << 2, -0xffff, 0xffff); | return av_clip(re_signal << 2, -0xffff, 0xffff); | ||||
| } | } | ||||
| static int g726_reset(G726Context* c, int bit_rate) | |||||
| static av_cold int g726_reset(G726Context* c, int bit_rate) | |||||
| { | { | ||||
| int i; | int i; | ||||
| @@ -319,7 +319,7 @@ typedef struct AVG726Context { | |||||
| int code_size; | int code_size; | ||||
| } AVG726Context; | } AVG726Context; | ||||
| static int g726_init(AVCodecContext * avctx) | |||||
| static av_cold int g726_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| AVG726Context* c = (AVG726Context*)avctx->priv_data; | AVG726Context* c = (AVG726Context*)avctx->priv_data; | ||||
| @@ -346,7 +346,7 @@ static int g726_init(AVCodecContext * avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int g726_close(AVCodecContext *avctx) | |||||
| static av_cold int g726_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| av_freep(&avctx->coded_frame); | av_freep(&avctx->coded_frame); | ||||
| return 0; | return 0; | ||||
| @@ -308,7 +308,7 @@ typedef struct { | |||||
| AVFrame picture; | AVFrame picture; | ||||
| } GIFContext; | } GIFContext; | ||||
| static int gif_encode_init(AVCodecContext *avctx) | |||||
| static av_cold int gif_encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| GIFContext *s = avctx->priv_data; | GIFContext *s = avctx->priv_data; | ||||
| @@ -269,7 +269,7 @@ static int gif_parse_next_image(GifState *s) | |||||
| return -1; | return -1; | ||||
| } | } | ||||
| static int gif_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int gif_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| GifState *s = avctx->priv_data; | GifState *s = avctx->priv_data; | ||||
| @@ -314,7 +314,7 @@ static int gif_decode_frame(AVCodecContext *avctx, void *data, int *data_size, c | |||||
| return s->bytestream - buf; | return s->bytestream - buf; | ||||
| } | } | ||||
| static int gif_decode_close(AVCodecContext *avctx) | |||||
| static av_cold int gif_decode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| GifState *s = avctx->priv_data; | GifState *s = avctx->priv_data; | ||||
| @@ -48,7 +48,7 @@ static VLC h261_cbp_vlc; | |||||
| static int h261_decode_block(H261Context * h, DCTELEM * block, int n, int coded); | static int h261_decode_block(H261Context * h, DCTELEM * block, int n, int coded); | ||||
| static void h261_decode_init_vlc(H261Context *h){ | |||||
| static av_cold void h261_decode_init_vlc(H261Context *h){ | |||||
| static int done = 0; | static int done = 0; | ||||
| if(!done){ | if(!done){ | ||||
| @@ -70,7 +70,7 @@ static void h261_decode_init_vlc(H261Context *h){ | |||||
| } | } | ||||
| } | } | ||||
| static int h261_decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int h261_decode_init(AVCodecContext *avctx){ | |||||
| H261Context *h= avctx->priv_data; | H261Context *h= avctx->priv_data; | ||||
| MpegEncContext * const s = &h->s; | MpegEncContext * const s = &h->s; | ||||
| @@ -628,7 +628,7 @@ assert(s->current_picture.pict_type == s->pict_type); | |||||
| return get_consumed_bytes(s, buf_size); | return get_consumed_bytes(s, buf_size); | ||||
| } | } | ||||
| static int h261_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int h261_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| H261Context *h= avctx->priv_data; | H261Context *h= avctx->priv_data; | ||||
| MpegEncContext *s = &h->s; | MpegEncContext *s = &h->s; | ||||
| @@ -35,7 +35,7 @@ | |||||
| //#define DEBUG | //#define DEBUG | ||||
| //#define PRINT_FRAME_TIME | //#define PRINT_FRAME_TIME | ||||
| int ff_h263_decode_init(AVCodecContext *avctx) | |||||
| av_cold int ff_h263_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| MpegEncContext *s = avctx->priv_data; | MpegEncContext *s = avctx->priv_data; | ||||
| @@ -119,7 +119,7 @@ int ff_h263_decode_init(AVCodecContext *avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| int ff_h263_decode_end(AVCodecContext *avctx) | |||||
| av_cold int ff_h263_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| MpegEncContext *s = avctx->priv_data; | MpegEncContext *s = avctx->priv_data; | ||||
| @@ -1952,7 +1952,7 @@ static void hl_motion(H264Context *h, uint8_t *dest_y, uint8_t *dest_cb, uint8_t | |||||
| prefetch_motion(h, 1); | prefetch_motion(h, 1); | ||||
| } | } | ||||
| static void decode_init_vlc(void){ | |||||
| static av_cold void decode_init_vlc(void){ | |||||
| static int done = 0; | static int done = 0; | ||||
| if (!done) { | if (!done) { | ||||
| @@ -2166,7 +2166,7 @@ fail: | |||||
| return -1; // free_tables will clean up for us | return -1; // free_tables will clean up for us | ||||
| } | } | ||||
| static void common_init(H264Context *h){ | |||||
| static av_cold void common_init(H264Context *h){ | |||||
| MpegEncContext * const s = &h->s; | MpegEncContext * const s = &h->s; | ||||
| s->width = s->avctx->width; | s->width = s->avctx->width; | ||||
| @@ -2183,7 +2183,7 @@ static void common_init(H264Context *h){ | |||||
| memset(h->pps.scaling_matrix8, 16, 2*64*sizeof(uint8_t)); | memset(h->pps.scaling_matrix8, 16, 2*64*sizeof(uint8_t)); | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int decode_init(AVCodecContext *avctx){ | |||||
| H264Context *h= avctx->priv_data; | H264Context *h= avctx->priv_data; | ||||
| MpegEncContext * const s = &h->s; | MpegEncContext * const s = &h->s; | ||||
| @@ -8054,7 +8054,7 @@ int main(void){ | |||||
| #endif /* TEST */ | #endif /* TEST */ | ||||
| static int decode_end(AVCodecContext *avctx) | |||||
| static av_cold int decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| H264Context *h = avctx->priv_data; | H264Context *h = avctx->priv_data; | ||||
| MpegEncContext *s = &h->s; | MpegEncContext *s = &h->s; | ||||
| @@ -478,7 +478,7 @@ static int common_init(AVCodecContext *avctx){ | |||||
| } | } | ||||
| #ifdef CONFIG_DECODERS | #ifdef CONFIG_DECODERS | ||||
| static int decode_init(AVCodecContext *avctx) | |||||
| static av_cold int decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| HYuvContext *s = avctx->priv_data; | HYuvContext *s = avctx->priv_data; | ||||
| @@ -599,7 +599,7 @@ static int store_table(HYuvContext *s, uint8_t *len, uint8_t *buf){ | |||||
| return index; | return index; | ||||
| } | } | ||||
| static int encode_init(AVCodecContext *avctx) | |||||
| static av_cold int encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| HYuvContext *s = avctx->priv_data; | HYuvContext *s = avctx->priv_data; | ||||
| int i, j; | int i, j; | ||||
| @@ -1210,7 +1210,7 @@ static int common_end(HYuvContext *s){ | |||||
| } | } | ||||
| #ifdef CONFIG_DECODERS | #ifdef CONFIG_DECODERS | ||||
| static int decode_end(AVCodecContext *avctx) | |||||
| static av_cold int decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| HYuvContext *s = avctx->priv_data; | HYuvContext *s = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -1420,7 +1420,7 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size, | |||||
| return size*4; | return size*4; | ||||
| } | } | ||||
| static int encode_end(AVCodecContext *avctx) | |||||
| static av_cold int encode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| HYuvContext *s = avctx->priv_data; | HYuvContext *s = avctx->priv_data; | ||||
| @@ -113,7 +113,7 @@ static int huff_smallest_node(hnode_t *hnodes, int num_hnodes) { | |||||
| * num_huff_nodes[prev] - contains the index to the root node of the tree. | * num_huff_nodes[prev] - contains the index to the root node of the tree. | ||||
| * That is: huff_nodes[prev][num_huff_nodes[prev]] is the root node. | * That is: huff_nodes[prev][num_huff_nodes[prev]] is the root node. | ||||
| */ | */ | ||||
| static void huff_build_tree(IdcinContext *s, int prev) { | |||||
| static av_cold void huff_build_tree(IdcinContext *s, int prev) { | |||||
| hnode_t *node, *hnodes; | hnode_t *node, *hnodes; | ||||
| int num_hnodes, i; | int num_hnodes, i; | ||||
| @@ -143,7 +143,7 @@ static void huff_build_tree(IdcinContext *s, int prev) { | |||||
| s->num_huff_nodes[prev] = num_hnodes - 1; | s->num_huff_nodes[prev] = num_hnodes - 1; | ||||
| } | } | ||||
| static int idcin_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int idcin_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| IdcinContext *s = avctx->priv_data; | IdcinContext *s = avctx->priv_data; | ||||
| int i, j, histogram_index = 0; | int i, j, histogram_index = 0; | ||||
| @@ -242,7 +242,7 @@ static int idcin_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int idcin_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int idcin_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| IdcinContext *s = avctx->priv_data; | IdcinContext *s = avctx->priv_data; | ||||
| @@ -90,7 +90,7 @@ typedef struct { | |||||
| } IMCContext; | } IMCContext; | ||||
| static int imc_decode_init(AVCodecContext * avctx) | |||||
| static av_cold int imc_decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| int i, j; | int i, j; | ||||
| IMCContext *q = avctx->priv_data; | IMCContext *q = avctx->priv_data; | ||||
| @@ -796,7 +796,7 @@ static int imc_decode_frame(AVCodecContext * avctx, | |||||
| } | } | ||||
| static int imc_decode_close(AVCodecContext * avctx) | |||||
| static av_cold int imc_decode_close(AVCodecContext * avctx) | |||||
| { | { | ||||
| IMCContext *q = avctx->priv_data; | IMCContext *q = avctx->priv_data; | ||||
| @@ -188,7 +188,7 @@ static int ir2_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int ir2_decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int ir2_decode_init(AVCodecContext *avctx){ | |||||
| Ir2Context * const ic = avctx->priv_data; | Ir2Context * const ic = avctx->priv_data; | ||||
| ic->avctx = avctx; | ic->avctx = avctx; | ||||
| @@ -62,7 +62,7 @@ static const int corrector_type_0[24] = { | |||||
| static const int corrector_type_2[8] = { 9, 7, 6, 8, 5, 4, 3, 2 }; | static const int corrector_type_2[8] = { 9, 7, 6, 8, 5, 4, 3, 2 }; | ||||
| static void build_modpred(Indeo3DecodeContext *s) | |||||
| static av_cold void build_modpred(Indeo3DecodeContext *s) | |||||
| { | { | ||||
| int i, j; | int i, j; | ||||
| @@ -97,7 +97,7 @@ static void iv_Decode_Chunk(Indeo3DecodeContext *s, unsigned char *cur, | |||||
| const unsigned char *buf2, int min_width_160); | const unsigned char *buf2, int min_width_160); | ||||
| /* ---------------------------------------------------------------------- */ | /* ---------------------------------------------------------------------- */ | ||||
| static void iv_alloc_frames(Indeo3DecodeContext *s) | |||||
| static av_cold void iv_alloc_frames(Indeo3DecodeContext *s) | |||||
| { | { | ||||
| int luma_width, luma_height, luma_pixels, chroma_width, chroma_height, | int luma_width, luma_height, luma_pixels, chroma_width, chroma_height, | ||||
| chroma_pixels, i; | chroma_pixels, i; | ||||
| @@ -155,7 +155,7 @@ static void iv_alloc_frames(Indeo3DecodeContext *s) | |||||
| } | } | ||||
| /* ---------------------------------------------------------------------- */ | /* ---------------------------------------------------------------------- */ | ||||
| static void iv_free_func(Indeo3DecodeContext *s) | |||||
| static av_cold void iv_free_func(Indeo3DecodeContext *s) | |||||
| { | { | ||||
| int i; | int i; | ||||
| @@ -1048,7 +1048,7 @@ static void iv_Decode_Chunk(Indeo3DecodeContext *s, | |||||
| } | } | ||||
| } | } | ||||
| static int indeo3_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int indeo3_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| Indeo3DecodeContext *s = avctx->priv_data; | Indeo3DecodeContext *s = avctx->priv_data; | ||||
| @@ -1115,7 +1115,7 @@ static int indeo3_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int indeo3_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int indeo3_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| Indeo3DecodeContext *s = avctx->priv_data; | Indeo3DecodeContext *s = avctx->priv_data; | ||||
| @@ -835,7 +835,7 @@ static void ipvideo_decode_opcodes(IpvideoContext *s) | |||||
| } | } | ||||
| } | } | ||||
| static int ipvideo_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int ipvideo_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| IpvideoContext *s = avctx->priv_data; | IpvideoContext *s = avctx->priv_data; | ||||
| @@ -919,7 +919,7 @@ static int ipvideo_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int ipvideo_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int ipvideo_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| IpvideoContext *s = avctx->priv_data; | IpvideoContext *s = avctx->priv_data; | ||||
| @@ -368,7 +368,7 @@ static int encode_picture_ls(AVCodecContext *avctx, unsigned char *buf, int buf_ | |||||
| return put_bits_count(&pb) >> 3; | return put_bits_count(&pb) >> 3; | ||||
| } | } | ||||
| static int encode_init_ls(AVCodecContext *ctx) { | |||||
| static av_cold int encode_init_ls(AVCodecContext *ctx) { | |||||
| JpeglsContext *c = (JpeglsContext*)ctx->priv_data; | JpeglsContext *c = (JpeglsContext*)ctx->priv_data; | ||||
| c->avctx = ctx; | c->avctx = ctx; | ||||
| @@ -338,7 +338,7 @@ static int decode_frame(AVCodecContext * avctx, void *data, int *data_size, cons | |||||
| /* | /* | ||||
| * Init kmvc decoder | * Init kmvc decoder | ||||
| */ | */ | ||||
| static int decode_init(AVCodecContext * avctx) | |||||
| static av_cold int decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| KmvcContext *const c = avctx->priv_data; | KmvcContext *const c = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -390,7 +390,7 @@ static int decode_init(AVCodecContext * avctx) | |||||
| /* | /* | ||||
| * Uninit kmvc decoder | * Uninit kmvc decoder | ||||
| */ | */ | ||||
| static int decode_end(AVCodecContext * avctx) | |||||
| static av_cold int decode_end(AVCodecContext * avctx) | |||||
| { | { | ||||
| KmvcContext *const c = avctx->priv_data; | KmvcContext *const c = avctx->priv_data; | ||||
| @@ -514,7 +514,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, const | |||||
| * Init lcl decoder | * Init lcl decoder | ||||
| * | * | ||||
| */ | */ | ||||
| static int decode_init(AVCodecContext *avctx) | |||||
| static av_cold int decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| LclDecContext * const c = avctx->priv_data; | LclDecContext * const c = avctx->priv_data; | ||||
| unsigned int basesize = avctx->width * avctx->height; | unsigned int basesize = avctx->width * avctx->height; | ||||
| @@ -673,7 +673,7 @@ static int decode_init(AVCodecContext *avctx) | |||||
| * Uninit lcl decoder | * Uninit lcl decoder | ||||
| * | * | ||||
| */ | */ | ||||
| static int decode_end(AVCodecContext *avctx) | |||||
| static av_cold int decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| LclDecContext * const c = avctx->priv_data; | LclDecContext * const c = avctx->priv_data; | ||||
| @@ -139,7 +139,7 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size, | |||||
| * Init lcl encoder | * Init lcl encoder | ||||
| * | * | ||||
| */ | */ | ||||
| static int encode_init(AVCodecContext *avctx) | |||||
| static av_cold int encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| LclEncContext *c = avctx->priv_data; | LclEncContext *c = avctx->priv_data; | ||||
| int zret; // Zlib return code | int zret; // Zlib return code | ||||
| @@ -207,7 +207,7 @@ static int encode_init(AVCodecContext *avctx) | |||||
| * Uninit lcl encoder | * Uninit lcl encoder | ||||
| * | * | ||||
| */ | */ | ||||
| static int encode_end(AVCodecContext *avctx) | |||||
| static av_cold int encode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| LclEncContext *c = avctx->priv_data; | LclEncContext *c = avctx->priv_data; | ||||
| @@ -77,7 +77,7 @@ static void* dlsymm(void* handle, const char* symbol) | |||||
| } | } | ||||
| #endif | #endif | ||||
| static int a52_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int a52_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| AC3DecodeState *s = avctx->priv_data; | AC3DecodeState *s = avctx->priv_data; | ||||
| @@ -203,7 +203,7 @@ static int a52_decode_frame(AVCodecContext *avctx, | |||||
| return len; | return len; | ||||
| } | } | ||||
| static int a52_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int a52_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| AC3DecodeState *s = avctx->priv_data; | AC3DecodeState *s = avctx->priv_data; | ||||
| s->a52_free(s->state); | s->a52_free(s->state); | ||||
| @@ -31,7 +31,7 @@ typedef struct FaacAudioContext { | |||||
| faacEncHandle faac_handle; | faacEncHandle faac_handle; | ||||
| } FaacAudioContext; | } FaacAudioContext; | ||||
| static int Faac_encode_init(AVCodecContext *avctx) | |||||
| static av_cold int Faac_encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| FaacAudioContext *s = avctx->priv_data; | FaacAudioContext *s = avctx->priv_data; | ||||
| faacEncConfigurationPtr faac_cfg; | faacEncConfigurationPtr faac_cfg; | ||||
| @@ -132,7 +132,7 @@ static int Faac_encode_frame(AVCodecContext *avctx, | |||||
| return bytes_written; | return bytes_written; | ||||
| } | } | ||||
| static int Faac_encode_close(AVCodecContext *avctx) | |||||
| static av_cold int Faac_encode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| FaacAudioContext *s = avctx->priv_data; | FaacAudioContext *s = avctx->priv_data; | ||||
| @@ -209,7 +209,7 @@ static int faac_decode_frame(AVCodecContext *avctx, | |||||
| #endif | #endif | ||||
| } | } | ||||
| static int faac_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int faac_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| FAACContext *s = avctx->priv_data; | FAACContext *s = avctx->priv_data; | ||||
| @@ -219,7 +219,7 @@ static int faac_decode_end(AVCodecContext *avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int faac_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int faac_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| FAACContext *s = avctx->priv_data; | FAACContext *s = avctx->priv_data; | ||||
| faacDecConfigurationPtr faac_cfg; | faacDecConfigurationPtr faac_cfg; | ||||
| @@ -35,7 +35,7 @@ | |||||
| #define GSM_MS_BLOCK_SIZE 65 | #define GSM_MS_BLOCK_SIZE 65 | ||||
| #define GSM_FRAME_SIZE 160 | #define GSM_FRAME_SIZE 160 | ||||
| static int libgsm_init(AVCodecContext *avctx) { | |||||
| static av_cold int libgsm_init(AVCodecContext *avctx) { | |||||
| if (avctx->channels > 1 || avctx->sample_rate != 8000 || avctx->bit_rate != 13000) | if (avctx->channels > 1 || avctx->sample_rate != 8000 || avctx->bit_rate != 13000) | ||||
| return -1; | return -1; | ||||
| @@ -60,7 +60,7 @@ static int libgsm_init(AVCodecContext *avctx) { | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int libgsm_close(AVCodecContext *avctx) { | |||||
| static av_cold int libgsm_close(AVCodecContext *avctx) { | |||||
| gsm_destroy(avctx->priv_data); | gsm_destroy(avctx->priv_data); | ||||
| avctx->priv_data = NULL; | avctx->priv_data = NULL; | ||||
| return 0; | return 0; | ||||
| @@ -36,7 +36,7 @@ typedef struct Mp3AudioContext { | |||||
| int buffer_index; | int buffer_index; | ||||
| } Mp3AudioContext; | } Mp3AudioContext; | ||||
| static int MP3lame_encode_init(AVCodecContext *avctx) | |||||
| static av_cold int MP3lame_encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| Mp3AudioContext *s = avctx->priv_data; | Mp3AudioContext *s = avctx->priv_data; | ||||
| @@ -198,7 +198,7 @@ static int MP3lame_encode_frame(AVCodecContext *avctx, | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int MP3lame_encode_close(AVCodecContext *avctx) | |||||
| static av_cold int MP3lame_encode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| Mp3AudioContext *s = avctx->priv_data; | Mp3AudioContext *s = avctx->priv_data; | ||||
| @@ -81,7 +81,7 @@ static int oggvorbis_init_encoder(vorbis_info *vi, AVCodecContext *avccontext) { | |||||
| return vorbis_encode_setup_init(vi); | return vorbis_encode_setup_init(vi); | ||||
| } | } | ||||
| static int oggvorbis_encode_init(AVCodecContext *avccontext) { | |||||
| static av_cold int oggvorbis_encode_init(AVCodecContext *avccontext) { | |||||
| OggVorbisContext *context = avccontext->priv_data ; | OggVorbisContext *context = avccontext->priv_data ; | ||||
| ogg_packet header, header_comm, header_code; | ogg_packet header, header_comm, header_code; | ||||
| uint8_t *p; | uint8_t *p; | ||||
| @@ -191,7 +191,7 @@ static int oggvorbis_encode_frame(AVCodecContext *avccontext, | |||||
| } | } | ||||
| static int oggvorbis_encode_close(AVCodecContext *avccontext) { | |||||
| static av_cold int oggvorbis_encode_close(AVCodecContext *avccontext) { | |||||
| OggVorbisContext *context = avccontext->priv_data ; | OggVorbisContext *context = avccontext->priv_data ; | ||||
| /* ogg_packet op ; */ | /* ogg_packet op ; */ | ||||
| @@ -119,7 +119,7 @@ X264_frame(AVCodecContext *ctx, uint8_t *buf, int bufsize, void *data) | |||||
| return bufsize; | return bufsize; | ||||
| } | } | ||||
| static int | |||||
| static av_cold int | |||||
| X264_close(AVCodecContext *avctx) | X264_close(AVCodecContext *avctx) | ||||
| { | { | ||||
| X264Context *x4 = avctx->priv_data; | X264Context *x4 = avctx->priv_data; | ||||
| @@ -130,7 +130,7 @@ X264_close(AVCodecContext *avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int | |||||
| static av_cold int | |||||
| X264_init(AVCodecContext *avctx) | X264_init(AVCodecContext *avctx) | ||||
| { | { | ||||
| X264Context *x4 = avctx->priv_data; | X264Context *x4 = avctx->priv_data; | ||||
| @@ -81,7 +81,7 @@ void xvid_correct_framerate(AVCodecContext *avctx); | |||||
| * @param avctx AVCodecContext pointer to context | * @param avctx AVCodecContext pointer to context | ||||
| * @return Returns 0 on success, -1 on failure | * @return Returns 0 on success, -1 on failure | ||||
| */ | */ | ||||
| int ff_xvid_encode_init(AVCodecContext *avctx) { | |||||
| av_cold int ff_xvid_encode_init(AVCodecContext *avctx) { | |||||
| int xerr, i; | int xerr, i; | ||||
| int xvid_flags = avctx->flags; | int xvid_flags = avctx->flags; | ||||
| xvid_context_t *x = avctx->priv_data; | xvid_context_t *x = avctx->priv_data; | ||||
| @@ -461,7 +461,7 @@ int ff_xvid_encode_frame(AVCodecContext *avctx, | |||||
| * @param avctx AVCodecContext pointer to context | * @param avctx AVCodecContext pointer to context | ||||
| * @return Returns 0, success guaranteed | * @return Returns 0, success guaranteed | ||||
| */ | */ | ||||
| int ff_xvid_encode_close(AVCodecContext *avctx) { | |||||
| av_cold int ff_xvid_encode_close(AVCodecContext *avctx) { | |||||
| xvid_context_t *x = avctx->priv_data; | xvid_context_t *x = avctx->priv_data; | ||||
| xvid_encore(x->encoder_handle, XVID_ENC_DESTROY, NULL, NULL); | xvid_encore(x->encoder_handle, XVID_ENC_DESTROY, NULL, NULL); | ||||
| @@ -225,7 +225,7 @@ static int decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int decode_init(AVCodecContext *avctx){ | |||||
| LOCOContext * const l = avctx->priv_data; | LOCOContext * const l = avctx->priv_data; | ||||
| int version; | int version; | ||||
| @@ -109,12 +109,12 @@ void ff_lzw_decode_tail(LZWState *p) | |||||
| s->pbuf= s->ebuf; | s->pbuf= s->ebuf; | ||||
| } | } | ||||
| void ff_lzw_decode_open(LZWState **p) | |||||
| av_cold void ff_lzw_decode_open(LZWState **p) | |||||
| { | { | ||||
| *p = av_mallocz(sizeof(struct LZWState)); | *p = av_mallocz(sizeof(struct LZWState)); | ||||
| } | } | ||||
| void ff_lzw_decode_close(LZWState **p) | |||||
| av_cold void ff_lzw_decode_close(LZWState **p) | |||||
| { | { | ||||
| av_freep(p); | av_freep(p); | ||||
| } | } | ||||
| @@ -392,7 +392,7 @@ static void Exp1to6(MACEContext *ctx, | |||||
| } | } | ||||
| /* \\\ */ | /* \\\ */ | ||||
| static int mace_decode_init(AVCodecContext * avctx) | |||||
| static av_cold int mace_decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| if (avctx->channels > 2) | if (avctx->channels > 2) | ||||
| return -1; | return -1; | ||||
| @@ -215,7 +215,7 @@ static int decode_frame(AVCodecContext *avctx, | |||||
| return (get_bits_count(&a->gb)+31)/32*4; | return (get_bits_count(&a->gb)+31)/32*4; | ||||
| } | } | ||||
| static void mdec_common_init(AVCodecContext *avctx){ | |||||
| static av_cold void mdec_common_init(AVCodecContext *avctx){ | |||||
| MDECContext * const a = avctx->priv_data; | MDECContext * const a = avctx->priv_data; | ||||
| dsputil_init(&a->dsp, avctx); | dsputil_init(&a->dsp, avctx); | ||||
| @@ -227,7 +227,7 @@ static void mdec_common_init(AVCodecContext *avctx){ | |||||
| a->avctx= avctx; | a->avctx= avctx; | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int decode_init(AVCodecContext *avctx){ | |||||
| MDECContext * const a = avctx->priv_data; | MDECContext * const a = avctx->priv_data; | ||||
| AVFrame *p= (AVFrame*)&a->picture; | AVFrame *p= (AVFrame*)&a->picture; | ||||
| @@ -247,7 +247,7 @@ static int decode_init(AVCodecContext *avctx){ | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int decode_end(AVCodecContext *avctx){ | |||||
| static av_cold int decode_end(AVCodecContext *avctx){ | |||||
| MDECContext * const a = avctx->priv_data; | MDECContext * const a = avctx->priv_data; | ||||
| av_freep(&a->bitstream_buffer); | av_freep(&a->bitstream_buffer); | ||||
| @@ -102,7 +102,7 @@ static const uint8_t col_zag[64] = { | |||||
| 53, 60, 61, 54, 47, 55, 62, 63 | 53, 60, 61, 54, 47, 55, 62, 63 | ||||
| }; | }; | ||||
| static int mimic_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int mimic_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| MimicContext *ctx = avctx->priv_data; | MimicContext *ctx = avctx->priv_data; | ||||
| @@ -371,7 +371,7 @@ static int mimic_decode_frame(AVCodecContext *avctx, void *data, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int mimic_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int mimic_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| MimicContext *ctx = avctx->priv_data; | MimicContext *ctx = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -73,7 +73,7 @@ static void build_basic_mjpeg_vlc(MJpegDecodeContext * s) { | |||||
| ff_mjpeg_val_ac_chrominance, 251, 0, 1); | ff_mjpeg_val_ac_chrominance, 251, 0, 1); | ||||
| } | } | ||||
| int ff_mjpeg_decode_init(AVCodecContext *avctx) | |||||
| av_cold int ff_mjpeg_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| MJpegDecodeContext *s = avctx->priv_data; | MJpegDecodeContext *s = avctx->priv_data; | ||||
| @@ -1338,7 +1338,7 @@ the_end: | |||||
| return buf_ptr - buf; | return buf_ptr - buf; | ||||
| } | } | ||||
| int ff_mjpeg_decode_end(AVCodecContext *avctx) | |||||
| av_cold int ff_mjpeg_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| MJpegDecodeContext *s = avctx->priv_data; | MJpegDecodeContext *s = avctx->priv_data; | ||||
| int i, j; | int i, j; | ||||
| @@ -44,7 +44,7 @@ | |||||
| #undef TWOMATRIXES | #undef TWOMATRIXES | ||||
| int ff_mjpeg_encode_init(MpegEncContext *s) | |||||
| av_cold int ff_mjpeg_encode_init(MpegEncContext *s) | |||||
| { | { | ||||
| MJpegContext *m; | MJpegContext *m; | ||||
| @@ -47,7 +47,7 @@ typedef struct MmContext { | |||||
| AVFrame frame; | AVFrame frame; | ||||
| } MmContext; | } MmContext; | ||||
| static int mm_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int mm_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| MmContext *s = avctx->priv_data; | MmContext *s = avctx->priv_data; | ||||
| @@ -182,7 +182,7 @@ static int mm_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int mm_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int mm_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| MmContext *s = avctx->priv_data; | MmContext *s = avctx->priv_data; | ||||
| @@ -44,7 +44,7 @@ | |||||
| static VLC scfi_vlc, dscf_vlc, hdr_vlc, quant_vlc[MPC7_QUANT_VLC_TABLES][2]; | static VLC scfi_vlc, dscf_vlc, hdr_vlc, quant_vlc[MPC7_QUANT_VLC_TABLES][2]; | ||||
| static int mpc7_decode_init(AVCodecContext * avctx) | |||||
| static av_cold int mpc7_decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| int i, j; | int i, j; | ||||
| MPCContext *c = avctx->priv_data; | MPCContext *c = avctx->priv_data; | ||||
| @@ -92,7 +92,7 @@ static int mpc8_get_mask(GetBitContext *gb, int size, int t) | |||||
| return mask; | return mask; | ||||
| } | } | ||||
| static int mpc8_decode_init(AVCodecContext * avctx) | |||||
| static av_cold int mpc8_decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| int i; | int i; | ||||
| MPCContext *c = avctx->priv_data; | MPCContext *c = avctx->priv_data; | ||||
| @@ -1199,7 +1199,7 @@ typedef struct Mpeg1Context { | |||||
| } Mpeg1Context; | } Mpeg1Context; | ||||
| static int mpeg_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int mpeg_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| Mpeg1Context *s = avctx->priv_data; | Mpeg1Context *s = avctx->priv_data; | ||||
| MpegEncContext *s2 = &s->mpeg_enc_ctx; | MpegEncContext *s2 = &s->mpeg_enc_ctx; | ||||
| @@ -2459,7 +2459,7 @@ AVCodec mpegvideo_decoder = { | |||||
| }; | }; | ||||
| #ifdef HAVE_XVMC | #ifdef HAVE_XVMC | ||||
| static int mpeg_mc_decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int mpeg_mc_decode_init(AVCodecContext *avctx){ | |||||
| Mpeg1Context *s; | Mpeg1Context *s; | ||||
| if( avctx->thread_count > 1) | if( avctx->thread_count > 1) | ||||
| @@ -133,7 +133,7 @@ static int find_frame_rate_index(MpegEncContext *s){ | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int encode_init(AVCodecContext *avctx) | |||||
| static av_cold int encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| MpegEncContext *s = avctx->priv_data; | MpegEncContext *s = avctx->priv_data; | ||||
| @@ -61,7 +61,7 @@ typedef struct MpegAudioContext { | |||||
| #include "mpegaudiodata.h" | #include "mpegaudiodata.h" | ||||
| #include "mpegaudiotab.h" | #include "mpegaudiotab.h" | ||||
| static int MPA_encode_init(AVCodecContext *avctx) | |||||
| static av_cold int MPA_encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| MpegAudioContext *s = avctx->priv_data; | MpegAudioContext *s = avctx->priv_data; | ||||
| int freq = avctx->sample_rate; | int freq = avctx->sample_rate; | ||||
| @@ -781,7 +781,7 @@ static int MPA_encode_frame(AVCodecContext *avctx, | |||||
| return pbBufPtr(&s->pb) - s->pb.buf; | return pbBufPtr(&s->pb) - s->pb.buf; | ||||
| } | } | ||||
| static int MPA_encode_close(AVCodecContext *avctx) | |||||
| static av_cold int MPA_encode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| av_freep(&avctx->coded_frame); | av_freep(&avctx->coded_frame); | ||||
| return 0; | return 0; | ||||
| @@ -240,7 +240,7 @@ static void MPV_encode_defaults(MpegEncContext *s){ | |||||
| } | } | ||||
| /* init video encoder */ | /* init video encoder */ | ||||
| int MPV_encode_init(AVCodecContext *avctx) | |||||
| av_cold int MPV_encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| MpegEncContext *s = avctx->priv_data; | MpegEncContext *s = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -737,7 +737,7 @@ int MPV_encode_init(AVCodecContext *avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| int MPV_encode_end(AVCodecContext *avctx) | |||||
| av_cold int MPV_encode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| MpegEncContext *s = avctx->priv_data; | MpegEncContext *s = avctx->priv_data; | ||||
| @@ -236,7 +236,7 @@ static void msrle_decode_pal8(MsrleContext *s) | |||||
| stream_ptr, s->size); | stream_ptr, s->size); | ||||
| } | } | ||||
| static int msrle_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int msrle_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| MsrleContext *s = avctx->priv_data; | MsrleContext *s = avctx->priv_data; | ||||
| @@ -283,7 +283,7 @@ static int msrle_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int msrle_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int msrle_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| MsrleContext *s = avctx->priv_data; | MsrleContext *s = avctx->priv_data; | ||||
| @@ -57,7 +57,7 @@ typedef struct Msvideo1Context { | |||||
| } Msvideo1Context; | } Msvideo1Context; | ||||
| static int msvideo1_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int msvideo1_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| Msvideo1Context *s = avctx->priv_data; | Msvideo1Context *s = avctx->priv_data; | ||||
| @@ -319,7 +319,7 @@ static int msvideo1_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int msvideo1_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int msvideo1_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| Msvideo1Context *s = avctx->priv_data; | Msvideo1Context *s = avctx->priv_data; | ||||
| @@ -329,7 +329,7 @@ void nelly_decode_block(NellyMoserDecodeContext *s, const unsigned char block[NE | |||||
| } | } | ||||
| } | } | ||||
| static int decode_init(AVCodecContext * avctx) { | |||||
| static av_cold int decode_init(AVCodecContext * avctx) { | |||||
| NellyMoserDecodeContext *s = avctx->priv_data; | NellyMoserDecodeContext *s = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -391,7 +391,7 @@ static int decode_tag(AVCodecContext * avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int decode_end(AVCodecContext * avctx) { | |||||
| static av_cold int decode_end(AVCodecContext * avctx) { | |||||
| NellyMoserDecodeContext *s = avctx->priv_data; | NellyMoserDecodeContext *s = avctx->priv_data; | ||||
| ff_mdct_end(&s->imdct_ctx); | ff_mdct_end(&s->imdct_ctx); | ||||
| @@ -236,7 +236,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, | |||||
| return orig_size; | return orig_size; | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx) { | |||||
| static av_cold int decode_init(AVCodecContext *avctx) { | |||||
| NuvContext *c = avctx->priv_data; | NuvContext *c = avctx->priv_data; | ||||
| avctx->pix_fmt = PIX_FMT_YUV420P; | avctx->pix_fmt = PIX_FMT_YUV420P; | ||||
| c->pic.data[0] = NULL; | c->pic.data[0] = NULL; | ||||
| @@ -253,7 +253,7 @@ static int decode_init(AVCodecContext *avctx) { | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int decode_end(AVCodecContext *avctx) { | |||||
| static av_cold int decode_end(AVCodecContext *avctx) { | |||||
| NuvContext *c = avctx->priv_data; | NuvContext *c = avctx->priv_data; | ||||
| av_freep(&c->decomp_buf); | av_freep(&c->decomp_buf); | ||||
| if (c->pic.data[0]) | if (c->pic.data[0]) | ||||
| @@ -44,7 +44,7 @@ | |||||
| * alaw2linear() - Convert an A-law value to 16-bit linear PCM | * alaw2linear() - Convert an A-law value to 16-bit linear PCM | ||||
| * | * | ||||
| */ | */ | ||||
| static int alaw2linear(unsigned char a_val) | |||||
| static av_cold int alaw2linear(unsigned char a_val) | |||||
| { | { | ||||
| int t; | int t; | ||||
| int seg; | int seg; | ||||
| @@ -59,7 +59,7 @@ static int alaw2linear(unsigned char a_val) | |||||
| return ((a_val & SIGN_BIT) ? t : -t); | return ((a_val & SIGN_BIT) ? t : -t); | ||||
| } | } | ||||
| static int ulaw2linear(unsigned char u_val) | |||||
| static av_cold int ulaw2linear(unsigned char u_val) | |||||
| { | { | ||||
| int t; | int t; | ||||
| @@ -80,7 +80,7 @@ static int ulaw2linear(unsigned char u_val) | |||||
| static uint8_t linear_to_alaw[16384]; | static uint8_t linear_to_alaw[16384]; | ||||
| static uint8_t linear_to_ulaw[16384]; | static uint8_t linear_to_ulaw[16384]; | ||||
| static void build_xlaw_table(uint8_t *linear_to_xlaw, | |||||
| static av_cold void build_xlaw_table(uint8_t *linear_to_xlaw, | |||||
| int (*xlaw2linear)(unsigned char), | int (*xlaw2linear)(unsigned char), | ||||
| int mask) | int mask) | ||||
| { | { | ||||
| @@ -104,7 +104,7 @@ static void build_xlaw_table(uint8_t *linear_to_xlaw, | |||||
| linear_to_xlaw[0] = linear_to_xlaw[1]; | linear_to_xlaw[0] = linear_to_xlaw[1]; | ||||
| } | } | ||||
| static int pcm_encode_init(AVCodecContext *avctx) | |||||
| static av_cold int pcm_encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| avctx->frame_size = 1; | avctx->frame_size = 1; | ||||
| switch(avctx->codec->id) { | switch(avctx->codec->id) { | ||||
| @@ -154,7 +154,7 @@ static int pcm_encode_init(AVCodecContext *avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int pcm_encode_close(AVCodecContext *avctx) | |||||
| static av_cold int pcm_encode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| av_freep(&avctx->coded_frame); | av_freep(&avctx->coded_frame); | ||||
| @@ -325,7 +325,7 @@ typedef struct PCMDecode { | |||||
| short table[256]; | short table[256]; | ||||
| } PCMDecode; | } PCMDecode; | ||||
| static int pcm_decode_init(AVCodecContext * avctx) | |||||
| static av_cold int pcm_decode_init(AVCodecContext * avctx) | |||||
| { | { | ||||
| PCMDecode *s = avctx->priv_data; | PCMDecode *s = avctx->priv_data; | ||||
| int i; | int i; | ||||
| @@ -30,7 +30,7 @@ typedef struct PCXContext { | |||||
| AVFrame picture; | AVFrame picture; | ||||
| } PCXContext; | } PCXContext; | ||||
| static int pcx_init(AVCodecContext *avctx) { | |||||
| static av_cold int pcx_init(AVCodecContext *avctx) { | |||||
| PCXContext *s = avctx->priv_data; | PCXContext *s = avctx->priv_data; | ||||
| avcodec_get_frame_defaults(&s->picture); | avcodec_get_frame_defaults(&s->picture); | ||||
| @@ -224,7 +224,7 @@ static int pcx_decode_frame(AVCodecContext *avctx, void *data, int *data_size, | |||||
| return buf - bufstart; | return buf - bufstart; | ||||
| } | } | ||||
| static int pcx_end(AVCodecContext *avctx) { | |||||
| static av_cold int pcx_end(AVCodecContext *avctx) { | |||||
| PCXContext *s = avctx->priv_data; | PCXContext *s = avctx->priv_data; | ||||
| if(s->picture.data[0]) | if(s->picture.data[0]) | ||||
| @@ -597,7 +597,7 @@ static int decode_frame(AVCodecContext *avctx, | |||||
| goto the_end; | goto the_end; | ||||
| } | } | ||||
| static int png_dec_init(AVCodecContext *avctx){ | |||||
| static av_cold int png_dec_init(AVCodecContext *avctx){ | |||||
| PNGDecContext *s = avctx->priv_data; | PNGDecContext *s = avctx->priv_data; | ||||
| avcodec_get_frame_defaults((AVFrame*)&s->picture); | avcodec_get_frame_defaults((AVFrame*)&s->picture); | ||||
| @@ -422,7 +422,7 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size, | |||||
| goto the_end; | goto the_end; | ||||
| } | } | ||||
| static int png_enc_init(AVCodecContext *avctx){ | |||||
| static av_cold int png_enc_init(AVCodecContext *avctx){ | |||||
| PNGEncContext *s = avctx->priv_data; | PNGEncContext *s = avctx->priv_data; | ||||
| avcodec_get_frame_defaults((AVFrame*)&s->picture); | avcodec_get_frame_defaults((AVFrame*)&s->picture); | ||||
| @@ -23,7 +23,7 @@ | |||||
| #include "pnm.h" | #include "pnm.h" | ||||
| static int common_init(AVCodecContext *avctx){ | |||||
| static av_cold int common_init(AVCodecContext *avctx){ | |||||
| PNMContext *s = avctx->priv_data; | PNMContext *s = avctx->priv_data; | ||||
| avcodec_get_frame_defaults((AVFrame*)&s->picture); | avcodec_get_frame_defaults((AVFrame*)&s->picture); | ||||
| @@ -25,7 +25,7 @@ typedef struct PTXContext { | |||||
| AVFrame picture; | AVFrame picture; | ||||
| } PTXContext; | } PTXContext; | ||||
| static int ptx_init(AVCodecContext *avctx) { | |||||
| static av_cold int ptx_init(AVCodecContext *avctx) { | |||||
| PTXContext *s = avctx->priv_data; | PTXContext *s = avctx->priv_data; | ||||
| avcodec_get_frame_defaults(&s->picture); | avcodec_get_frame_defaults(&s->picture); | ||||
| @@ -94,7 +94,7 @@ static int ptx_decode_frame(AVCodecContext *avctx, void *data, int *data_size, | |||||
| return offset + w*h*bytes_per_pixel; | return offset + w*h*bytes_per_pixel; | ||||
| } | } | ||||
| static int ptx_end(AVCodecContext *avctx) { | |||||
| static av_cold int ptx_end(AVCodecContext *avctx) { | |||||
| PTXContext *s = avctx->priv_data; | PTXContext *s = avctx->priv_data; | ||||
| if(s->picture.data[0]) | if(s->picture.data[0]) | ||||
| @@ -129,7 +129,7 @@ static int decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int decode_init(AVCodecContext *avctx){ | |||||
| // QdrawContext * const a = avctx->priv_data; | // QdrawContext * const a = avctx->priv_data; | ||||
| if (avcodec_check_dimensions(avctx, avctx->width, avctx->height) < 0) { | if (avcodec_check_dimensions(avctx, avctx->width, avctx->height) < 0) { | ||||
| @@ -284,7 +284,7 @@ static int decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int decode_init(AVCodecContext *avctx){ | |||||
| static av_cold int decode_init(AVCodecContext *avctx){ | |||||
| QpegContext * const a = avctx->priv_data; | QpegContext * const a = avctx->priv_data; | ||||
| a->avctx = avctx; | a->avctx = avctx; | ||||
| @@ -295,7 +295,7 @@ static int decode_init(AVCodecContext *avctx){ | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int decode_end(AVCodecContext *avctx){ | |||||
| static av_cold int decode_end(AVCodecContext *avctx){ | |||||
| QpegContext * const a = avctx->priv_data; | QpegContext * const a = avctx->priv_data; | ||||
| AVFrame * const p= (AVFrame*)&a->pic; | AVFrame * const p= (AVFrame*)&a->pic; | ||||
| @@ -485,7 +485,7 @@ static void qtrle_decode_32bpp(QtrleContext *s) | |||||
| } | } | ||||
| } | } | ||||
| static int qtrle_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int qtrle_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| QtrleContext *s = avctx->priv_data; | QtrleContext *s = avctx->priv_data; | ||||
| @@ -600,7 +600,7 @@ static int qtrle_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int qtrle_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int qtrle_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| QtrleContext *s = avctx->priv_data; | QtrleContext *s = avctx->priv_data; | ||||
| @@ -57,7 +57,7 @@ typedef struct QtrleEncContext { | |||||
| uint8_t* skip_table; | uint8_t* skip_table; | ||||
| } QtrleEncContext; | } QtrleEncContext; | ||||
| static int qtrle_encode_init(AVCodecContext *avctx) | |||||
| static av_cold int qtrle_encode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| QtrleEncContext *s = avctx->priv_data; | QtrleEncContext *s = avctx->priv_data; | ||||
| @@ -303,7 +303,7 @@ static int qtrle_encode_frame(AVCodecContext *avctx, uint8_t *buf, int buf_size, | |||||
| return chunksize; | return chunksize; | ||||
| } | } | ||||
| static int qtrle_encode_end(AVCodecContext *avctx) | |||||
| static av_cold int qtrle_encode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| QtrleEncContext *s = avctx->priv_data; | QtrleEncContext *s = avctx->priv_data; | ||||
| @@ -64,7 +64,7 @@ static int findPixelFormat(const PixelFormatTag *tags, unsigned int fourcc) | |||||
| return PIX_FMT_YUV420P; | return PIX_FMT_YUV420P; | ||||
| } | } | ||||
| static int raw_init_decoder(AVCodecContext *avctx) | |||||
| static av_cold int raw_init_decoder(AVCodecContext *avctx) | |||||
| { | { | ||||
| RawVideoContext *context = avctx->priv_data; | RawVideoContext *context = avctx->priv_data; | ||||
| @@ -145,7 +145,7 @@ static int raw_decode(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int raw_close_decoder(AVCodecContext *avctx) | |||||
| static av_cold int raw_close_decoder(AVCodecContext *avctx) | |||||
| { | { | ||||
| RawVideoContext *context = avctx->priv_data; | RawVideoContext *context = avctx->priv_data; | ||||
| @@ -27,7 +27,7 @@ | |||||
| #include "avcodec.h" | #include "avcodec.h" | ||||
| #include "raw.h" | #include "raw.h" | ||||
| static int raw_init_encoder(AVCodecContext *avctx) | |||||
| static av_cold int raw_init_encoder(AVCodecContext *avctx) | |||||
| { | { | ||||
| avctx->coded_frame = (AVFrame *)avctx->priv_data; | avctx->coded_frame = (AVFrame *)avctx->priv_data; | ||||
| avctx->coded_frame->pict_type = FF_I_TYPE; | avctx->coded_frame->pict_type = FF_I_TYPE; | ||||
| @@ -37,7 +37,7 @@ typedef struct | |||||
| short lastSample[2]; | short lastSample[2]; | ||||
| } ROQDPCMContext_t; | } ROQDPCMContext_t; | ||||
| static void roq_dpcm_table_init(void) | |||||
| static av_cold void roq_dpcm_table_init(void) | |||||
| { | { | ||||
| int i; | int i; | ||||
| @@ -158,7 +158,7 @@ static int roq_dpcm_encode_frame(AVCodecContext *avctx, | |||||
| return out - frame; | return out - frame; | ||||
| } | } | ||||
| static int roq_dpcm_encode_close(AVCodecContext *avctx) | |||||
| static av_cold int roq_dpcm_encode_close(AVCodecContext *avctx) | |||||
| { | { | ||||
| av_freep(&avctx->coded_frame); | av_freep(&avctx->coded_frame); | ||||
| @@ -153,7 +153,7 @@ static void roqvideo_decode_frame(RoqContext *ri) | |||||
| } | } | ||||
| static int roq_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int roq_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| RoqContext *s = avctx->priv_data; | RoqContext *s = avctx->priv_data; | ||||
| @@ -196,7 +196,7 @@ static int roq_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int roq_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int roq_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| RoqContext *s = avctx->priv_data; | RoqContext *s = avctx->priv_data; | ||||
| @@ -226,7 +226,7 @@ static void rpza_decode_stream(RpzaContext *s) | |||||
| } | } | ||||
| } | } | ||||
| static int rpza_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int rpza_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| RpzaContext *s = avctx->priv_data; | RpzaContext *s = avctx->priv_data; | ||||
| @@ -263,7 +263,7 @@ static int rpza_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| static int rpza_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int rpza_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| RpzaContext *s = avctx->priv_data; | RpzaContext *s = avctx->priv_data; | ||||
| @@ -522,7 +522,7 @@ av_log(s->avctx, AV_LOG_DEBUG, "\n");*/ | |||||
| return s->mb_width*s->mb_height - mb_pos; | return s->mb_width*s->mb_height - mb_pos; | ||||
| } | } | ||||
| static int rv10_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int rv10_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| MpegEncContext *s = avctx->priv_data; | MpegEncContext *s = avctx->priv_data; | ||||
| static int done=0; | static int done=0; | ||||
| @@ -588,7 +588,7 @@ static int rv10_decode_init(AVCodecContext *avctx) | |||||
| return 0; | return 0; | ||||
| } | } | ||||
| static int rv10_decode_end(AVCodecContext *avctx) | |||||
| static av_cold int rv10_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| MpegEncContext *s = avctx->priv_data; | MpegEncContext *s = avctx->priv_data; | ||||
| @@ -114,7 +114,7 @@ static int rv30_decode_mb_info(RV34DecContext *r) | |||||
| /** | /** | ||||
| * Initialize decoder. | * Initialize decoder. | ||||
| */ | */ | ||||
| static int rv30_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int rv30_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| RV34DecContext *r = avctx->priv_data; | RV34DecContext *r = avctx->priv_data; | ||||
| @@ -99,7 +99,7 @@ static void rv34_gen_vlc(const uint8_t *bits, int size, VLC *vlc, const uint8_t | |||||
| /** | /** | ||||
| * Initialize all tables. | * Initialize all tables. | ||||
| */ | */ | ||||
| static void rv34_init_tables() | |||||
| static av_cold void rv34_init_tables() | |||||
| { | { | ||||
| int i, j, k; | int i, j, k; | ||||
| @@ -1163,7 +1163,7 @@ static int rv34_decode_slice(RV34DecContext *r, int end, uint8_t* buf, int buf_s | |||||
| /** | /** | ||||
| * Initialize decoder. | * Initialize decoder. | ||||
| */ | */ | ||||
| int ff_rv34_decode_init(AVCodecContext *avctx) | |||||
| av_cold int ff_rv34_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| RV34DecContext *r = avctx->priv_data; | RV34DecContext *r = avctx->priv_data; | ||||
| MpegEncContext *s = &r->s; | MpegEncContext *s = &r->s; | ||||
| @@ -1285,7 +1285,7 @@ int ff_rv34_decode_frame(AVCodecContext *avctx, | |||||
| return buf_size; | return buf_size; | ||||
| } | } | ||||
| int ff_rv34_decode_end(AVCodecContext *avctx) | |||||
| av_cold int ff_rv34_decode_end(AVCodecContext *avctx) | |||||
| { | { | ||||
| RV34DecContext *r = avctx->priv_data; | RV34DecContext *r = avctx->priv_data; | ||||
| @@ -40,7 +40,7 @@ static VLC ptype_vlc[NUM_PTYPE_VLCS], btype_vlc[NUM_BTYPE_VLCS]; | |||||
| /** | /** | ||||
| * Initialize all tables. | * Initialize all tables. | ||||
| */ | */ | ||||
| static void rv40_init_tables() | |||||
| static av_cold void rv40_init_tables() | |||||
| { | { | ||||
| int i; | int i; | ||||
| @@ -250,7 +250,7 @@ static int rv40_decode_mb_info(RV34DecContext *r) | |||||
| /** | /** | ||||
| * Initialize decoder. | * Initialize decoder. | ||||
| */ | */ | ||||
| static int rv40_decode_init(AVCodecContext *avctx) | |||||
| static av_cold int rv40_decode_init(AVCodecContext *avctx) | |||||
| { | { | ||||
| RV34DecContext *r = avctx->priv_data; | RV34DecContext *r = avctx->priv_data; | ||||