30 #define RTP_VC2HQ_PL_HEADER_SIZE 4
32 #define DIRAC_DATA_UNIT_HEADER_SIZE 13
33 #define DIRAC_PIC_NR_SIZE 4
34 #define DIRAC_RTP_PCODE_HQ_PIC_FRAGMENT 0xEC
41 AV_WB8 (&rtp_ctx->
buf[2], i ? (f ? (0x03) : (0x02)) : 0x00);
44 memcpy(&rtp_ctx->
buf[4 + info_hdr_size], buf, size);
52 int lvl, second_field;
53 uint32_t pic_nr, wavelet_depth, prefix_bytes, size_scaler;
55 char *info_hdr = &rtp_ctx->
buf[4];
60 second_field = interlaced && (pic_nr & 0x01);
71 for(lvl = 0; lvl < wavelet_depth; lvl++)
81 AV_WB16(&info_hdr[ 4], prefix_bytes);
82 AV_WB16(&info_hdr[ 6], size_scaler);
83 AV_WB16(&info_hdr[ 8], frag_len);
91 AV_WB16(&info_hdr[ 8], frag_len);
105 const uint8_t *unit = frame_buf;
110 parse_code = unit[4];
113 switch (parse_code) {
#define DIRAC_RTP_PCODE_HQ_PIC_FRAGMENT
static void send_picture(AVFormatContext *ctx, const uint8_t *buf, int size, int interlaced)
#define RTP_VC2HQ_PL_HEADER_SIZE
Interface to Dirac Decoder/Encoder.
static av_cold int end(AVCodecContext *avctx)
uint64_t_TMPL AV_WL64 unsigned int_TMPL AV_WL32 unsigned int_TMPL AV_WL24 unsigned int_TMPL AV_WL16 uint64_t_TMPL AV_WB64 unsigned int_TMPL AV_RB32
static int get_bits_count(const GetBitContext *s)
bitstream reader API header.
#define DIRAC_PIC_NR_SIZE
#define DIRAC_DATA_UNIT_HEADER_SIZE
void ff_rtp_send_data(AVFormatContext *s1, const uint8_t *buf1, int len, int m)
static void send_packet(AVFormatContext *ctx, uint8_t parse_code, int info_hdr_size, const uint8_t *buf, int size, int i, int f, int rtp_m)
void ff_rtp_send_vc2hq(AVFormatContext *ctx, const uint8_t *frame_buf, int frame_size, int interlaced)
static int init_get_bits(GetBitContext *s, const uint8_t *buffer, int bit_size)
Initialize GetBitContext.
void avpriv_report_missing_feature(void *avc, const char *msg,...) av_printf_format(2
Log a generic warning message about a missing feature.
void * priv_data
Format private data.
static unsigned get_interleaved_ue_golomb(GetBitContext *gb)
AVFormatContext * rtp_ctx