From 4bc328a2bdf96d01afd3cf4532efb9db41f00985 Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Tue, 8 Feb 2011 21:46:47 +0100 Subject: asf: split ASFContext into muxer and demuxer parts. Signed-off-by: Ronald S. Bultje --- libavformat/asfenc.c | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) (limited to 'libavformat/asfenc.c') diff --git a/libavformat/asfenc.c b/libavformat/asfenc.c index b8f8635603..709080fbbb 100644 --- a/libavformat/asfenc.c +++ b/libavformat/asfenc.c @@ -188,6 +188,31 @@ 2*PAYLOAD_HEADER_SIZE_MULTIPLE_PAYLOADS \ ) +typedef struct { + uint32_t seqno; + int is_streamed; + ASFStream streams[128]; ///< it's max number and it's not that big + /* non streamed additonnal info */ + uint64_t nb_packets; ///< how many packets are there in the file, invalid if broadcasting + int64_t duration; ///< in 100ns units + /* packet filling */ + unsigned char multi_payloads_present; + int packet_size_left; + int packet_timestamp_start; + int packet_timestamp_end; + unsigned int packet_nb_payloads; + uint8_t packet_buf[PACKET_SIZE]; + ByteIOContext pb; + /* only for reading */ + uint64_t data_offset; ///< beginning of the first data packet + + int64_t last_indexed_pts; + ASFIndex* index_ptr; + uint32_t nb_index_count; + uint32_t nb_index_memory_alloc; + uint16_t maximum_packet; +} ASFContext; + static const AVCodecTag codec_asf_bmp_tags[] = { { CODEC_ID_MPEG4, MKTAG('M', 'P', '4', 'S') }, { CODEC_ID_MPEG4, MKTAG('M', '4', 'S', '2') }, -- cgit v1.2.3