Lines Matching defs:avctx
56 static av_cold int screenpresso_close(AVCodecContext *avctx)
58 ScreenpressoContext *ctx = avctx->priv_data;
66 static av_cold int screenpresso_init(AVCodecContext *avctx)
68 ScreenpressoContext *ctx = avctx->priv_data;
71 int ret = av_image_check_size(avctx->width, avctx->height, 0, avctx);
73 av_log(avctx, AV_LOG_ERROR, "Invalid image size %dx%d.\n",
74 avctx->width, avctx->height);
84 ctx->inflated_size = avctx->width * avctx->height * 4;
105 static int screenpresso_decode_frame(AVCodecContext *avctx, AVFrame *frame,
108 ScreenpressoContext *ctx = avctx->priv_data;
115 av_log(avctx, AV_LOG_ERROR, "Packet too small (%d)\n", avpkt->size);
120 av_log(avctx, AV_LOG_DEBUG, "Compression level %d\n", avpkt->data[0] >> 4);
127 avctx->pix_fmt = AV_PIX_FMT_RGB555LE;
130 avctx->pix_fmt = AV_PIX_FMT_BGR24;
133 avctx->pix_fmt = AV_PIX_FMT_BGR0;
136 av_log(avctx, AV_LOG_ERROR, "Invalid bits per pixel value (%d)\n",
145 av_log(avctx, AV_LOG_ERROR, "Deflate error %d.\n", ret);
149 ret = ff_reget_buffer(avctx, ctx->current, 0);
154 src_linesize = FFALIGN(avctx->width * component_size, 4);
159 ctx->current->linesize[0] * (avctx->height - 1),
162 avctx->width * component_size, avctx->height);
167 avctx->width * component_size, avctx->height);