patches/videoparsers: Rebase the patch on top of gst-vaapi-branch commit 20ee952
authorSreerenj Balachandran <sreerenj.balachandran@intel.com>
Tue, 26 May 2015 07:21:59 +0000 (10:21 +0300)
committerSreerenj Balachandran <sreerenj.balachandran@intel.com>
Tue, 26 May 2015 07:21:59 +0000 (10:21 +0300)
Signed-off-by: Sreerenj Balachandran <sreerenj.balachandran@intel.com>
patches/videoparsers/0003-h264parse-default-to-byte-stream-nalu-format-Annex-B.patch [new file with mode: 0644]
patches/videoparsers/0004-h264parse-default-to-byte-stream-nalu-format-Annex-B.patch [deleted file]
patches/videoparsers/series.frag

diff --git a/patches/videoparsers/0003-h264parse-default-to-byte-stream-nalu-format-Annex-B.patch b/patches/videoparsers/0003-h264parse-default-to-byte-stream-nalu-format-Annex-B.patch
new file mode 100644 (file)
index 0000000..4bd43ee
--- /dev/null
@@ -0,0 +1,44 @@
+From 7650c8681ecf1304a59e7cc4c0bc9eba4f753ffa Mon Sep 17 00:00:00 2001
+From: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
+Date: Tue, 26 May 2015 09:33:57 +0300
+Subject: [PATCH 3/3] h264parse: default to byte-stream/nalu format (Annex B).
+
+Always default to stream-format=byte-stream,alignment=nalu if avcC
+format was not detected. This is the natural stream format specified
+in the standard (Annex.B): a series of NAL units prefixed with the
+usual start code.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=732167
+
+Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
+Signed-off-by: Sreerenj Balachandran <sreerenj.balachandran@intel.com>
+---
+ gst/vaapi/gsth264parse.c | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/gst/vaapi/gsth264parse.c b/gst/vaapi/gsth264parse.c
+index 76f7686..b28d449 100644
+--- a/gst/vaapi/gsth264parse.c
++++ b/gst/vaapi/gsth264parse.c
+@@ -388,7 +388,8 @@ gst_h264_parse_negotiate (GstH264Parse * h264parse, gint in_format,
+   if (!format)
+     format = GST_H264_PARSE_FORMAT_BYTE;
+   if (!align)
+-    align = GST_H264_PARSE_ALIGN_AU;
++    align = format == GST_H264_PARSE_FORMAT_BYTE ? GST_H264_PARSE_ALIGN_NAL :
++        GST_H264_PARSE_ALIGN_AU;
+   GST_DEBUG_OBJECT (h264parse, "selected format %s, alignment %s",
+       gst_h264_parse_get_string (h264parse, TRUE, format),
+@@ -2260,6 +2261,8 @@ gst_h264_parse_set_caps (GstBaseParse * parse, GstCaps * caps)
+   /* bytestream caps sanity checks */
+   if (format == GST_H264_PARSE_FORMAT_BYTE) {
++    if (align == GST_H264_PARSE_ALIGN_NONE)
++      align = GST_H264_PARSE_ALIGN_NAL;
+     /* should have SPS/PSS in-band (and/or oob in streamheader field) */
+     if (codec_data_value != NULL)
+       goto bytestream_caps_with_codec_data;
+-- 
+2.1.4
+
diff --git a/patches/videoparsers/0004-h264parse-default-to-byte-stream-nalu-format-Annex-B.patch b/patches/videoparsers/0004-h264parse-default-to-byte-stream-nalu-format-Annex-B.patch
deleted file mode 100644 (file)
index a1d2360..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-From 134793f35f1a219c79b32b2d23df73ceff0b5e32 Mon Sep 17 00:00:00 2001
-From: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
-Date: Tue, 24 Jun 2014 17:27:12 +0200
-Subject: [PATCH 3/3] h264parse: default to byte-stream/nalu format (Annex B).
-
-Always default to stream-format=byte-stream,alignment=nalu if avcC
-format was not detected. This is the natural stream format specified
-in the standard (Annex.B): a series of NAL units prefixed with the
-usual start code.
-
-https://bugzilla.gnome.org/show_bug.cgi?id=732167
-
-Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
----
- gst/vaapi/gsth264parse.c | 5 +++--
- 1 file changed, 3 insertions(+), 2 deletions(-)
-
-diff --git a/gst/vaapi/gsth264parse.c b/gst/vaapi/gsth264parse.c
-index fceec68..f15b1b0 100644
---- a/gst/vaapi/gsth264parse.c
-+++ b/gst/vaapi/gsth264parse.c
-@@ -393,7 +393,8 @@ gst_h264_parse_negotiate (GstH264Parse * h264parse, gint in_format,
-   if (!format)
-     format = GST_H264_PARSE_FORMAT_BYTE;
-   if (!align)
--    align = GST_H264_PARSE_ALIGN_AU;
-+    align = format == GST_H264_PARSE_FORMAT_BYTE ? GST_H264_PARSE_ALIGN_NAL :
-+        GST_H264_PARSE_ALIGN_AU;
-   GST_DEBUG_OBJECT (h264parse, "selected format %s, alignment %s",
-       gst_h264_parse_get_string (h264parse, TRUE, format),
-@@ -2204,7 +2205,7 @@ gst_h264_parse_set_caps (GstBaseParse * parse, GstCaps * caps)
-     if (format == GST_H264_PARSE_FORMAT_NONE) {
-       format = GST_H264_PARSE_FORMAT_BYTE;
--      align = GST_H264_PARSE_ALIGN_AU;
-+      align = GST_H264_PARSE_ALIGN_NAL;
-     }
-   }
--- 
-2.1.4
-
index 040b2bd0fa55e8672500856a030f296470509132..227df479a558a324d9e5f18796c82b73adec4a6a 100644 (file)
@@ -3,6 +3,6 @@
 videoparsers_patches_base = \
        0001-plugins-compile-the-built-in-video-parsers-as-vaapip.patch \
        0002-h264parse-fix-build-with-older-GStreamer-1.x-stacks.patch  \
-       0004-h264parse-default-to-byte-stream-nalu-format-Annex-B.patch \
+        0003-h264parse-default-to-byte-stream-nalu-format-Annex-B.patch \
         0001-h265parse-include-gstvaapiparse.h.patch \
        $(NULL)