ffprobe.xsd 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  3. targetNamespace="http://www.ffmpeg.org/schema/ffprobe"
  4. xmlns:ffprobe="http://www.ffmpeg.org/schema/ffprobe">
  5. <xsd:element name="ffprobe" type="ffprobe:ffprobeType"/>
  6. <xsd:complexType name="ffprobeType">
  7. <xsd:sequence>
  8. <xsd:element name="program_version" type="ffprobe:programVersionType" minOccurs="0" maxOccurs="1" />
  9. <xsd:element name="library_versions" type="ffprobe:libraryVersionsType" minOccurs="0" maxOccurs="1" />
  10. <xsd:element name="pixel_formats" type="ffprobe:pixelFormatsType" minOccurs="0" maxOccurs="1" />
  11. <xsd:element name="packets" type="ffprobe:packetsType" minOccurs="0" maxOccurs="1" />
  12. <xsd:element name="frames" type="ffprobe:framesType" minOccurs="0" maxOccurs="1" />
  13. <xsd:element name="packets_and_frames" type="ffprobe:packetsAndFramesType" minOccurs="0" maxOccurs="1" />
  14. <xsd:element name="programs" type="ffprobe:programsType" minOccurs="0" maxOccurs="1" />
  15. <xsd:element name="streams" type="ffprobe:streamsType" minOccurs="0" maxOccurs="1" />
  16. <xsd:element name="chapters" type="ffprobe:chaptersType" minOccurs="0" maxOccurs="1" />
  17. <xsd:element name="format" type="ffprobe:formatType" minOccurs="0" maxOccurs="1" />
  18. <xsd:element name="error" type="ffprobe:errorType" minOccurs="0" maxOccurs="1" />
  19. </xsd:sequence>
  20. </xsd:complexType>
  21. <xsd:complexType name="packetsType">
  22. <xsd:sequence>
  23. <xsd:element name="packet" type="ffprobe:packetType" minOccurs="0" maxOccurs="unbounded"/>
  24. </xsd:sequence>
  25. </xsd:complexType>
  26. <xsd:complexType name="framesType">
  27. <xsd:sequence>
  28. <xsd:choice minOccurs="0" maxOccurs="unbounded">
  29. <xsd:element name="frame" type="ffprobe:frameType" minOccurs="0" maxOccurs="unbounded"/>
  30. <xsd:element name="subtitle" type="ffprobe:subtitleType" minOccurs="0" maxOccurs="unbounded"/>
  31. </xsd:choice>
  32. </xsd:sequence>
  33. </xsd:complexType>
  34. <xsd:complexType name="packetsAndFramesType">
  35. <xsd:sequence>
  36. <xsd:choice minOccurs="0" maxOccurs="unbounded">
  37. <xsd:element name="packet" type="ffprobe:packetType" minOccurs="0" maxOccurs="unbounded"/>
  38. <xsd:element name="frame" type="ffprobe:frameType" minOccurs="0" maxOccurs="unbounded"/>
  39. <xsd:element name="subtitle" type="ffprobe:subtitleType" minOccurs="0" maxOccurs="unbounded"/>
  40. </xsd:choice>
  41. </xsd:sequence>
  42. </xsd:complexType>
  43. <xsd:complexType name="packetType">
  44. <xsd:sequence>
  45. <xsd:element name="tag" type="ffprobe:tagType" minOccurs="0" maxOccurs="unbounded"/>
  46. <xsd:element name="side_data_list" type="ffprobe:packetSideDataListType" minOccurs="0" maxOccurs="1" />
  47. </xsd:sequence>
  48. <xsd:attribute name="codec_type" type="xsd:string" use="required" />
  49. <xsd:attribute name="stream_index" type="xsd:int" use="required" />
  50. <xsd:attribute name="pts" type="xsd:long" />
  51. <xsd:attribute name="pts_time" type="xsd:float" />
  52. <xsd:attribute name="dts" type="xsd:long" />
  53. <xsd:attribute name="dts_time" type="xsd:float" />
  54. <xsd:attribute name="duration" type="xsd:long" />
  55. <xsd:attribute name="duration_time" type="xsd:float" />
  56. <xsd:attribute name="convergence_duration" type="xsd:long" />
  57. <xsd:attribute name="convergence_duration_time" type="xsd:float" />
  58. <xsd:attribute name="size" type="xsd:long" use="required" />
  59. <xsd:attribute name="pos" type="xsd:long" />
  60. <xsd:attribute name="flags" type="xsd:string" use="required" />
  61. <xsd:attribute name="data" type="xsd:string" />
  62. <xsd:attribute name="data_hash" type="xsd:string" />
  63. </xsd:complexType>
  64. <xsd:complexType name="packetSideDataListType">
  65. <xsd:sequence>
  66. <xsd:element name="side_data" type="ffprobe:packetSideDataType" minOccurs="1" maxOccurs="unbounded"/>
  67. </xsd:sequence>
  68. </xsd:complexType>
  69. <xsd:complexType name="packetSideDataType">
  70. <xsd:attribute name="side_data_type" type="xsd:string"/>
  71. <xsd:attribute name="side_data_size" type="xsd:int" />
  72. </xsd:complexType>
  73. <xsd:complexType name="frameType">
  74. <xsd:sequence>
  75. <xsd:element name="tag" type="ffprobe:tagType" minOccurs="0" maxOccurs="unbounded"/>
  76. <xsd:element name="side_data_list" type="ffprobe:frameSideDataListType" minOccurs="0" maxOccurs="1" />
  77. </xsd:sequence>
  78. <xsd:attribute name="media_type" type="xsd:string" use="required"/>
  79. <xsd:attribute name="stream_index" type="xsd:int" />
  80. <xsd:attribute name="key_frame" type="xsd:int" use="required"/>
  81. <xsd:attribute name="pts" type="xsd:long" />
  82. <xsd:attribute name="pts_time" type="xsd:float"/>
  83. <xsd:attribute name="pkt_pts" type="xsd:long" />
  84. <xsd:attribute name="pkt_pts_time" type="xsd:float"/>
  85. <xsd:attribute name="pkt_dts" type="xsd:long" />
  86. <xsd:attribute name="pkt_dts_time" type="xsd:float"/>
  87. <xsd:attribute name="best_effort_timestamp" type="xsd:long" />
  88. <xsd:attribute name="best_effort_timestamp_time" type="xsd:float" />
  89. <xsd:attribute name="pkt_duration" type="xsd:long" />
  90. <xsd:attribute name="pkt_duration_time" type="xsd:float"/>
  91. <xsd:attribute name="pkt_pos" type="xsd:long" />
  92. <xsd:attribute name="pkt_size" type="xsd:int" />
  93. <!-- audio attributes -->
  94. <xsd:attribute name="sample_fmt" type="xsd:string"/>
  95. <xsd:attribute name="nb_samples" type="xsd:long" />
  96. <xsd:attribute name="channels" type="xsd:int" />
  97. <xsd:attribute name="channel_layout" type="xsd:string"/>
  98. <!-- video attributes -->
  99. <xsd:attribute name="width" type="xsd:long" />
  100. <xsd:attribute name="height" type="xsd:long" />
  101. <xsd:attribute name="pix_fmt" type="xsd:string"/>
  102. <xsd:attribute name="sample_aspect_ratio" type="xsd:string"/>
  103. <xsd:attribute name="pict_type" type="xsd:string"/>
  104. <xsd:attribute name="coded_picture_number" type="xsd:long" />
  105. <xsd:attribute name="display_picture_number" type="xsd:long" />
  106. <xsd:attribute name="interlaced_frame" type="xsd:int" />
  107. <xsd:attribute name="top_field_first" type="xsd:int" />
  108. <xsd:attribute name="repeat_pict" type="xsd:int" />
  109. </xsd:complexType>
  110. <xsd:complexType name="frameSideDataListType">
  111. <xsd:sequence>
  112. <xsd:element name="side_data" type="ffprobe:frameSideDataType" minOccurs="1" maxOccurs="unbounded"/>
  113. </xsd:sequence>
  114. </xsd:complexType>
  115. <xsd:complexType name="frameSideDataType">
  116. <xsd:attribute name="side_data_type" type="xsd:string"/>
  117. <xsd:attribute name="side_data_size" type="xsd:int" />
  118. </xsd:complexType>
  119. <xsd:complexType name="subtitleType">
  120. <xsd:attribute name="media_type" type="xsd:string" fixed="subtitle" use="required"/>
  121. <xsd:attribute name="pts" type="xsd:long" />
  122. <xsd:attribute name="pts_time" type="xsd:float"/>
  123. <xsd:attribute name="format" type="xsd:int" />
  124. <xsd:attribute name="start_display_time" type="xsd:int" />
  125. <xsd:attribute name="end_display_time" type="xsd:int" />
  126. <xsd:attribute name="num_rects" type="xsd:int" />
  127. </xsd:complexType>
  128. <xsd:complexType name="streamsType">
  129. <xsd:sequence>
  130. <xsd:element name="stream" type="ffprobe:streamType" minOccurs="0" maxOccurs="unbounded"/>
  131. </xsd:sequence>
  132. </xsd:complexType>
  133. <xsd:complexType name="programsType">
  134. <xsd:sequence>
  135. <xsd:element name="program" type="ffprobe:programType" minOccurs="0" maxOccurs="unbounded"/>
  136. </xsd:sequence>
  137. </xsd:complexType>
  138. <xsd:complexType name="streamDispositionType">
  139. <xsd:attribute name="default" type="xsd:int" use="required" />
  140. <xsd:attribute name="dub" type="xsd:int" use="required" />
  141. <xsd:attribute name="original" type="xsd:int" use="required" />
  142. <xsd:attribute name="comment" type="xsd:int" use="required" />
  143. <xsd:attribute name="lyrics" type="xsd:int" use="required" />
  144. <xsd:attribute name="karaoke" type="xsd:int" use="required" />
  145. <xsd:attribute name="forced" type="xsd:int" use="required" />
  146. <xsd:attribute name="hearing_impaired" type="xsd:int" use="required" />
  147. <xsd:attribute name="visual_impaired" type="xsd:int" use="required" />
  148. <xsd:attribute name="clean_effects" type="xsd:int" use="required" />
  149. <xsd:attribute name="attached_pic" type="xsd:int" use="required" />
  150. </xsd:complexType>
  151. <xsd:complexType name="streamType">
  152. <xsd:sequence>
  153. <xsd:element name="disposition" type="ffprobe:streamDispositionType" minOccurs="0" maxOccurs="1"/>
  154. <xsd:element name="tag" type="ffprobe:tagType" minOccurs="0" maxOccurs="unbounded"/>
  155. <xsd:element name="side_data_list" type="ffprobe:packetSideDataListType" minOccurs="0" maxOccurs="1" />
  156. </xsd:sequence>
  157. <xsd:attribute name="index" type="xsd:int" use="required"/>
  158. <xsd:attribute name="codec_name" type="xsd:string" />
  159. <xsd:attribute name="codec_long_name" type="xsd:string" />
  160. <xsd:attribute name="profile" type="xsd:string" />
  161. <xsd:attribute name="codec_type" type="xsd:string" />
  162. <xsd:attribute name="codec_time_base" type="xsd:string" use="required"/>
  163. <xsd:attribute name="codec_tag" type="xsd:string" use="required"/>
  164. <xsd:attribute name="codec_tag_string" type="xsd:string" use="required"/>
  165. <xsd:attribute name="extradata" type="xsd:string" />
  166. <xsd:attribute name="extradata_hash" type="xsd:string" />
  167. <!-- video attributes -->
  168. <xsd:attribute name="width" type="xsd:int"/>
  169. <xsd:attribute name="height" type="xsd:int"/>
  170. <xsd:attribute name="coded_width" type="xsd:int"/>
  171. <xsd:attribute name="coded_height" type="xsd:int"/>
  172. <xsd:attribute name="has_b_frames" type="xsd:int"/>
  173. <xsd:attribute name="sample_aspect_ratio" type="xsd:string"/>
  174. <xsd:attribute name="display_aspect_ratio" type="xsd:string"/>
  175. <xsd:attribute name="pix_fmt" type="xsd:string"/>
  176. <xsd:attribute name="level" type="xsd:int"/>
  177. <xsd:attribute name="color_range" type="xsd:string"/>
  178. <xsd:attribute name="color_space" type="xsd:string"/>
  179. <xsd:attribute name="color_transfer" type="xsd:string"/>
  180. <xsd:attribute name="color_primaries" type="xsd:string"/>
  181. <xsd:attribute name="chroma_location" type="xsd:string"/>
  182. <xsd:attribute name="timecode" type="xsd:string"/>
  183. <xsd:attribute name="refs" type="xsd:int"/>
  184. <!-- audio attributes -->
  185. <xsd:attribute name="sample_fmt" type="xsd:string"/>
  186. <xsd:attribute name="sample_rate" type="xsd:int"/>
  187. <xsd:attribute name="channels" type="xsd:int"/>
  188. <xsd:attribute name="channel_layout" type="xsd:string"/>
  189. <xsd:attribute name="bits_per_sample" type="xsd:int"/>
  190. <xsd:attribute name="id" type="xsd:string"/>
  191. <xsd:attribute name="r_frame_rate" type="xsd:string" use="required"/>
  192. <xsd:attribute name="avg_frame_rate" type="xsd:string" use="required"/>
  193. <xsd:attribute name="time_base" type="xsd:string" use="required"/>
  194. <xsd:attribute name="start_pts" type="xsd:long"/>
  195. <xsd:attribute name="start_time" type="xsd:float"/>
  196. <xsd:attribute name="duration_ts" type="xsd:long"/>
  197. <xsd:attribute name="duration" type="xsd:float"/>
  198. <xsd:attribute name="bit_rate" type="xsd:int"/>
  199. <xsd:attribute name="max_bit_rate" type="xsd:int"/>
  200. <xsd:attribute name="bits_per_raw_sample" type="xsd:int"/>
  201. <xsd:attribute name="nb_frames" type="xsd:int"/>
  202. <xsd:attribute name="nb_read_frames" type="xsd:int"/>
  203. <xsd:attribute name="nb_read_packets" type="xsd:int"/>
  204. </xsd:complexType>
  205. <xsd:complexType name="programType">
  206. <xsd:sequence>
  207. <xsd:element name="tag" type="ffprobe:tagType" minOccurs="0" maxOccurs="unbounded"/>
  208. <xsd:element name="streams" type="ffprobe:streamsType" minOccurs="0" maxOccurs="1"/>
  209. </xsd:sequence>
  210. <xsd:attribute name="program_id" type="xsd:int" use="required"/>
  211. <xsd:attribute name="program_num" type="xsd:int" use="required"/>
  212. <xsd:attribute name="nb_streams" type="xsd:int" use="required"/>
  213. <xsd:attribute name="start_time" type="xsd:float"/>
  214. <xsd:attribute name="start_pts" type="xsd:long"/>
  215. <xsd:attribute name="end_time" type="xsd:float"/>
  216. <xsd:attribute name="end_pts" type="xsd:long"/>
  217. <xsd:attribute name="pmt_pid" type="xsd:int" use="required"/>
  218. <xsd:attribute name="pcr_pid" type="xsd:int" use="required"/>
  219. </xsd:complexType>
  220. <xsd:complexType name="formatType">
  221. <xsd:sequence>
  222. <xsd:element name="tag" type="ffprobe:tagType" minOccurs="0" maxOccurs="unbounded"/>
  223. </xsd:sequence>
  224. <xsd:attribute name="filename" type="xsd:string" use="required"/>
  225. <xsd:attribute name="nb_streams" type="xsd:int" use="required"/>
  226. <xsd:attribute name="nb_programs" type="xsd:int" use="required"/>
  227. <xsd:attribute name="format_name" type="xsd:string" use="required"/>
  228. <xsd:attribute name="format_long_name" type="xsd:string"/>
  229. <xsd:attribute name="start_time" type="xsd:float"/>
  230. <xsd:attribute name="duration" type="xsd:float"/>
  231. <xsd:attribute name="size" type="xsd:long"/>
  232. <xsd:attribute name="bit_rate" type="xsd:long"/>
  233. <xsd:attribute name="probe_score" type="xsd:int"/>
  234. </xsd:complexType>
  235. <xsd:complexType name="tagType">
  236. <xsd:attribute name="key" type="xsd:string" use="required"/>
  237. <xsd:attribute name="value" type="xsd:string" use="required"/>
  238. </xsd:complexType>
  239. <xsd:complexType name="errorType">
  240. <xsd:attribute name="code" type="xsd:int" use="required"/>
  241. <xsd:attribute name="string" type="xsd:string" use="required"/>
  242. </xsd:complexType>
  243. <xsd:complexType name="programVersionType">
  244. <xsd:attribute name="version" type="xsd:string" use="required"/>
  245. <xsd:attribute name="copyright" type="xsd:string" use="required"/>
  246. <xsd:attribute name="build_date" type="xsd:string"/>
  247. <xsd:attribute name="build_time" type="xsd:string"/>
  248. <xsd:attribute name="compiler_ident" type="xsd:string" use="required"/>
  249. <xsd:attribute name="configuration" type="xsd:string" use="required"/>
  250. </xsd:complexType>
  251. <xsd:complexType name="chaptersType">
  252. <xsd:sequence>
  253. <xsd:element name="chapter" type="ffprobe:chapterType" minOccurs="0" maxOccurs="unbounded"/>
  254. </xsd:sequence>
  255. </xsd:complexType>
  256. <xsd:complexType name="chapterType">
  257. <xsd:sequence>
  258. <xsd:element name="tag" type="ffprobe:tagType" minOccurs="0" maxOccurs="unbounded"/>
  259. </xsd:sequence>
  260. <xsd:attribute name="id" type="xsd:int" use="required"/>
  261. <xsd:attribute name="time_base" type="xsd:string" use="required"/>
  262. <xsd:attribute name="start" type="xsd:int" use="required"/>
  263. <xsd:attribute name="start_time" type="xsd:float"/>
  264. <xsd:attribute name="end" type="xsd:int" use="required"/>
  265. <xsd:attribute name="end_time" type="xsd:float" use="required"/>
  266. </xsd:complexType>
  267. <xsd:complexType name="libraryVersionType">
  268. <xsd:attribute name="name" type="xsd:string" use="required"/>
  269. <xsd:attribute name="major" type="xsd:int" use="required"/>
  270. <xsd:attribute name="minor" type="xsd:int" use="required"/>
  271. <xsd:attribute name="micro" type="xsd:int" use="required"/>
  272. <xsd:attribute name="version" type="xsd:int" use="required"/>
  273. <xsd:attribute name="ident" type="xsd:string" use="required"/>
  274. </xsd:complexType>
  275. <xsd:complexType name="libraryVersionsType">
  276. <xsd:sequence>
  277. <xsd:element name="library_version" type="ffprobe:libraryVersionType" minOccurs="0" maxOccurs="unbounded"/>
  278. </xsd:sequence>
  279. </xsd:complexType>
  280. <xsd:complexType name="pixelFormatFlagsType">
  281. <xsd:attribute name="big_endian" type="xsd:int" use="required"/>
  282. <xsd:attribute name="palette" type="xsd:int" use="required"/>
  283. <xsd:attribute name="bitstream" type="xsd:int" use="required"/>
  284. <xsd:attribute name="hwaccel" type="xsd:int" use="required"/>
  285. <xsd:attribute name="planar" type="xsd:int" use="required"/>
  286. <xsd:attribute name="rgb" type="xsd:int" use="required"/>
  287. <xsd:attribute name="pseudopal" type="xsd:int" use="required"/>
  288. <xsd:attribute name="alpha" type="xsd:int" use="required"/>
  289. </xsd:complexType>
  290. <xsd:complexType name="pixelFormatComponentType">
  291. <xsd:attribute name="index" type="xsd:int" use="required"/>
  292. <xsd:attribute name="bit_depth" type="xsd:int" use="required"/>
  293. </xsd:complexType>
  294. <xsd:complexType name="pixelFormatComponentsType">
  295. <xsd:sequence>
  296. <xsd:element name="component" type="ffprobe:pixelFormatComponentType" minOccurs="0" maxOccurs="unbounded"/>
  297. </xsd:sequence>
  298. </xsd:complexType>
  299. <xsd:complexType name="pixelFormatType">
  300. <xsd:sequence>
  301. <xsd:element name="flags" type="ffprobe:pixelFormatFlagsType" minOccurs="0" maxOccurs="1"/>
  302. <xsd:element name="components" type="ffprobe:pixelFormatComponentsType" minOccurs="0" maxOccurs="1"/>
  303. </xsd:sequence>
  304. <xsd:attribute name="name" type="xsd:string" use="required"/>
  305. <xsd:attribute name="nb_components" type="xsd:int" use="required"/>
  306. <xsd:attribute name="log2_chroma_w" type="xsd:int"/>
  307. <xsd:attribute name="log2_chroma_h" type="xsd:int"/>
  308. <xsd:attribute name="bits_per_pixel" type="xsd:int"/>
  309. </xsd:complexType>
  310. <xsd:complexType name="pixelFormatsType">
  311. <xsd:sequence>
  312. <xsd:element name="pixel_format" type="ffprobe:pixelFormatType" minOccurs="0" maxOccurs="unbounded"/>
  313. </xsd:sequence>
  314. </xsd:complexType>
  315. </xsd:schema>