26 #define MAX_FRAME_SIZE 10 28 #define SYNC_WORD 0x6b21 32 #if CONFIG_BIT_DEMUXER 35 int i = 0, j, valid = 0;
41 if (j != 0 && j != 0x10 && j != 0x40 && j != 0x50 && j != 0x76)
94 if(ret != 8 * packet_size *
sizeof(uint16_t))
101 for(j=0; j < packet_size; j++)
129 "only codec g729 with 1 channel is supported by this format\n");
152 for (i = 0; i < 8 * pkt->
size; i++)
161 .mime_type =
"audio/bit",
static void write_packet(OutputFile *of, AVPacket *pkt, OutputStream *ost, int unqueue)
void avio_wl16(AVIOContext *s, unsigned int val)
#define AVERROR_INVALIDDATA
Invalid data found when processing input.
static void put_bits(Jpeg2000EncoderContext *s, int val, int n)
put n times val bit
int64_t pos
byte position in stream, -1 if unknown
enum AVCodecID codec_id
Specific type of the encoded data (the codec used).
This struct describes the properties of an encoded stream.
int64_t duration
Duration of this packet in AVStream->time_base units, 0 if unknown.
AVStream * avformat_new_stream(AVFormatContext *s, const AVCodec *c)
Add a new stream to a media file.
AVStream ** streams
A list of all streams in the file.
#define AVERROR_EOF
End of file.
bitstream reader API header.
static av_always_inline int64_t avio_tell(AVIOContext *s)
ftell() equivalent for AVIOContext.
static int probe(AVProbeData *p)
int avio_read(AVIOContext *s, unsigned char *buf, int size)
Read size bytes from AVIOContext into buf.
int av_new_packet(AVPacket *pkt, int size)
Allocate the payload of a packet and initialize its fields with default values.
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
enum AVMediaType codec_type
General type of the encoded data.
int buf_size
Size of buf except extra allocated bytes.
unsigned char * buf
Buffer must have AVPROBE_PADDING_SIZE of extra allocated bytes filled with zero.
int block_align
Audio only.
static int read_header(FFV1Context *f)
static int read_packet(void *opaque, uint8_t *buf, int buf_size)
AVIOContext * pb
I/O context.
static unsigned int get_bits1(GetBitContext *s)
static int init_get_bits(GetBitContext *s, const uint8_t *buffer, int bit_size)
Initialize GetBitContext.
This structure contains the data a format has to probe a file.
int sample_rate
Audio only.
unsigned int avio_rl16(AVIOContext *s)
static void flush_put_bits(PutBitContext *s)
Pad the end of the output stream with zeros.
static void init_put_bits(PutBitContext *s, uint8_t *buffer, int buffer_size)
Initialize the PutBitContext s.
static void write_header(FFV1Context *f)
int bits_per_coded_sample
The number of bits per sample in the codedwords.
AVCodecParameters * codecpar
Codec parameters associated with this stream.
int avio_feof(AVIOContext *s)
feof() equivalent for AVIOContext.
This structure stores compressed data.