32 void *
data,
int *got_frame,
36 int buf_size = avpkt->
size;
39 unsigned int x, y,
width = (avctx->
width + 7) / 8;
42 if (buf_size <= 2 * avctx->
height)
55 buf_size -= 2 * avctx->
height;
57 for (y = 0; y < avctx->
height; y++) {
58 unsigned int pkt_size = bytestream2_get_le16(&idx);
64 if (pkt_size > buf_size) {
72 int size = bytestream2_get_byte(&gb);
78 size = bytestream2_get_byte(&gb);
81 value = bytestream2_get_byte(&gb);
#define AVERROR_INVALIDDATA
Invalid data found when processing input.
This structure describes decoded (raw) audio or video data.
ptrdiff_t const GLvoid * data
#define AV_LOG_WARNING
Something somehow does not look correct.
#define avpriv_request_sample(...)
enum AVPixelFormat pix_fmt
Pixel format, see AV_PIX_FMT_xxx.
static av_always_inline void bytestream2_init(GetByteContext *g, const uint8_t *buf, int buf_size)
GLsizei GLboolean const GLfloat * value
static av_always_inline int bytestream2_get_bytes_left(GetByteContext *g)
static av_always_inline void bytestream2_skip(GetByteContext *g, unsigned int size)
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
static int msp2_decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
const char * name
Name of the codec implementation.
enum AVPictureType pict_type
Picture type of the frame.
int width
picture width / height.
Libavcodec external API header.
int linesize[AV_NUM_DATA_POINTERS]
For video, size in bytes of each picture line.
main external API structure.
int ff_get_buffer(AVCodecContext *avctx, AVFrame *frame, int flags)
Get a buffer for a frame.
uint8_t * data[AV_NUM_DATA_POINTERS]
pointer to the picture/channel planes.
Y , 1bpp, 0 is black, 1 is white, in each byte pixels are ordered from the msb to the lsb...
common internal api header.
int key_frame
1 -> keyframe, 0-> not
This structure stores compressed data.
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.