Lines Matching defs:avctx

105     AVCodecContext *avctx;
129 static av_cold int vqa_decode_init(AVCodecContext *avctx)
131 VqaContext *s = avctx->priv_data;
135 s->avctx = avctx;
138 if (s->avctx->extradata_size != VQA_HEADER_SIZE) {
139 av_log(s->avctx, AV_LOG_ERROR, "expected extradata size of %d\n", VQA_HEADER_SIZE);
144 s->vqa_version = s->avctx->extradata[0];
147 avpriv_request_sample(avctx, "VQA Version %i", s->vqa_version);
151 s->width = AV_RL16(&s->avctx->extradata[6]);
152 s->height = AV_RL16(&s->avctx->extradata[8]);
153 if ((ret = ff_set_dimensions(avctx, s->width, s->height)) < 0) {
157 s->vector_width = s->avctx->extradata[10];
158 s->vector_height = s->avctx->extradata[11];
159 s->partial_count = s->partial_countdown = s->avctx->extradata[13];
161 colors = (s->avctx->extradata[14] << 8) | s->avctx->extradata[15];
164 avctx->pix_fmt = AV_PIX_FMT_PAL8;
166 avctx->pix_fmt = AV_PIX_FMT_RGB555LE;
177 av_log(avctx, AV_LOG_ERROR, "Image size not multiple of block size\n");
220 av_log(s->avctx, AV_LOG_ERROR, "decode_format80 problem: next op would overflow dest_index\n"); \
221 av_log(s->avctx, AV_LOG_ERROR, "current dest_index = %d, count = %d, dest_size = %d\n", \
228 av_log(s->avctx, AV_LOG_ERROR, "decode_format80 problem: next op would overflow dest_index\n"); \
229 av_log(s->avctx, AV_LOG_ERROR, "current src_pos = %d, count = %d, dest_size = %d\n", \
246 av_log(s->avctx, AV_LOG_ERROR, "Chunk size %d is out of range\n",
255 ff_tlog(s->avctx, "found new format stream ");
261 ff_tlog(s->avctx, "opcode %02X: ", opcode);
268 av_log(s->avctx, AV_LOG_ERROR, "decode_format80 problem: dest_index (%d) exceeded dest_size (%d)\n",
279 ff_tlog(s->avctx, "(1) copy %X bytes from pos %X\n", count, src_pos);
290 ff_tlog(s->avctx, "(2) set %X bytes to %02X\n", count, color);
301 ff_tlog(s->avctx, "(3) copy %X bytes from pos %X\n", count, src_pos);
311 ff_tlog(s->avctx, "(4) copy %X bytes from source to dest\n", count);
320 ff_tlog(s->avctx, "(5) copy %X bytes from relpos %X\n", count, src_pos);
335 av_log(s->avctx, AV_LOG_ERROR, "decode_format80 problem: decode finished with dest_index (%d) < dest_size (%d)\n",
409 av_log(s->avctx, AV_LOG_ERROR, "Found unknown chunk type: %s (%08X)\n",
422 av_log(s->avctx, AV_LOG_ERROR, "problem: found both CPL0 and CPLZ chunks\n");
440 av_log(s->avctx, AV_LOG_ERROR, "problem: found a palette chunk with %d colors\n",
458 av_log(s->avctx, AV_LOG_ERROR, "problem: found both CBF0 and CBFZ chunks\n");
479 av_log(s->avctx, AV_LOG_ERROR, "problem: CBF0 chunk too large (0x%X bytes)\n",
491 av_log(s->avctx, AV_LOG_ERROR, "problem: no VPTZ chunk found\n");
542 av_log(s->avctx, AV_LOG_ERROR, "VQA3 shouldn't have a color palette");
559 av_log(s->avctx, AV_LOG_ERROR, "problem: found both CBP0 and CBPZ chunks\n");
569 av_log(s->avctx, AV_LOG_ERROR, "cbp0 chunk too large (%u bytes)\n",
598 av_log(s->avctx, AV_LOG_ERROR, "cbpz chunk too large (%u bytes)\n",
659 av_log(s->avctx, AV_LOG_ERROR, "Found unknown chunk type: %s (%08X)\n",
670 av_log(s->avctx, AV_LOG_ERROR, "problem: found both CBF0 and CBFZ chunks\n");
689 av_log(s->avctx, AV_LOG_ERROR, "problem: CBF0 chunk too large (0x%X bytes)\n",
704 av_log(s->avctx, AV_LOG_ERROR, "VPTR chunk didn't fit in decode buffer");
716 av_log(s->avctx, AV_LOG_ERROR, "frame has no block data\n");
754 av_log(s->avctx, AV_LOG_ERROR, " unknown type in VPTR chunk (%d)\n",type);
759 av_log(s->avctx, AV_LOG_ERROR, "invalid count: %d\n", count);
788 av_log(s->avctx, AV_LOG_ERROR, "had %d leftover vectors\n", count);
797 static int vqa_decode_frame(AVCodecContext *avctx, AVFrame *rframe,
800 VqaContext *s = avctx->priv_data;
803 if ((res = ff_reget_buffer(avctx, s->frame, 0)) < 0)
808 if (avctx->pix_fmt == AV_PIX_FMT_PAL8) {
815 } else if (avctx->pix_fmt == AV_PIX_FMT_RGB555LE) {
819 av_log(s->avctx, AV_LOG_ERROR, "unsupported pixel format\n");
832 static av_cold int vqa_decode_end(AVCodecContext *avctx)
834 VqaContext *s = avctx->priv_data;