Go to the documentation of this file.
27 #include "config_components.h"
37 const uint8_t *buf = avpkt->
data;
38 int buf_size = avpkt->
size;
49 recoded = buf_recoded->
data;
72 for (
i = 2;
i < buf_size-2 && j < buf_size+1024-2;
i++)
73 recoded[j++] = buf[
i];
75 for (
i = 14;
i < buf_size && j < buf_size+1024-3;
i++)
77 recoded[j++] = buf[
i];
87 avpkt->
buf = buf_recoded;
88 avpkt->
data = recoded;
94 #if CONFIG_SP5X_DECODER
110 #if CONFIG_AMV_DECODER
#define FF_CODEC_CAP_INIT_CLEANUP
The codec allows calling the close function for deallocation even if the init function returned a fai...
static const uint8_t sp5x_data_sos[]
uint8_t * data
The data buffer.
const FFCodec ff_sp5x_decoder
AVCodec p
The public AVCodec.
av_cold int ff_mjpeg_decode_init(AVCodecContext *avctx)
const FFCodec ff_amv_decoder
av_cold int ff_mjpeg_decode_end(AVCodecContext *avctx)
int ff_mjpeg_receive_frame(AVCodecContext *avctx, AVFrame *frame)
AVBufferRef * buf
A reference to the reference-counted buffer where the packet data is stored.
void av_buffer_unref(AVBufferRef **buf)
Free a given reference and automatically free the buffer if there are no more references to it.
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() or get_encode_buffer() for allocating buffers and supports custom allocators.
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
static const uint8_t sp5x_data_sof[]
static const uint8_t sp5x_data_dqt[]
#define i(width, name, range_min, range_max)
#define FF_CODEC_CAP_INIT_THREADSAFE
The codec does not modify any global variables in the init function, allowing to call the init functi...
const char * name
Name of the codec implementation.
#define FF_CODEC_CAP_SETS_PKT_DTS
Decoders marked with FF_CODEC_CAP_SETS_PKT_DTS want to set AVFrame.pkt_dts manually.
AVBufferRef * av_buffer_allocz(size_t size)
Same as av_buffer_alloc(), except the returned buffer will be initialized to zero.
main external API structure.
#define FF_CODEC_RECEIVE_FRAME_CB(func)
int ff_sp5x_process_packet(AVCodecContext *avctx, AVPacket *avpkt)
int coded_width
Bitstream width / height, may be different from width/height e.g.
static const uint8_t sp5x_data_dht[]
A reference to a data buffer.
This structure stores compressed data.
int width
picture width / height.
static const uint8_t sp5x_qscale_five_quant_table[][64]