Lines Matching defs:avctx
75 static av_cold int mpc7_decode_init(AVCodecContext * avctx)
78 MPCContext *c = avctx->priv_data;
83 if (avctx->ch_layout.nb_channels != 2) {
84 avpriv_request_sample(avctx, "%d channels", avctx->ch_layout.nb_channels);
88 if(avctx->extradata_size < 16){
89 av_log(avctx, AV_LOG_ERROR, "Too small extradata size (%i)!\n", avctx->extradata_size);
96 c->bdsp.bswap_buf((uint32_t *) buf, (const uint32_t *) avctx->extradata, 4);
103 av_log(avctx, AV_LOG_ERROR, "Too many bands: %i\n", c->maxbands);
109 av_log(avctx, AV_LOG_DEBUG, "IS: %d, MSS: %d, TG: %d, LFL: %d, bands: %d\n",
113 avctx->sample_fmt = AV_SAMPLE_FMT_S16P;
114 av_channel_layout_uninit(&avctx->ch_layout);
115 avctx->ch_layout = (AVChannelLayout)AV_CHANNEL_LAYOUT_STEREO;
175 static int mpc7_decode_frame(AVCodecContext *avctx, AVFrame *frame,
180 MPCContext *c = avctx->priv_data;
192 av_log(avctx, AV_LOG_ERROR, "packet size is too small (%i bytes)\n",
197 av_log(avctx, AV_LOG_WARNING, "packet size is not a multiple of 4. "
208 if ((ret = ff_get_buffer(avctx, frame, 0)) < 0)
227 av_log(avctx, AV_LOG_ERROR, "subband index invalid\n");
282 av_log(avctx, AV_LOG_ERROR, "Error decoding frame: used %i of %i bits\n", bits_used, bits_avail);
296 static void mpc7_decode_flush(AVCodecContext *avctx)
298 MPCContext *c = avctx->priv_data;
304 static av_cold int mpc7_decode_close(AVCodecContext *avctx)
306 MPCContext *c = avctx->priv_data;