54 while(r->
sum > val && cnt < 9) {
94 v = ((v>>1) + r->
lossy) ^ -(v&1);
114 c = data[-stride -
step];
120 int stride,
const uint8_t *buf,
int buf_size,
int step)
139 for (i = 1; i <
width; i++) {
141 data[i *
step] = data[i * step -
step] + val;
144 for (j = 1; j <
height; j++) {
147 data[0] = data[-
stride] + val;
149 for (i = 1; i <
width; i++) {
160 void *
data,
int *data_size,
163 const uint8_t *buf = avpkt->
data;
164 int buf_size = avpkt->
size;
183 buf += decoded; buf_size -= decoded;
186 buf += decoded; buf_size -= decoded;
193 buf += decoded; buf_size -= decoded;
196 buf += decoded; buf_size -= decoded;
203 buf += decoded; buf_size -= decoded;
206 buf += decoded; buf_size -= decoded;
213 buf += decoded; buf_size -= decoded;
216 buf += decoded; buf_size -= decoded;
219 buf += decoded; buf_size -= decoded;
planar YUV 4:2:2, 16bpp, (1 Cr & Cb sample per 2x1 Y samples)
int(* get_buffer)(struct AVCodecContext *c, AVFrame *pic)
Called at the beginning of each frame to get a buffer for it.
enum PixelFormat pix_fmt
Pixel format, see PIX_FMT_xxx.
void(* release_buffer)(struct AVCodecContext *c, AVFrame *pic)
Called to release buffers which were allocated with get_buffer.
static av_cold int decode_end(AVCodecContext *avctx)
static int loco_predict(uint8_t *data, int stride, int step)
static int get_ur_golomb_jpegls(GetBitContext *gb, int k, int limit, int esc_len)
read unsigned golomb rice code (jpegls).
static int decode(MimicContext *ctx, int quality, int num_coeffs, int is_iframe)
static int loco_get_rice_param(RICEContext *r)
planar YUV 4:2:0, 12bpp, (1 Cr & Cb sample per 2x2 Y samples)
#define FF_DEBUG_PICT_INFO
uint8_t * extradata
some codecs need / can use extradata like Huffman tables.
static int get_bits_count(const GetBitContext *s)
bitstream reader API header.
static int init(AVCodecParserContext *s)
#define CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.
int reference
is this picture used as reference The values for this are the same as the MpegEncContext.picture_structure variable, that is 1->top field, 2->bottom field, 3->frame/both fields.
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
void av_log(void *avcl, int level, const char *fmt,...)
const char * name
Name of the codec implementation.
static int loco_get_rice(RICEContext *r)
struct LOCOContext LOCOContext
struct RICEContext RICEContext
static void loco_update_rice_param(RICEContext *r, int val)
static av_cold int decode_init(AVCodecContext *avctx)
int width
picture width / height.
struct AVFrame AVFrame
Audio Video Frame.
static int loco_decode_plane(LOCOContext *l, uint8_t *data, int width, int height, int stride, const uint8_t *buf, int buf_size, int step)
int linesize[AV_NUM_DATA_POINTERS]
Size, in bytes, of the data for each picture/channel plane.
void av_log_ask_for_sample(void *avc, const char *msg,...) av_printf_format(2
Log a generic warning message asking for a sample.
main external API structure.
static void close(AVCodecParserContext *s)
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
static int init_get_bits(GetBitContext *s, const uint8_t *buffer, int bit_size)
Initialize GetBitContext.
packed RGB 8:8:8, 24bpp, BGRBGR...
uint8_t * data[AV_NUM_DATA_POINTERS]
pointer to the picture/channel planes.
static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPacket *avpkt)
int key_frame
1 -> keyframe, 0-> not