aboutsummaryrefslogtreecommitdiffstats
path: root/doc/ffprobe.xsd
blob: d6947649ff9271d88644886005346b94cf5ff144 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
<?xml version="1.0" encoding="UTF-8"?>

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    targetNamespace="http://www.ffmpeg.org/schema/ffprobe"
    xmlns:ffprobe="http://www.ffmpeg.org/schema/ffprobe">

    <xsd:element name="ffprobe" type="ffprobe:ffprobeType"/>

    <xsd:complexType name="ffprobeType">
        <xsd:sequence>
            <xsd:element name="packets"  type="ffprobe:packetsType" minOccurs="0" maxOccurs="1" />
            <xsd:element name="frames"   type="ffprobe:framesType"  minOccurs="0" maxOccurs="1" />
            <xsd:element name="streams"  type="ffprobe:streamsType" minOccurs="0" maxOccurs="1" />
            <xsd:element name="format"   type="ffprobe:formatType"  minOccurs="0" maxOccurs="1" />
            <xsd:element name="error"    type="ffprobe:errorType"   minOccurs="0" maxOccurs="1" />
        </xsd:sequence>
    </xsd:complexType>

    <xsd:complexType name="packetsType">
        <xsd:sequence>
            <xsd:element name="packet" type="ffprobe:packetType" minOccurs="0" maxOccurs="unbounded"/>
        </xsd:sequence>
    </xsd:complexType>

    <xsd:complexType name="framesType">
        <xsd:sequence>
            <xsd:element name="frame" type="ffprobe:frameType" minOccurs="0" maxOccurs="unbounded"/>
        </xsd:sequence>
    </xsd:complexType>

    <xsd:complexType name="packetType">
      <xsd:attribute name="codec_type"    type="xsd:string" use="required" />
      <xsd:attribute name="stream_index"  type="xsd:int" use="required" />
      <xsd:attribute name="pts"           type="xsd:long"  />
      <xsd:attribute name="pts_time"      type="xsd:float" />
      <xsd:attribute name="dts"           type="xsd:long"  />
      <xsd:attribute name="dts_time"      type="xsd:float" />
      <xsd:attribute name="duration"      type="xsd:long"  />
      <xsd:attribute name="duration_time" type="xsd:float" />
      <xsd:attribute name="size"          type="xsd:long" use="required" />
      <xsd:attribute name="pos"           type="xsd:long"  />
      <xsd:attribute name="flags"         type="xsd:string" use="required" />
    </xsd:complexType>

    <xsd:complexType name="frameType">
      <xsd:attribute name="media_type"    type="xsd:string" use="required"/>
      <xsd:attribute name="key_frame"     type="xsd:int"    use="required"/>
      <xsd:attribute name="pts"           type="xsd:long" />
      <xsd:attribute name="pts_time"      type="xsd:float"/>
      <xsd:attribute name="pkt_pts"       type="xsd:long" />
      <xsd:attribute name="pkt_pts_time"  type="xsd:float"/>
      <xsd:attribute name="pkt_dts"       type="xsd:long" />
      <xsd:attribute name="pkt_dts_time"  type="xsd:float"/>
      <xsd:attribute name="pkt_pos"       type="xsd:long" />

      <!-- video attributes -->
      <xsd:attribute name="width"                  type="xsd:long"  />
      <xsd:attribute name="height"                 type="xsd:long"  />
      <xsd:attribute name="pix_fmt"                type="xsd:string"/>
      <xsd:attribute name="sample_aspect_ratio"    type="xsd:string"/>
      <xsd:attribute name="pict_type"              type="xsd:string"/>
      <xsd:attribute name="coded_picture_number"   type="xsd:long"  />
      <xsd:attribute name="display_picture_number" type="xsd:long"  />
      <xsd:attribute name="interlaced_frame"       type="xsd:int"   />
      <xsd:attribute name="top_field_first"        type="xsd:int"   />
      <xsd:attribute name="repeat_pict"            type="xsd:int"   />
      <xsd:attribute name="reference"              type="xsd:int"   />
    </xsd:complexType>

    <xsd:complexType name="streamsType">
        <xsd:sequence>
            <xsd:element name="stream" type="ffprobe:streamType" minOccurs="0" maxOccurs="unbounded"/>
        </xsd:sequence>
    </xsd:complexType>

    <xsd:complexType name="streamType">
      <xsd:attribute name="index"            type="xsd:int" use="required"/>
      <xsd:attribute name="codec_name"       type="xsd:string" />
      <xsd:attribute name="codec_long_name"  type="xsd:string" />
      <xsd:attribute name="codec_type"       type="xsd:string" />
      <xsd:attribute name="codec_time_base"  type="xsd:string" use="required"/>
      <xsd:attribute name="codec_tag"        type="xsd:string" use="required"/>
      <xsd:attribute name="codec_tag_string" type="xsd:string" use="required"/>

      <!-- video attributes -->
      <xsd:attribute name="width"                type="xsd:int"/>
      <xsd:attribute name="height"               type="xsd:int"/>
      <xsd:attribute name="has_b_frames"         type="xsd:int"/>
      <xsd:attribute name="sample_aspect_ratio"  type="xsd:string"/>
      <xsd:attribute name="display_aspect_ratio" type="xsd:string"/>
      <xsd:attribute name="pix_fmt"              type="xsd:string"/>
      <xsd:attribute name="level"                type="xsd:int"/>
      <xsd:attribute name="timecode"             type="xsd:string"/>

      <!-- audio attributes -->
      <xsd:attribute name="sample_fmt"       type="xsd:string"/>
      <xsd:attribute name="sample_rate"      type="xsd:int"/>
      <xsd:attribute name="channels"         type="xsd:int"/>
      <xsd:attribute name="bits_per_sample"  type="xsd:int"/>

      <xsd:attribute name="id"               type="xsd:string"/>
      <xsd:attribute name="r_frame_rate"     type="xsd:string" use="required"/>
      <xsd:attribute name="avg_frame_rate"   type="xsd:string" use="required"/>
      <xsd:attribute name="time_base"        type="xsd:string" use="required"/>
      <xsd:attribute name="start_time"       type="xsd:float"/>
      <xsd:attribute name="duration"         type="xsd:float"/>
      <xsd:attribute name="nb_frames"        type="xsd:int"/>
    </xsd:complexType>

    <xsd:complexType name="formatType">
      <xsd:sequence>
        <xsd:element name="tag" type="ffprobe:tagType" minOccurs="0" maxOccurs="unbounded"/>
      </xsd:sequence>

      <xsd:attribute name="filename"         type="xsd:string" use="required"/>
      <xsd:attribute name="nb_streams"       type="xsd:int"    use="required"/>
      <xsd:attribute name="format_name"      type="xsd:string" use="required"/>
      <xsd:attribute name="format_long_name" type="xsd:string" use="required"/>
      <xsd:attribute name="start_time"       type="xsd:float"/>
      <xsd:attribute name="duration"         type="xsd:float"/>
      <xsd:attribute name="size"             type="xsd:long"/>
      <xsd:attribute name="bit_rate"         type="xsd:long"/>
    </xsd:complexType>

    <xsd:complexType name="tagType">
      <xsd:attribute name="key"   type="xsd:string" use="required"/>
      <xsd:attribute name="value" type="xsd:string" use="required"/>
    </xsd:complexType>

    <xsd:complexType name="errorType">
      <xsd:attribute name="code"   type="xsd:int"    use="required"/>
      <xsd:attribute name="string" type="xsd:string" use="required"/>
    </xsd:complexType>
</xsd:schema>