27 #define BITSTREAM_READER_LE
65 for (i = 0; i < ctx->
size; i++) {
68 if (ctx->
val[i] == UINT8_MAX)
72 for (i = 0; i < ctx->
size; i++) {
89 uint8_t *dst = pic->
data[plane];
90 uint8_t *val = ctx->
val + offset;
92 int i, j, left, left_top;
94 for (i = 0; i <
height; i++) {
95 for (j = 0; j <
width; j++)
96 val[j] = (val[j] >> 1) ^ -(val[j] & 1);
102 width, &left, &left_top);
105 for (j = 1; j <
width; j++)
106 dst[j] = val[j] + dst[j - 1];
119 const uint8_t *src = avpkt->
data;
122 int width_uv = avctx->
width / 2, height_uv = avctx->
height / 2;
164 offset += width_uv * height_uv;
int(* get_buffer)(struct AVCodecContext *c, AVFrame *pic)
Called at the beginning of each frame to get a buffer for it.
const uint8_t av_reverse[256]
enum PixelFormat pix_fmt
Pixel format, see PIX_FMT_xxx.
#define AVERROR_INVALIDDATA
Invalid data found when processing input.
void(* release_buffer)(struct AVCodecContext *c, AVFrame *pic)
Called to release buffers which were allocated with get_buffer.
static unsigned int get_bits(GetBitContext *s, int n)
Read 1-25 bits.
AVFrame * coded_frame
the picture in the bitstream
int bits_per_raw_sample
Bits per sample/pixel of internal libavcodec pixel/sample format.
void av_freep(void *arg)
Free a memory block which has been allocated with av_malloc(z)() or av_realloc() and set the pointer ...
static int decode(MimicContext *ctx, int quality, int num_coeffs, int is_iframe)
planar YUV 4:2:0, 12bpp, (1 Cr & Cb sample per 2x2 Y samples)
static int vble_unpack(VBLEContext *ctx, GetBitContext *gb)
bitstream reader API header.
int avpicture_get_size(enum PixelFormat pix_fmt, int width, int height)
Calculate the size in bytes that a picture of the given width and height would occupy if stored in th...
av_cold void dsputil_init(DSPContext *c, AVCodecContext *avctx)
static int init(AVCodecParserContext *s)
#define CODEC_FLAG_GRAY
Only decode/encode grayscale.
#define CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.
static int get_bits_left(GetBitContext *gb)
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.
AVFrame * avcodec_alloc_frame(void)
Allocate an AVFrame and set its fields to default values.
void(* add_hfyu_median_prediction)(uint8_t *dst, const uint8_t *top, const uint8_t *diff, int w, int *left, int *left_top)
enum AVPictureType pict_type
Picture type of the frame, see ?_TYPE below.
static void vble_restore_plane(VBLEContext *ctx, int plane, int offset, int width, int height)
int width
picture width / height.
struct AVFrame AVFrame
Audio Video Frame.
static unsigned int show_bits(GetBitContext *s, int n)
Show 1-25 bits.
int linesize[AV_NUM_DATA_POINTERS]
Size, in bytes, of the data for each picture/channel plane.
main external API structure.
static void close(AVCodecParserContext *s)
static int vble_decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPacket *avpkt)
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
static av_cold int vble_decode_close(AVCodecContext *avctx)
static unsigned int get_bits1(GetBitContext *s)
void * av_malloc(size_t size)
Allocate a block of size bytes with alignment suitable for all memory accesses (including vectors if ...
static void skip_bits(GetBitContext *s, int n)
static uint8_t vble_read_reverse_unary(GetBitContext *gb)
static int init_get_bits(GetBitContext *s, const uint8_t *buffer, int bit_size)
Initialize GetBitContext.
uint8_t * data[AV_NUM_DATA_POINTERS]
pointer to the picture/channel planes.
int key_frame
1 -> keyframe, 0-> not
static av_cold int vble_decode_init(AVCodecContext *avctx)