Lines Matching defs:avctx

32 static int xwd_decode_frame(AVCodecContext *avctx, AVFrame *p,
53 av_log(avctx, AV_LOG_ERROR, "unsupported version\n");
58 av_log(avctx, AV_LOG_ERROR, "invalid header size\n");
81 if ((ret = ff_set_dimensions(avctx, width, height)) < 0)
84 av_log(avctx, AV_LOG_DEBUG,
87 av_log(avctx, AV_LOG_DEBUG,
90 av_log(avctx, AV_LOG_DEBUG,
95 av_log(avctx, AV_LOG_ERROR, "invalid pixmap format\n");
100 av_log(avctx, AV_LOG_ERROR, "invalid pixmap depth\n");
105 avpriv_request_sample(avctx, "xoffset %"PRIu32"", xoffset);
110 av_log(avctx, AV_LOG_ERROR, "invalid byte order\n");
115 av_log(avctx, AV_LOG_ERROR, "invalid bitmap bit order\n");
120 av_log(avctx, AV_LOG_ERROR, "invalid bitmap unit\n");
125 av_log(avctx, AV_LOG_ERROR, "invalid bitmap scan-line pad\n");
130 av_log(avctx, AV_LOG_ERROR, "invalid bits per pixel\n");
135 av_log(avctx, AV_LOG_ERROR, "invalid number of entries in colormap\n");
139 if ((ret = av_image_check_size(avctx->width, avctx->height, 0, NULL)) < 0)
142 rsize = FFALIGN(avctx->width * bpp, bpad) / 8;
144 av_log(avctx, AV_LOG_ERROR, "invalid bytes per scan-line\n");
148 if (bytestream2_get_bytes_left(&gb) < ncolors * XWD_CMAP_SIZE + (uint64_t)avctx->height * lsize) {
149 av_log(avctx, AV_LOG_ERROR, "input buffer too small\n");
154 avpriv_report_missing_feature(avctx, "Pixmap format %"PRIu32, pixformat);
158 avctx->pix_fmt = AV_PIX_FMT_NONE;
165 avctx->pix_fmt = AV_PIX_FMT_MONOWHITE;
167 avctx->pix_fmt = AV_PIX_FMT_GRAY8;
173 avctx->pix_fmt = AV_PIX_FMT_PAL8;
181 avctx->pix_fmt = be ? AV_PIX_FMT_RGB555BE : AV_PIX_FMT_RGB555LE;
183 avctx->pix_fmt = be ? AV_PIX_FMT_BGR555BE : AV_PIX_FMT_BGR555LE;
186 avctx->pix_fmt = be ? AV_PIX_FMT_RGB565BE : AV_PIX_FMT_RGB565LE;
188 avctx->pix_fmt = be ? AV_PIX_FMT_BGR565BE : AV_PIX_FMT_BGR565LE;
191 avctx->pix_fmt = be ? AV_PIX_FMT_RGB24 : AV_PIX_FMT_BGR24;
193 avctx->pix_fmt = be ? AV_PIX_FMT_BGR24 : AV_PIX_FMT_RGB24;
196 avctx->pix_fmt = be ? AV_PIX_FMT_ARGB : AV_PIX_FMT_BGRA;
198 avctx->pix_fmt = be ? AV_PIX_FMT_ABGR : AV_PIX_FMT_RGBA;
203 av_log(avctx, AV_LOG_ERROR, "invalid visual class\n");
207 if (avctx->pix_fmt == AV_PIX_FMT_NONE) {
208 avpriv_request_sample(avctx,
214 if ((ret = ff_get_buffer(avctx, p, 0)) < 0)
220 if (avctx->pix_fmt == AV_PIX_FMT_PAL8) {
239 for (i = 0; i < avctx->height; i++) {