[FFmpeg-devel] [PATCH] ffprobe.xsd: Add packets_and_frames element definition

Tobias Rapp t.rapp at noa-audio.com
Thu Oct 23 15:17:55 CEST 2014


Attached patch allows validation of ffprobe XML output if -show_packets 
and -show_frames are both set.
-------------- next part --------------
From 0c10cf28993f61cbb8365caf8d06f5d5b6111a80 Mon Sep 17 00:00:00 2001
From: Tobias Rapp <t.rapp at noa-audio.com>
Date: Thu, 23 Oct 2014 15:10:28 +0200
Subject: [PATCH] ffprobe.xsd: Add packets_and_frames element definition

This allows validation of ffprobe XML output if -show_packets and
-show_frames are both set.
---
 doc/ffprobe.xsd | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/doc/ffprobe.xsd b/doc/ffprobe.xsd
index f4d679e..c2cab37 100644
--- a/doc/ffprobe.xsd
+++ b/doc/ffprobe.xsd
@@ -13,6 +13,7 @@
             <xsd:element name="pixel_formats"    type="ffprobe:pixelFormatsType"    minOccurs="0" maxOccurs="1" />
             <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="packets_and_frames" type="ffprobe:packetsAndFramesType" minOccurs="0" maxOccurs="1" />
             <xsd:element name="programs" type="ffprobe:programsType" minOccurs="0" maxOccurs="1" />
             <xsd:element name="streams"  type="ffprobe:streamsType" minOccurs="0" maxOccurs="1" />
             <xsd:element name="chapters" type="ffprobe:chaptersType" minOccurs="0" maxOccurs="1" />
@@ -36,6 +37,16 @@
         </xsd:sequence>
     </xsd:complexType>
 
+    <xsd:complexType name="packetsAndFramesType">
+        <xsd:sequence>
+            <xsd:choice minOccurs="0" maxOccurs="unbounded">
+                <xsd:element name="packet" type="ffprobe:packetType" minOccurs="0" maxOccurs="unbounded"/>
+                <xsd:element name="frame" type="ffprobe:frameType" minOccurs="0" maxOccurs="unbounded"/>
+                <xsd:element name="subtitle" type="ffprobe:subtitleType" minOccurs="0" maxOccurs="unbounded"/>
+            </xsd:choice>
+        </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" />
-- 
1.9.1


More information about the ffmpeg-devel mailing list