Raw Video Decoder.
More...
Go to the source code of this file.
Raw Video Decoder.
Definition in file rawdec.c.
#define SCALE16 |
( |
|
x, |
|
|
|
bits |
|
) |
| (((x) << (16 - (bits))) | ((x) >> (2 * (bits) - 16))) |
#define MKSCALE16 |
( |
|
name, |
|
|
|
r16, |
|
|
|
w16 |
|
) |
| |
Value:
for (i = 0; i + 1 < buf_size; i += 2) \
w16(dst + i,
SCALE16(r16(
buf + i), avctx->bits_per_coded_sample)); \
} else { \
for (i = 0; i < avctx->width * avctx->height; i++) {
\
w16(dst + i*2,
SCALE16(sample, avctx->bits_per_coded_sample)); \
} \
} \
}
static unsigned int get_bits(GetBitContext *s, int n)
Read 1-25 bits.
main external API structure.
static int init_get_bits(GetBitContext *s, const uint8_t *buffer, int bit_size)
Initialize GetBitContext.
Scale buffer to 16 bits per coded sample resolution.
Definition at line 148 of file rawdec.c.
Initial value:={
}
#define AV_OPT_FLAG_VIDEO_PARAM
#define AV_OPT_FLAG_DECODING_PARAM
a generic parameter which can be set by the user for demuxing or decoding
Definition at line 58 of file rawdec.c.
Initial value:= {
.class_name = "rawdec",
}
#define LIBAVUTIL_VERSION_INT
static const AVOption options[]
Definition at line 63 of file rawdec.c.
Initial value:= {
.name = "rawvideo",
}
static av_cold int init(AVCodecContext *avctx)
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
static int raw_decode(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
static av_cold int raw_close_decoder(AVCodecContext *avctx)
#define AV_CODEC_CAP_PARAM_CHANGE
Codec supports changed parameters at any point.
static av_cold int raw_init_decoder(AVCodecContext *avctx)
static int decode(AVCodecContext *avctx, AVFrame *frame, int *got_frame, AVPacket *pkt)
static const AVClass rawdec_class
Definition at line 493 of file rawdec.c.