1 /*****************************************************************************
2 * asf.h: MMS access plug-in
3 *****************************************************************************
4 * Copyright (C) 2001-2004 the VideoLAN team
7 * Authors: Laurent Aimar <fenrir@via.ecp.fr>
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
19 * You should have received a copy of the GNU General Public License
20 * along with this program; if not, write to the Free Software
21 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
22 *****************************************************************************/
24 /****************************************************************************
26 * Definitions and data duplicated from asf demuxers but I want access
27 * and demux plugins to be independent
29 ****************************************************************************/
34 #define ASF_STREAM_VIDEO 0x0001
35 #define ASF_STREAM_AUDIO 0x0002
36 #define ASF_STREAM_UNKNOWN 0xffff
40 int i_cat; /* ASF_STREAM_VIDEO, ASF_STREAM_AUDIO */
41 int i_bitrate; /* -1 if unknown */
48 int64_t i_data_packets_count;
49 int32_t i_min_data_packet_size;
51 asf_stream_t stream[128];
64 void GenerateGuid ( guid_t * );
65 void asf_HeaderParse ( asf_header_t *, uint8_t *, int );
66 void asf_StreamSelect ( asf_header_t *,
67 int i_bitrate_max, bool b_all, bool b_audio,
70 #define GUID_FMT "%8.8x-%4.4x-%4.4x-%2.2x%2.2x%2.2x%2.2x%2.2x%2.2x%2.2x%2.2x"
71 #define GUID_PRINT( guid ) \
75 (guid).v4[0],(guid).v4[1],(guid).v4[2],(guid).v4[3], \
76 (guid).v4[4],(guid).v4[5],(guid).v4[6],(guid).v4[7]
78 static const guid_t asf_object_header_guid =
83 { 0xA6,0xD9, 0x00,0xAA,0x00,0x62,0xCE,0x6C }
86 static const guid_t asf_object_file_properties_guid =
91 { 0x8e,0xe4, 0x00,0xC0,0x0C,0x20,0x53,0x65 }
94 static const guid_t asf_object_stream_properties_guid =
99 { 0x8E,0xE6, 0x00,0xC0,0x0C,0x20,0x53,0x65 }
102 static const guid_t asf_object_stream_type_audio =
107 { 0xA8,0xFD, 0x00,0x80,0x5F,0x5C,0x44,0x2B }
110 static const guid_t asf_object_stream_type_video =
115 { 0xA8,0xFD, 0x00,0x80,0x5F,0x5C,0x44,0x2B }
118 static const guid_t asf_object_bitrate_properties_guid =
123 { 0x8D,0x82,0x00,0x60,0x97,0xC9,0xA2,0xB2 }
126 static const guid_t asf_object_bitrate_mutual_exclusion_guid =
131 { 0x90,0x34,0x00,0xA0,0xC9,0x03,0x49,0xBE }
134 static const guid_t asf_object_extended_stream_properties_guid =
139 { 0x83, 0x99, 0xA9, 0x69, 0x52, 0x06, 0x5B, 0x5A }
142 static const guid_t asf_object_header_extension_guid =
147 { 0x8E, 0xE3, 0x00, 0xC0, 0x0C, 0x20, 0x53, 0x65 }