Go to the documentation of this file.
27 #define MMS_MAX_STREAMS 256
34 size_to_copy =
FFMIN(
size, remaining_size);
36 memcpy(
buf, pos, size_to_copy);
64 "Corrupt stream (invalid ASF header, size=%d)\n",
79 if (!chunksize || chunksize >
end - p) {
81 "Corrupt stream (header chunksize %"PRId64
" is invalid)\n",
91 "Corrupt stream (too large pkt_len %d)\n",
99 stream_id =
flags & 0x7F;
114 "Corrupt stream (too many A/V streams)\n");
120 int stream_count =
AV_RL16(p + 84), ext_len_count =
AV_RL16(p + 86);
122 while (stream_count--) {
125 "Corrupt stream (next stream name length is not in the buffer)\n");
130 while (ext_len_count--) {
133 "Corrupt stream (next extension system info length is not in the buffer)\n");
140 "Corrupt stream (the last extension system info length is invalid)\n");
148 if (chunksize >
end - p) {
150 "Corrupt stream (header chunksize %"PRId64
" is invalid)\n",
Filter the word “frame” indicates either a video frame or a group of audio as stored in an AVFrame structure Format for each input and each output the list of supported formats For video that means pixel format For audio that means channel sample they are references to shared objects When the negotiation mechanism computes the intersection of the formats supported at each end of a all references to both lists are replaced with a reference to the intersection And when a single format is eventually chosen for a link amongst the remaining all references to the list are updated That means that if a filter requires that its input and output have the same format amongst a supported all it has to do is use a reference to the same list of formats query_formats can leave some formats unset and return AVERROR(EAGAIN) to cause the negotiation mechanism toagain later. That can be used by filters with complex requirements to use the format negotiated on one link to set the formats supported on another. Frame references ownership and permissions
static av_cold int end(AVCodecContext *avctx)
uint8_t * asf_header
Internal handling of the ASF header.
const ff_asf_guid ff_asf_stream_header
int stream_num
stream numbers.
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
int ff_mms_asf_header_parser(MMSContext *mms)
void * av_fast_realloc(void *ptr, unsigned int *size, size_t min_size)
Reallocate the given buffer if it is not large enough, otherwise do nothing.
const ff_asf_guid ff_asf_data_header
int ff_mms_read_header(MMSContext *mms, uint8_t *buf, const int size)
#define MMS_MAX_STREAMS
arbitrary sanity check value
uint64_t_TMPL AV_WL64 unsigned int_TMPL AV_WL32 unsigned int_TMPL AV_WL24 unsigned int_TMPL AV_RL16
uint8_t in_buffer[65536]
Buffer for incoming packets.
const ff_asf_guid ff_asf_header
uint8_t out_buffer[512]
Buffer for outgoing packet.
const ff_asf_guid ff_asf_head1_guid
int ff_mms_read_data(MMSContext *mms, uint8_t *buf, const int size)
int remaining_in_len
Reading length from incoming buffer.
const ff_asf_guid ff_asf_ext_stream_header
uint64_t_TMPL AV_WL64 unsigned int_TMPL AV_RL32
int asf_header_size
Size of stored ASF header.
const ff_asf_guid ff_asf_file_header
#define flags(name, subs,...)
#define AVERROR_INVALIDDATA
Invalid data found when processing input.
static const av_unused uint8_t * skip_bytes(CABACContext *c, int n)
Skip n bytes and reset the decoder.
unsigned int nb_streams_allocated
allocated size of streams
uint8_t * read_in_ptr
Pointer for reading from incoming buffer.