commit 9198652c32b938898355fed2dbf75f6bcb153a15
Author: Dominik 'Rathann' Mierzejewski <dominik(a)greysector.net>
Date: Fri Sep 4 16:32:02 2020 +0200
merge with -free from Fedora
0001-fix-faad2-version-check.patch | 18 ++
...rabin-Fix-spelling-error-in-debug-logging.patch | 26 ++
...Specify-directory-when-including-stdafx.h.patch | 29 +++
...Sanity-check-width-height-before-using-it.patch | 50 ++++
...dd-a-camerabin_create_view_finder_caps-he.patch | 121 ++++++++++
...nsure-codec_data-has-the-required-size-wh.patch | 28 +++
...dd-gst_camerabin_get_video_source_propert.patch | 97 ++++++++
...et-src_filter-and-zoom_src_filter-caps-wh.patch | 74 ++++++
0005-geometrictransform-crash-fix1.patch | 37 +++
0006-geometrictransform-crash-fix2.patch | 36 +++
...ugins-bad-0.10.23-drop-vpx-compat-defines.patch | 27 +++
gst-plugins-bad-0.10.23-timidity2.diff | 12 +
gstreamer-plugins-bad.spec | 265 ++++++++++++++++++---
vp8enc-bitrate-fix.patch | 23 ++
14 files changed, 805 insertions(+), 38 deletions(-)
---
diff --git a/0001-fix-faad2-version-check.patch b/0001-fix-faad2-version-check.patch
index ba92546..d725372 100644
--- a/0001-fix-faad2-version-check.patch
+++ b/0001-fix-faad2-version-check.patch
@@ -30,6 +30,24 @@ index 29b10a6..ceaf31f 100644
], [
faad2_minor_version=$minor
])
+diff --git a/configure b/configure
+index 29b10a6..ceaf31f 100644
+--- a/configure
++++ b/configure
+@@ -34232,11 +34942,11 @@
+ /* end confdefs.h. */
+
+ #include <$faad_hdr>
+- GST_CHECK_FAAD_VERSION FAAD2_VERSION
++ FAAD2_VERSION
+
+ _ACEOF
+ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+- $EGREP "GST_CHECK_FAAD_VERSION \"2\.$minor\"" >/dev/null
2>&1; then :
++ $EGREP "\"2\.$minor\"$" >/dev/null 2>&1; then :
+
+ faad2_minor_version=$minor
+
--
cgit v0.10.2
diff --git a/0001-gstcamerabin-Fix-spelling-error-in-debug-logging.patch
b/0001-gstcamerabin-Fix-spelling-error-in-debug-logging.patch
new file mode 100644
index 0000000..f98e03a
--- /dev/null
+++ b/0001-gstcamerabin-Fix-spelling-error-in-debug-logging.patch
@@ -0,0 +1,26 @@
+From 62c58f011e7069aa45e980930cdfa2d937920a77 Mon Sep 17 00:00:00 2001
+From: Hans de Goede <hdegoede(a)redhat.com>
+Date: Fri, 8 Jun 2012 10:57:54 +0200
+Subject: [PATCH 1/4] gstcamerabin: Fix spelling error in debug logging
+
+Signed-off-by: Hans de Goede <hdegoede(a)redhat.com>
+---
+ gst/camerabin/gstcamerabin.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gst/camerabin/gstcamerabin.c b/gst/camerabin/gstcamerabin.c
+index a17e02c..8a36970 100644
+--- a/gst/camerabin/gstcamerabin.c
++++ b/gst/camerabin/gstcamerabin.c
+@@ -1517,7 +1517,7 @@ gst_camerabin_set_capsfilter_caps (GstCameraBin * camera, GstCaps *
new_caps)
+ if (camera->src_zoom_filter)
+ g_object_set (G_OBJECT (camera->src_zoom_filter), "caps", new_caps,
NULL);
+ gst_camerabin_update_aspect_filter (camera, new_caps);
+- GST_INFO_OBJECT (camera, "udpated");
++ GST_INFO_OBJECT (camera, "updated");
+ }
+
+ /*
+--
+1.7.10.2
+
diff --git a/0001-modplug-Specify-directory-when-including-stdafx.h.patch
b/0001-modplug-Specify-directory-when-including-stdafx.h.patch
new file mode 100644
index 0000000..86d69ea
--- /dev/null
+++ b/0001-modplug-Specify-directory-when-including-stdafx.h.patch
@@ -0,0 +1,29 @@
+From fd4cb22ae42b146e327b12aa0507b59520ba1db2 Mon Sep 17 00:00:00 2001
+From: Iain Lane <iain.lane(a)canonical.com>
+Date: Tue, 10 Sep 2013 08:48:32 +0000
+Subject: [PATCH] modplug: Specify directory when including stdafx.h
+
+modplug stopped exposing their directory in their pcfile, meaining
+consumers accessing the headers directly fail to build.
+
+http://sourceforge.net/p/modplug-xmms/git/ci/75e9b166982ed637b59ef7cbc1835a09f768923e/
+---
+ ext/modplug/gstmodplug.cc | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/ext/modplug/gstmodplug.cc b/ext/modplug/gstmodplug.cc
+index 47154cf..a968c4a 100644
+--- a/ext/modplug/gstmodplug.cc
++++ b/ext/modplug/gstmodplug.cc
+@@ -54,7 +54,7 @@
+ #define WORDS_BIGENDIAN 0
+ #endif
+
+-#include <stdafx.h>
++#include <libmodplug/stdafx.h>
+ #include <libmodplug/sndfile.h>
+
+ #include "gstmodplug.h"
+--
+1.8.5.3
+
diff --git a/0001-vmncdec-Sanity-check-width-height-before-using-it.patch
b/0001-vmncdec-Sanity-check-width-height-before-using-it.patch
new file mode 100644
index 0000000..c7e2f32
--- /dev/null
+++ b/0001-vmncdec-Sanity-check-width-height-before-using-it.patch
@@ -0,0 +1,50 @@
+From 26f4b2c203d6d0ef0c8204a48dba504870c2cfdf Mon Sep 17 00:00:00 2001
+From: Wim Taymans <wtaymans(a)redhat.com>
+Date: Tue, 6 Dec 2016 10:24:03 +0100
+Subject: [PATCH 1/2] vmncdec: Sanity-check width/height before using it
+
+We will allocate a screen area of width*height*bpp bytes, however this
+calculation can easily overflow if too high width or height are given
+inside the stream. Nonetheless we would just assume that enough memory
+was allocated, try to fill it and overwrite as much memory as wanted.
+
+Also allocate the screen area filled with zeroes to ensure that we start
+with full-black and not any random (or not so random) data.
+
+https://scarybeastsecurity.blogspot.gr/2016/11/0day-poc-risky-design-decisions-in.html
+
+Ideally we should just remove this plugin in favour of the one in
+gst-libav, which generally seems to be of better code quality.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=774533
+---
+ gst/vmnc/vmncdec.c | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/gst/vmnc/vmncdec.c b/gst/vmnc/vmncdec.c
+index 08085b5..c83e315 100644
+--- a/gst/vmnc/vmncdec.c
++++ b/gst/vmnc/vmncdec.c
+@@ -370,7 +370,7 @@ vmnc_handle_wmvi_rectangle (GstVMncDec * dec, struct RfbRectangle
*rect,
+
+ if (dec->imagedata)
+ g_free (dec->imagedata);
+- dec->imagedata = g_malloc (dec->format.width * dec->format.height *
++ dec->imagedata = g_malloc0 (dec->format.width * dec->format.height *
+ dec->format.bytes_per_pixel);
+ GST_DEBUG_OBJECT (dec, "Allocated image data at %p", dec->imagedata);
+
+@@ -901,6 +901,10 @@ vmnc_handle_packet (GstVMncDec * dec, const guint8 * data, int len,
+ GST_WARNING_OBJECT (dec, "Rectangle out of range, type %d",
r.type);
+ return ERROR_INVALID;
+ }
++ } else if (r.width > 16384 || r.height > 16384) {
++ GST_WARNING_OBJECT (dec, "Width or height too high: %ux%u",
r.width,
++ r.height);
++ return ERROR_INVALID;
+ }
+
+ switch (r.type) {
+--
+2.9.3
+
diff --git a/0002-camerabin-Add-a-camerabin_create_view_finder_caps-he.patch
b/0002-camerabin-Add-a-camerabin_create_view_finder_caps-he.patch
new file mode 100644
index 0000000..3edb6ec
--- /dev/null
+++ b/0002-camerabin-Add-a-camerabin_create_view_finder_caps-he.patch
@@ -0,0 +1,121 @@
+From a07a1138a8cf8ad1029845dfe4cfdf5a0a36e670 Mon Sep 17 00:00:00 2001
+From: Hans de Goede <hdegoede(a)redhat.com>
+Date: Fri, 8 Jun 2012 11:31:05 +0200
+Subject: [PATCH 2/4] camerabin: Add a camerabin_create_view_finder_caps()
+ helper function
+
+Signed-off-by: Hans de Goede <hdegoede(a)redhat.com>
+---
+ gst/camerabin/gstcamerabin.c | 72 +++++++++++++++++++++++-------------------
+ 1 file changed, 40 insertions(+), 32 deletions(-)
+
+diff --git a/gst/camerabin/gstcamerabin.c b/gst/camerabin/gstcamerabin.c
+index 8a36970..3f87ff9 100644
+--- a/gst/camerabin/gstcamerabin.c
++++ b/gst/camerabin/gstcamerabin.c
+@@ -505,22 +505,15 @@ GST_BOILERPLATE_FULL (GstCameraBin, gst_camerabin, GstPipeline,
+ */
+
+ /*
+- * camerabin_setup_src_elements:
++ * camerabin_create_view_finder_caps:
+ * @camera: camerabin object
+ *
+- * This function updates camerabin capsfilters according
+- * to fps, resolution and zoom that have been configured
+- * to camerabin.
++ * This function creates new view_finder_caps, according to
++ * fps and resolution that have been configured to camerabin.
+ */
+-static void
+-camerabin_setup_src_elements (GstCameraBin * camera)
++static GstCaps *camerabin_create_view_finder_caps (GstCameraBin * camera)
+ {
+ GstStructure *st;
+- GstCaps *new_caps;
+- gboolean detect_framerate = FALSE;
+-
+- /* clear video update status */
+- camera->video_capture_caps_update = FALSE;
+
+ if (!camera->view_finder_caps) {
+ st = gst_structure_from_string (CAMERABIN_DEFAULT_VF_CAPS, NULL);
+@@ -529,39 +522,54 @@ camerabin_setup_src_elements (GstCameraBin * camera)
+ 0));
+ }
+
+- gst_camerabin_monitor_video_source_properties (camera);
+-
+ if (camera->app_width > 0 && camera->app_height > 0) {
+ gst_structure_set (st,
+ "width", G_TYPE_INT, camera->app_width,
+ "height", G_TYPE_INT, camera->app_height, NULL);
+ }
+
+- if (camera->app_fps_n > 0 && camera->app_fps_d > 0) {
+- if (camera->night_mode) {
+- GST_INFO_OBJECT (camera, "night mode, lowest allowed fps will be
forced");
+- camera->pre_night_fps_n = camera->app_fps_n;
+- camera->pre_night_fps_d = camera->app_fps_d;
+- detect_framerate = TRUE;
+- } else {
+- gst_structure_set (st,
+- "framerate", GST_TYPE_FRACTION, camera->app_fps_n,
+- camera->app_fps_d, NULL);
+- new_caps = gst_caps_new_full (st, NULL);
+- }
++ if (!camera->night_mode && camera->app_fps_n > 0 &&
camera->app_fps_d > 0) {
++ gst_structure_set (st,
++ "framerate", GST_TYPE_FRACTION, camera->app_fps_n,
++ camera->app_fps_d, NULL);
+ } else {
+- GST_DEBUG_OBJECT (camera, "no framerate specified");
+- detect_framerate = TRUE;
+- }
+-
+- if (detect_framerate) {
+- GST_DEBUG_OBJECT (camera, "detecting allowed framerate");
+ /* Remove old framerate if any */
+ if (gst_structure_has_field (st, "framerate")) {
+ gst_structure_remove_field (st, "framerate");
+ }
+- new_caps = gst_caps_new_full (st, NULL);
++ }
++
++ /* The returned caps take ownership of the structure st */
++ return gst_caps_new_full (st, NULL);
++}
+
++/*
++ * camerabin_setup_src_elements:
++ * @camera: camerabin object
++ *
++ * This function updates camerabin capsfilters according
++ * to fps, resolution and zoom that have been configured
++ * to camerabin.
++ */
++static void
++camerabin_setup_src_elements (GstCameraBin * camera)
++{
++ GstCaps *new_caps;
++
++ /* clear video update status */
++ camera->video_capture_caps_update = FALSE;
++
++ gst_camerabin_monitor_video_source_properties (camera);
++
++ new_caps = camerabin_create_view_finder_caps (camera);
++
++ if (camera->night_mode || camera->app_fps_n <= 0 || camera->app_fps_d
<= 0) {
++ if (camera->night_mode) {
++ GST_INFO_OBJECT (camera, "night mode, lowest allowed fps will be
forced");
++ camera->pre_night_fps_n = camera->app_fps_n;
++ camera->pre_night_fps_d = camera->app_fps_d;
++ }
++ GST_DEBUG_OBJECT (camera, "detecting allowed framerate");
+ /* Set allowed framerate for the resolution */
+ gst_camerabin_set_allowed_framerate (camera, new_caps);
+ }
+--
+1.7.10.2
+
diff --git a/0002-h264parse-Ensure-codec_data-has-the-required-size-wh.patch
b/0002-h264parse-Ensure-codec_data-has-the-required-size-wh.patch
new file mode 100644
index 0000000..1028b01
--- /dev/null
+++ b/0002-h264parse-Ensure-codec_data-has-the-required-size-wh.patch
@@ -0,0 +1,28 @@
+From 3003cbe1624cc6daa416caba9c1dce0180f3837c Mon Sep 17 00:00:00 2001
+From: Wim Taymans <wtaymans(a)redhat.com>
+Date: Wed, 7 Dec 2016 09:37:10 +0100
+Subject: [PATCH 2/2] h264parse: Ensure codec_data has the required size when
+ reading number of SPS
+
+https://bugzilla.gnome.org/show_bug.cgi?id=774896
+---
+ gst/videoparsers/gsth264parse.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/gst/videoparsers/gsth264parse.c b/gst/videoparsers/gsth264parse.c
+index cf81657..4c14f2b 100644
+--- a/gst/videoparsers/gsth264parse.c
++++ b/gst/videoparsers/gsth264parse.c
+@@ -1605,6 +1605,9 @@ gst_h264_parse_set_caps (GstBaseParse * parse, GstCaps * caps)
+ off = nalu.offset + nalu.size;
+ }
+
++ if (off >= size) {
++ goto avcc_too_small;
++ }
+ num_pps = data[off];
+ off++;
+
+--
+2.9.3
+
diff --git a/0003-camerabin-Add-gst_camerabin_get_video_source_propert.patch
b/0003-camerabin-Add-gst_camerabin_get_video_source_propert.patch
new file mode 100644
index 0000000..3950bb7
--- /dev/null
+++ b/0003-camerabin-Add-gst_camerabin_get_video_source_propert.patch
@@ -0,0 +1,97 @@
+From 1ef6977002ef18631f81646f198ef6a667ef8f73 Mon Sep 17 00:00:00 2001
+From: Hans de Goede <hdegoede(a)redhat.com>
+Date: Fri, 8 Jun 2012 11:41:17 +0200
+Subject: [PATCH 3/4] camerabin: Add
+ gst_camerabin_get_video_source_properties() helper
+ function
+
+Signed-off-by: Hans de Goede <hdegoede(a)redhat.com>
+---
+ gst/camerabin/gstcamerabin.c | 31 +++++++++++++++++++++++++------
+ 1 file changed, 25 insertions(+), 6 deletions(-)
+
+diff --git a/gst/camerabin/gstcamerabin.c b/gst/camerabin/gstcamerabin.c
+index 3f87ff9..a36d5b5 100644
+--- a/gst/camerabin/gstcamerabin.c
++++ b/gst/camerabin/gstcamerabin.c
+@@ -347,6 +347,7 @@ static void gst_camerabin_scene_mode_notify_cb (GObject *
video_source,
+ GParamSpec * pspec, gpointer user_data);
+ static void gst_camerabin_zoom_notify_cb (GObject * video_source,
+ GParamSpec * pspec, gpointer user_data);
++static void gst_camerabin_get_video_source_properties (GstCameraBin * camera);
+ static void gst_camerabin_monitor_video_source_properties (GstCameraBin *
+ camera);
+ static void gst_camerabin_configure_format (GstCameraBin * camera,
+@@ -528,6 +529,8 @@ static GstCaps *camerabin_create_view_finder_caps (GstCameraBin *
camera)
+ "height", G_TYPE_INT, camera->app_height, NULL);
+ }
+
++ gst_camerabin_get_video_source_properties (camera);
++
+ if (!camera->night_mode && camera->app_fps_n > 0 &&
camera->app_fps_d > 0) {
+ gst_structure_set (st,
+ "framerate", GST_TYPE_FRACTION, camera->app_fps_n,
+@@ -559,8 +562,6 @@ camerabin_setup_src_elements (GstCameraBin * camera)
+ /* clear video update status */
+ camera->video_capture_caps_update = FALSE;
+
+- gst_camerabin_monitor_video_source_properties (camera);
+-
+ new_caps = camerabin_create_view_finder_caps (camera);
+
+ if (camera->night_mode || camera->app_fps_n <= 0 || camera->app_fps_d
<= 0) {
+@@ -574,6 +575,8 @@ camerabin_setup_src_elements (GstCameraBin * camera)
+ gst_camerabin_set_allowed_framerate (camera, new_caps);
+ }
+
++ gst_camerabin_monitor_video_source_properties (camera);
++
+ /* Set default zoom method */
+ if (camera->src_zoom_scale) {
+ g_object_set (camera->src_zoom_scale, "method",
+@@ -2660,6 +2663,26 @@ gst_camerabin_zoom_notify_cb (GObject * video_source, GParamSpec *
pspec,
+ }
+
+ /*
++ * gst_camerabin_monitor_get_video_source_properties:
++ * @camera: camerabin object
++ *
++ * Get properties from video source photography interface property scene mode.
++ *
++ */
++static void
++gst_camerabin_get_video_source_properties (GstCameraBin * camera)
++{
++ if (GST_IS_ELEMENT (camera->src_vid_src) &&
++ gst_element_implements_interface (camera->src_vid_src,
++ GST_TYPE_PHOTOGRAPHY)) {
++ gint scene_mode;
++ g_object_get (G_OBJECT (camera->src_vid_src), "scene-mode",
&scene_mode,
++ NULL);
++ camera->night_mode = scene_mode == GST_PHOTOGRAPHY_SCENE_MODE_NIGHT;
++ }
++}
++
++/*
+ * gst_camerabin_monitor_video_source_properties:
+ * @camera: camerabin object
+ *
+@@ -2674,15 +2697,11 @@ gst_camerabin_monitor_video_source_properties (GstCameraBin *
camera)
+ if (GST_IS_ELEMENT (camera->src_vid_src) &&
+ gst_element_implements_interface (camera->src_vid_src,
+ GST_TYPE_PHOTOGRAPHY)) {
+- gint scene_mode;
+ GST_DEBUG_OBJECT (camera,
+ "connecting to %" GST_PTR_FORMAT " - notify::scene-mode",
+ camera->src_vid_src);
+ g_signal_connect (G_OBJECT (camera->src_vid_src),
"notify::scene-mode",
+ (GCallback) gst_camerabin_scene_mode_notify_cb, camera);
+- g_object_get (G_OBJECT (camera->src_vid_src), "scene-mode",
&scene_mode,
+- NULL);
+- camera->night_mode = scene_mode == GST_PHOTOGRAPHY_SCENE_MODE_NIGHT;
+
+ GST_DEBUG_OBJECT (camera,
+ "connecting to %" GST_PTR_FORMAT " - notify::zoom",
+--
+1.7.10.2
+
diff --git a/0004-camerabin-Set-src_filter-and-zoom_src_filter-caps-wh.patch
b/0004-camerabin-Set-src_filter-and-zoom_src_filter-caps-wh.patch
new file mode 100644
index 0000000..ade66be
--- /dev/null
+++ b/0004-camerabin-Set-src_filter-and-zoom_src_filter-caps-wh.patch
@@ -0,0 +1,74 @@
+From 9ea00bf5e7043cab7da93abcb345b2f5c65285de Mon Sep 17 00:00:00 2001
+From: Hans de Goede <hdegoede(a)redhat.com>
+Date: Fri, 8 Jun 2012 13:39:37 +0200
+Subject: [PATCH 4/4] camerabin: Set src_filter and zoom_src_filter caps while
+ creating the pipeline
+
+We (Fedora) have been receiving bug reports for cheese, about cheese
+taking 30-60 seconds before showing video, and pausing the same amount of
+time when changing the resolution for example.
+
+I've managed to reproduce this with a Logitech Webcam Pro 9000, which
+supports a large list of resolutions at about 5 different framerates /
+resolution, in my case with an unmodified gst-plugins-bad-0.10.23, the
+camerabin_create_src_elements function takes approx 7 seconds.
+
+Running under gdb and interrupting the execution during these 7 seconds
+consistenly points to gst_caps_intersect_full.
+
+Part of the problem is cheese setting the
+GST_CAMERABIN_FLAG_SOURCE_COLOR_CONVERSION flag, which means that after
+the first ffmpegcsp element in the pipe the total number of caps is
+x resolutions * y framerates * z formats, where both x (due to the camera)
+and z (due to ffmpegcsp) being large. intersecting this with the capabilities
+of other parts of the pipeline simply leads to an explosion of combinations
+which pegs my core i5 CPU @3.1GHz for 7 seconds!
+
+This patch fixes this issue by setting up the capsfilter elements in the pipe
+with an initial filter, greatly reducing the number of combinations when doing
+cap intersecting.
+
+This reduces the time spend in camerabin_create_src_elements from approx 7
+to 0.2 seconds. And when patching cheese to use the default camerabin flags,
+(so removing the first ffmpegcsp element) from approx 0.7 to 0.04 seconds
+
+Signed-off-by: Hans de Goede <hdegoede(a)redhat.com>
+---
+ gst/camerabin/gstcamerabin.c | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git a/gst/camerabin/gstcamerabin.c b/gst/camerabin/gstcamerabin.c
+index a36d5b5..6d7d30f 100644
+--- a/gst/camerabin/gstcamerabin.c
++++ b/gst/camerabin/gstcamerabin.c
+@@ -606,6 +606,7 @@ camerabin_create_src_elements (GstCameraBin * camera)
+ gboolean ret = FALSE;
+ GstBin *cbin = GST_BIN (camera);
+ gchar *driver_name = NULL;
++ GstCaps *filter_caps;
+
+ /* Add application set or default video src element */
+ if (!(camera->src_vid_src = gst_camerabin_setup_default_element (cbin,
+@@ -625,6 +626,10 @@ camerabin_create_src_elements (GstCameraBin * camera)
+ gst_camerabin_create_and_add_element (cbin, "capsfilter",
+ "src-capsfilter")))
+ goto done;
++
++ filter_caps = camerabin_create_view_finder_caps (camera);
++ g_object_set (G_OBJECT (camera->src_filter), "caps", filter_caps, NULL);
++
+ if (camera->flags & GST_CAMERABIN_FLAG_SOURCE_RESIZE) {
+ if (!(camera->src_zoom_crop =
+ gst_camerabin_create_and_add_element (cbin, "videocrop",
+@@ -638,6 +643,8 @@ camerabin_create_src_elements (GstCameraBin * camera)
+ gst_camerabin_create_and_add_element (cbin, "capsfilter",
+ "src-resize-capsfilter")))
+ goto done;
++ g_object_set (G_OBJECT (camera->src_zoom_filter), "caps", filter_caps,
++ NULL);
+ }
+ if (camera->app_video_filter) {
+ if (!gst_camerabin_add_element (cbin, camera->app_video_filter)) {
+--
+1.7.10.2
+
diff --git a/0005-geometrictransform-crash-fix1.patch
b/0005-geometrictransform-crash-fix1.patch
new file mode 100644
index 0000000..ba71862
--- /dev/null
+++ b/0005-geometrictransform-crash-fix1.patch
@@ -0,0 +1,37 @@
+From 4e7edb2778f85a5475ffe9c782c91d86a7b902ca Mon Sep 17 00:00:00 2001
+From: Oleksij Rempel (Alexey Fisher) <bug-track(a)fisher-privat.net>
+Date: Mon, 12 Mar 2012 14:42:04 +0000
+Subject: geometrictransform: make sure gt->map not freed twice
+
+current cheese can create situation where gt->map is freed twice.
+This patch set map to null to avoid it.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=671910
+
+diff --git a/gst/geometrictransform/gstgeometrictransform.c
b/gst/geometrictransform/gstgeometrictransform.c
+index 8e78de7..274d483 100644
+--- a/gst/geometrictransform/gstgeometrictransform.c
++++ b/gst/geometrictransform/gstgeometrictransform.c
+@@ -143,9 +143,10 @@ gst_geometric_transform_generate_map (GstGeometricTransform * gt)
+ }
+
+ end:
+- if (!ret)
++ if (!ret) {
+ g_free (gt->map);
+- else
++ gt->map = NULL;
++ } else
+ gt->needs_remap = FALSE;
+ return ret;
+ }
+@@ -348,6 +349,7 @@ gst_geometric_transform_stop (GstBaseTransform * trans)
+ GstGeometricTransform *gt = GST_GEOMETRIC_TRANSFORM_CAST (trans);
+
+ g_free (gt->map);
++ gt->map = NULL;
+
+ return TRUE;
+ }
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/0006-geometrictransform-crash-fix2.patch
b/0006-geometrictransform-crash-fix2.patch
new file mode 100644
index 0000000..d9552b4
--- /dev/null
+++ b/0006-geometrictransform-crash-fix2.patch
@@ -0,0 +1,36 @@
+From 7dd5b2002abf516ebdf92696c57a9a7692c166e9 Mon Sep 17 00:00:00 2001
+From: Thiago Santos <thiago.sousa.santos(a)collabora.com>
+Date: Tue, 20 Mar 2012 23:07:11 +0000
+Subject: geometrictransform: Prevent access to the transform map when it is null
+
+Check if the map doesn't exist when receiving a new caps and create
+a new one. This prevents that the transform functions try to access
+the map when it doesn't exist.
+
+diff --git a/gst/geometrictransform/gstgeometrictransform.c
b/gst/geometrictransform/gstgeometrictransform.c
+index be651a4..a1ec3ab 100644
+--- a/gst/geometrictransform/gstgeometrictransform.c
++++ b/gst/geometrictransform/gstgeometrictransform.c
+@@ -178,8 +178,8 @@ gst_geometric_transform_set_caps (GstBaseTransform * btrans, GstCaps
* incaps,
+
+ /* regenerate the map */
+ GST_OBJECT_LOCK (gt);
+- if (old_width == 0 || old_height == 0 || gt->width != old_width ||
+- gt->height != old_height) {
++ if (gt->map == NULL || old_width == 0 || old_height == 0
++ || gt->width != old_width || gt->height != old_height) {
+ if (klass->prepare_func)
+ if (!klass->prepare_func (gt)) {
+ GST_OBJECT_UNLOCK (gt);
+@@ -352,6 +352,9 @@ gst_geometric_transform_stop (GstBaseTransform * trans)
+ {
+ GstGeometricTransform *gt = GST_GEOMETRIC_TRANSFORM_CAST (trans);
+
++ gt->width = 0;
++ gt->height = 0;
++
+ g_free (gt->map);
+ gt->map = NULL;
+
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/gst-plugins-bad-0.10.23-drop-vpx-compat-defines.patch
b/gst-plugins-bad-0.10.23-drop-vpx-compat-defines.patch
new file mode 100644
index 0000000..599ec08
--- /dev/null
+++ b/gst-plugins-bad-0.10.23-drop-vpx-compat-defines.patch
@@ -0,0 +1,27 @@
+diff -up gst-plugins-bad-0.10.23/ext/vp8/gstvp8utils.h.drop-compat-defines
gst-plugins-bad-0.10.23/ext/vp8/gstvp8utils.h
+--- gst-plugins-bad-0.10.23/ext/vp8/gstvp8utils.h.drop-compat-defines 2015-04-07
09:28:01.637679239 -0400
++++ gst-plugins-bad-0.10.23/ext/vp8/gstvp8utils.h 2015-04-07 09:28:10.397622550 -0400
+@@ -25,23 +25,6 @@
+
+ G_BEGIN_DECLS
+
+-/* Some compatibility defines for older libvpx versions */
+-#ifndef VPX_IMG_FMT_I420
+-#define VPX_IMG_FMT_I420 IMG_FMT_I420
+-#endif
+-
+-#ifndef VPX_PLANE_Y
+-#define VPX_PLANE_Y PLANE_Y
+-#endif
+-
+-#ifndef VPX_PLANE_U
+-#define VPX_PLANE_U PLANE_U
+-#endif
+-
+-#ifndef VPX_PLANE_V
+-#define VPX_PLANE_V PLANE_V
+-#endif
+-
+ const char * gst_vpx_error_name (vpx_codec_err_t status);
+
+ G_END_DECLS
diff --git a/gst-plugins-bad-0.10.23-timidity2.diff
b/gst-plugins-bad-0.10.23-timidity2.diff
new file mode 100644
index 0000000..c91e3e3
--- /dev/null
+++ b/gst-plugins-bad-0.10.23-timidity2.diff
@@ -0,0 +1,12 @@
+diff -uNr gst-plugins-bad-0.10.23/ext/timidity/gsttimidity.c
gst-plugins-bad-0.10.23.timidity/ext/timidity/gsttimidity.c
+--- gst-plugins-bad-0.10.23/ext/timidity/gsttimidity.c 2011-12-30 19:24:28.000000000
+0100
++++ gst-plugins-bad-0.10.23.timidity/ext/timidity/gsttimidity.c 2016-10-06
10:37:54.076801395 +0200
+@@ -615,7 +615,7 @@
+ GST_DEBUG_OBJECT (timidity, "Parsing song");
+
+ stream =
+- mid_istream_open_mem (timidity->mididata, timidity->mididata_size, 0);
++ mid_istream_open_mem (timidity->mididata, timidity->mididata_size);
+
+ timidity->song = mid_song_load (stream, timidity->song_options);
+ mid_istream_close (stream);
diff --git a/gstreamer-plugins-bad.spec b/gstreamer-plugins-bad.spec
index e508bb9..c1050b8 100644
--- a/gstreamer-plugins-bad.spec
+++ b/gstreamer-plugins-bad.spec
@@ -1,36 +1,64 @@
%define majorminor 0.10
%define gstreamer gstreamer
-%define gst_minver 0.10.33
-%define gstpb_minver 0.10.33
-
-# which plugins to actually build and install
-%ifarch %{ix86} x86_64
-%define gstdirs gst/dvdspu gst/real gst/siren
-%else
-%define gstdirs gst/dvdspu gst/siren
-%endif
-%define extdirs ext/dts ext/faad ext/libmms ext/mimic ext/mpeg2enc ext/mplex ext/rtmp
ext/voamrwbenc ext/xvid
+%define gst_minver 0.10.36
+%define gstpb_minver %{gst_minver}
Summary: GStreamer streaming media framework "bad" plug-ins
Name: gstreamer-plugins-bad
Version: 0.10.23
-Release: 13%{?dist}
-License: LGPLv2+
-Group: Applications/Multimedia
+Release: 14%{?dist}
+# The freeze and nfs plugins are LGPLv2 (only)
+License: LGPLv2+ and LGPLv2
URL:
https://gstreamer.freedesktop.org/
Source:
https://gstreamer.freedesktop.org/src/gst-plugins-bad/gst-plugins-bad-%{v...
-Patch1: 0001-fix-faad2-version-check.patch
+# Based on upstream 04909e2c50e68
+Patch0: vp8enc-bitrate-fix.patch
+#
https://bugzilla.gnome.org/show_bug.cgi?id=677698 / rhbz#797188
+Patch1: 0001-gstcamerabin-Fix-spelling-error-in-debug-logging.patch
+Patch2: 0002-camerabin-Add-a-camerabin_create_view_finder_caps-he.patch
+Patch3: 0003-camerabin-Add-gst_camerabin_get_video_source_propert.patch
+Patch4: 0004-camerabin-Set-src_filter-and-zoom_src_filter-caps-wh.patch
+# Cherry picked from upstream git for rhbz#820959
+Patch5: 0005-geometrictransform-crash-fix1.patch
+Patch6: 0006-geometrictransform-crash-fix2.patch
+Patch8: 0001-modplug-Specify-directory-when-including-stdafx.h.patch
+# No longer needed, actually break build if we have them now.
+Patch9: gst-plugins-bad-0.10.23-drop-vpx-compat-defines.patch
+# Fix for libtimidity-0.2.x
+Patch11: gst-plugins-bad-0.10.23-timidity2.diff
+Patch12: 0001-vmncdec-Sanity-check-width-height-before-using-it.patch
+Patch13: 0002-h264parse-Ensure-codec_data-has-the-required-size-wh.patch
+Patch14: 0001-fix-faad2-version-check.patch
+
Requires: %{gstreamer} >= %{gst_minver}
-# Drag in the free plugins which are in Fedora now, for upgrade path
-Requires: gstreamer-plugins-bad-free >= %{version}
BuildRequires: %{gstreamer}-devel >= %{gst_minver}
BuildRequires: %{gstreamer}-plugins-base-devel >= %{gstpb_minver}
BuildRequires: gcc-c++
BuildRequires: check
BuildRequires: gettext-devel
BuildRequires: libXt-devel
-BuildRequireS: gtk-doc
+BuildRequires: bzip2-devel
+BuildRequires: exempi-devel
+BuildRequires: gsm-devel
+BuildRequires: jasper-devel
+BuildRequires: ladspa-devel
+BuildRequires: libdvdnav-devel
+BuildRequires: libexif-devel
+BuildRequires: libiptcdata-devel
+BuildRequires: libmpcdec-devel
+BuildRequires: libofa-devel
+BuildRequires: liboil-devel
+BuildRequires: librsvg2-devel
+BuildRequires: libsndfile-devel
+BuildRequires: libvpx-devel
+BuildRequires: mesa-libGLU-devel
+BuildRequires: orc-devel
+Buildrequires: wavpack-devel
+BuildRequires: chrpath
+
+BuildRequires: opus-devel
+BuildRequires: soundtouch-devel
BuildRequires: liboil-devel
BuildRequires: libdca-devel
BuildRequires: faad2-devel
@@ -41,77 +69,238 @@ BuildRequires: twolame-devel
BuildRequires: libmimic-devel
BuildRequires: librtmp-devel
BuildRequires: vo-amrwbenc-devel
-# For autoreconf
-BuildRequires: libtool
+BuildRequires: libass-devel
+BuildRequires: libcdaudio-devel
+BuildRequires: libcurl-devel
+BuildRequires: libdc1394-devel
+BuildRequires: libkate-devel
+BuildRequires: libmodplug-devel
+BuildRequires: libtimidity-devel
+BuildRequires: libvdpau-devel
+BuildRequires: opencv-devel
+BuildRequires: schroedinger-devel
+BuildRequires: SDL-devel
+BuildRequires: slv2-devel
+BuildRequires: wildmidi-devel
+BuildRequires: zbar-devel
+BuildRequires: zvbi-devel
%description
GStreamer is a streaming media framework, based on graphs of elements which
operate on media data.
-This package contains plug-ins that have licensing issues, aren't tested
+This package contains plug-ins that aren't tested
well enough, or the code is not of good enough quality.
+%package devel
+Summary: Development files for the GStreamer media framework "bad" plug-ins
+Requires: %{name} = %{version}-%{release}
+Requires: gstreamer-plugins-base-devel
+
+%description devel
+GStreamer is a streaming media framework, based on graphs of elements which
+operate on media data.
+
+This package contains the development files for the plug-ins that
+aren't tested well enough, or the code is not of good enough quality.
+
+
%prep
-%setup -q -n gst-plugins-bad-%{version}
-%patch1 -p1
-# For patch1
-autoreconf -ivf
+%autosetup -n gst-plugins-bad-%{version} -p1
%build
-# Note we don't bother with disabling everything which is in Fedora, that
-# is unmaintainable, instead we selectively run make in subdirs
%configure \
--with-package-name="gst-plugins-bad rpmfusion rpm" \
--with-package-origin="http://rpmfusion.org/" \
- --enable-debug --disable-static --enable-experimental
+ --enable-debug --disable-static --disable-gtk-doc --enable-experimental \
+ --disable-nsf --disable-apexsink \
+
# Don't use rpath!
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g'
libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
-for i in %{gstdirs} %{extdirs}; do
- pushd $i
- make %{?_smp_mflags} V=2
- popd
-done
+%make_build
%install
-for i in %{gstdirs} %{extdirs}; do
- pushd $i
- make install V=2 DESTDIR=$RPM_BUILD_ROOT
- popd
-done
+%make_install
+%find_lang gst-plugins-bad-%{majorminor}
+
+# Some of the plugins somehow get an rpath embedded ??
+chrpath --delete %{buildroot}%{_libdir}/gstreamer-%{majorminor}/*.so
# Clean out files that should not be part of the rpm.
rm %{buildroot}%{_libdir}/gstreamer-%{majorminor}/*.la
+rm %{buildroot}%{_libdir}/*.la
+rm -r %{buildroot}%{_datadir}/gtk-doc
-%files
+%files -f gst-plugins-bad-%{majorminor}.lang
%doc AUTHORS COPYING README REQUIREMENTS
# Take the whole dir for proper dir ownership (shared with other plugin pkgs)
%{_datadir}/gstreamer-0.10
+%{_libdir}/libgstbasecamerabinsrc-%{majorminor}.so.*
+%{_libdir}/libgstbasevideo-%{majorminor}.so.*
+%{_libdir}/libgstcodecparsers-%{majorminor}.so.*
+%{_libdir}/libgstphotography-%{majorminor}.so.*
+%{_libdir}/libgstsignalprocessor-%{majorminor}.so.*
+%{_libdir}/libgstvdp-%{majorminor}.so.*
# Plugins without external dependencies
+%{_libdir}/gstreamer-%{majorminor}/libgstadpcmdec.so
+%{_libdir}/gstreamer-%{majorminor}/libgstadpcmenc.so
+%{_libdir}/gstreamer-%{majorminor}/libgstaiff.so
+%{_libdir}/gstreamer-%{majorminor}/libgstasfmux.so
+%{_libdir}/gstreamer-%{majorminor}/libgstaudiovisualizers.so
+%{_libdir}/gstreamer-%{majorminor}/libgstautoconvert.so
+%{_libdir}/gstreamer-%{majorminor}/libgstbayer.so
+%{_libdir}/gstreamer-%{majorminor}/libgstcamerabin.so
+%{_libdir}/gstreamer-%{majorminor}/libgstcamerabin2.so
+%{_libdir}/gstreamer-%{majorminor}/libgstcdxaparse.so
+%{_libdir}/gstreamer-%{majorminor}/libgstcog.so
+%{_libdir}/gstreamer-%{majorminor}/libgstcoloreffects.so
+%{_libdir}/gstreamer-%{majorminor}/libgstcolorspace.so
+%{_libdir}/gstreamer-%{majorminor}/libgstdataurisrc.so
+%{_libdir}/gstreamer-%{majorminor}/libgstdccp.so
+%{_libdir}/gstreamer-%{majorminor}/libgstdtmf.so
%{_libdir}/gstreamer-%{majorminor}/libgstdvdspu.so
+%{_libdir}/gstreamer-%{majorminor}/libgstfaceoverlay.so
+%{_libdir}/gstreamer-%{majorminor}/libgstfestival.so
+%{_libdir}/gstreamer-%{majorminor}/libgstfieldanalysis.so
+%{_libdir}/gstreamer-%{majorminor}/libgstfragmented.so
+%{_libdir}/gstreamer-%{majorminor}/libgstfreeverb.so
+%{_libdir}/gstreamer-%{majorminor}/libgstfreeze.so
+%{_libdir}/gstreamer-%{majorminor}/libgstfrei0r.so
+%{_libdir}/gstreamer-%{majorminor}/libgstgaudieffects.so
+%{_libdir}/gstreamer-%{majorminor}/libgstgeometrictransform.so
+%{_libdir}/gstreamer-%{majorminor}/libgstgsettingselements.so
+%{_libdir}/gstreamer-%{majorminor}/libgsth264parse.so
+%{_libdir}/gstreamer-%{majorminor}/libgsthdvparse.so
+%{_libdir}/gstreamer-%{majorminor}/libgstid3tag.so
+%{_libdir}/gstreamer-%{majorminor}/libgstinter.so
+%{_libdir}/gstreamer-%{majorminor}/libgstinterlace.so
+%{_libdir}/gstreamer-%{majorminor}/libgstivfparse.so
+%{_libdir}/gstreamer-%{majorminor}/libgstjpegformat.so
+%{_libdir}/gstreamer-%{majorminor}/libgstjp2kdecimator.so
+%{_libdir}/gstreamer-%{majorminor}/libgstlegacyresample.so
+%{_libdir}/gstreamer-%{majorminor}/libgstliveadder.so
+%{_libdir}/gstreamer-%{majorminor}/libgstmpegdemux.so
+%{_libdir}/gstreamer-%{majorminor}/libgstmpegpsmux.so
+%{_libdir}/gstreamer-%{majorminor}/libgstmpegtsdemux.so
+%{_libdir}/gstreamer-%{majorminor}/libgstmpegtsmux.so
+%{_libdir}/gstreamer-%{majorminor}/libgstmpegvideoparse.so
+%{_libdir}/gstreamer-%{majorminor}/libgstmve.so
+%{_libdir}/gstreamer-%{majorminor}/libgstmxf.so
+%{_libdir}/gstreamer-%{majorminor}/libgstnuvdemux.so
+%{_libdir}/gstreamer-%{majorminor}/libgstpatchdetect.so
+%{_libdir}/gstreamer-%{majorminor}/libgstpcapparse.so
+%{_libdir}/gstreamer-%{majorminor}/libgstpnm.so
+%{_libdir}/gstreamer-%{majorminor}/libgstrawparse.so
%ifarch %{ix86} x86_64
%{_libdir}/gstreamer-%{majorminor}/libgstreal.so
%endif
+%{_libdir}/gstreamer-%{majorminor}/libgstremovesilence.so
+%{_libdir}/gstreamer-%{majorminor}/libgstrfbsrc.so
+%{_libdir}/gstreamer-%{majorminor}/libgstrtpmux.so
+%{_libdir}/gstreamer-%{majorminor}/libgstrtpvp8.so
+%{_libdir}/gstreamer-%{majorminor}/libgstscaletempoplugin.so
+%{_libdir}/gstreamer-%{majorminor}/libgstsdi.so
+%{_libdir}/gstreamer-%{majorminor}/libgstsdpelem.so
+%{_libdir}/gstreamer-%{majorminor}/libgstsegmentclip.so
+%{_libdir}/gstreamer-%{majorminor}/libgstshm.so
%{_libdir}/gstreamer-%{majorminor}/libgstsiren.so
+%{_libdir}/gstreamer-%{majorminor}/libgstsmooth.so
+%{_libdir}/gstreamer-%{majorminor}/libgstspeed.so
+%{_libdir}/gstreamer-%{majorminor}/libgststereo.so
+%{_libdir}/gstreamer-%{majorminor}/libgstsubenc.so
+%{_libdir}/gstreamer-%{majorminor}/libgsttta.so
+%{_libdir}/gstreamer-%{majorminor}/libgstvideofiltersbad.so
+%{_libdir}/gstreamer-%{majorminor}/libgstvideosignal.so
+%{_libdir}/gstreamer-%{majorminor}/libgstvideomaxrate.so
+%{_libdir}/gstreamer-%{majorminor}/libgstvideomeasure.so
+%{_libdir}/gstreamer-%{majorminor}/libgstvideoparsersbad.so
+%{_libdir}/gstreamer-%{majorminor}/libgstvmnc.so
+%{_libdir}/gstreamer-%{majorminor}/libgsty4mdec.so
+
+# System (Linux) specific plugins
+%{_libdir}/gstreamer-%{majorminor}/libgstdvb.so
+%{_libdir}/gstreamer-%{majorminor}/libgstdvbsuboverlay.so
+%{_libdir}/gstreamer-%{majorminor}/libgstvcdsrc.so
# Plugins with external dependencies
+%{_libdir}/gstreamer-%{majorminor}/libgstbz2.so
%{_libdir}/gstreamer-%{majorminor}/libgstdtsdec.so
%{_libdir}/gstreamer-%{majorminor}/libgstfaad.so
+%{_libdir}/gstreamer-%{majorminor}/libgstgsm.so
+%{_libdir}/gstreamer-%{majorminor}/libgstjp2k.so
+%{_libdir}/gstreamer-%{majorminor}/libgstladspa.so
%{_libdir}/gstreamer-%{majorminor}/libgstmms.so
%{_libdir}/gstreamer-%{majorminor}/libgstmimic.so
%{_libdir}/gstreamer-%{majorminor}/libgstmpeg2enc.so
%{_libdir}/gstreamer-%{majorminor}/libgstmplex.so
+%{_libdir}/gstreamer-%{majorminor}/libgstmusepack.so
+%{_libdir}/gstreamer-%{majorminor}/libgstofa.so
+%{_libdir}/gstreamer-%{majorminor}/libgstopus.so
+%{_libdir}/gstreamer-%{majorminor}/libgstrsvg.so
%{_libdir}/gstreamer-%{majorminor}/libgstrtmp.so
+%{_libdir}/gstreamer-%{majorminor}/libgstsndfile.so
+%{_libdir}/gstreamer-%{majorminor}/libgstsoundtouch.so
%{_libdir}/gstreamer-%{majorminor}/libgstvoamrwbenc.so
+%{_libdir}/gstreamer-%{majorminor}/libgstvp8.so
%{_libdir}/gstreamer-%{majorminor}/libgstxvid.so
+%{_libdir}/gstreamer-%{majorminor}/libresindvd.so
+
+#debugging plugin
+%{_libdir}/gstreamer-%{majorminor}/libgstdebugutilsbad.so
+
+#data for plugins
+%{_datadir}/glib-2.0/schemas/org.freedesktop.gstreamer-%{majorminor}.default-elements.gschema.xml
+
+# Plugins with external dependencies
+%{_libdir}/gstreamer-%{majorminor}/libgstassrender.so
+%{_libdir}/gstreamer-%{majorminor}/libgstcdaudio.so
+%{_libdir}/gstreamer-%{majorminor}/libgstcurl.so
+%{_libdir}/gstreamer-%{majorminor}/libgstdc1394.so
+%{_libdir}/gstreamer-%{majorminor}/libgstkate.so
+%{_libdir}/gstreamer-%{majorminor}/libgstlv2.so
+%{_libdir}/gstreamer-%{majorminor}/libgstmodplug.so
+%{_libdir}/gstreamer-%{majorminor}/libgstschro.so
+%{_libdir}/gstreamer-%{majorminor}/libgstsdl.so
+%{_libdir}/gstreamer-%{majorminor}/libgstteletextdec.so
+%{_libdir}/gstreamer-%{majorminor}/libgsttimidity.so
+%{_libdir}/gstreamer-%{majorminor}/libgstvdpau.so
+%{_libdir}/gstreamer-%{majorminor}/libgstwildmidi.so
+%{_libdir}/gstreamer-%{majorminor}/libgstzbar.so
+# Linux specific plugins
+%{_libdir}/gstreamer-%{majorminor}/libgstdecklink.so
+%{_libdir}/gstreamer-%{majorminor}/libgstfbdevsink.so
+%{_libdir}/gstreamer-%{majorminor}/libgstlinsys.so
+
+%files devel
+%{_libdir}/libgstbasecamerabinsrc-%{majorminor}.so
+%{_libdir}/libgstbasevideo-%{majorminor}.so
+%{_libdir}/libgstcodecparsers-%{majorminor}.so
+%{_libdir}/libgstphotography-%{majorminor}.so
+%{_libdir}/libgstsignalprocessor-%{majorminor}.so
+%{_libdir}/libgstvdp-%{majorminor}.so
+%{_includedir}/gstreamer-%{majorminor}/gst/basecamerabinsrc
+%{_includedir}/gstreamer-%{majorminor}/gst/codecparsers
+%{_includedir}/gstreamer-%{majorminor}/gst/interfaces/photography*
+%{_includedir}/gstreamer-%{majorminor}/gst/signalprocessor
+%{_includedir}/gstreamer-%{majorminor}/gst/video
+%{_includedir}/gstreamer-%{majorminor}/gst/vdpau
+
+# pkg-config files
+%{_libdir}/pkgconfig/gstreamer-basevideo-%{majorminor}.pc
+%{_libdir}/pkgconfig/gstreamer-codecparsers-%{majorminor}.pc
+%{_libdir}/pkgconfig/gstreamer-plugins-bad-%{majorminor}.pc
%changelog
+* Fri Sep 04 2020 Dominik Mierzejewski <rpm(a)greysector.net> - 0.10.23-14
+- merge with -free from Fedora
+
* Fri Aug 09 2019 RPM Fusion Release Engineering <leigh123linux(a)gmail.com> -
0.10.23-13
- Rebuilt for
https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
diff --git a/vp8enc-bitrate-fix.patch b/vp8enc-bitrate-fix.patch
new file mode 100644
index 0000000..671424e
--- /dev/null
+++ b/vp8enc-bitrate-fix.patch
@@ -0,0 +1,23 @@
+diff -ru gst-plugins-bad-0.10.23.orign/ext/vp8/gstvp8enc.c
gst-plugins-bad-0.10.23/ext/vp8/gstvp8enc.c
+--- gst-plugins-bad-0.10.23.orign/ext/vp8/gstvp8enc.c 2012-01-25 18:10:21.000000000
+0100
++++ gst-plugins-bad-0.10.23/ext/vp8/gstvp8enc.c 2012-05-28 14:21:16.552995768 +0200
+@@ -732,6 +732,11 @@
+ return FALSE;
+ }
+
++ /* Scale default bitrate to our size */
++ cfg.rc_target_bitrate = gst_util_uint64_scale (cfg.rc_target_bitrate,
++ state->width * state->height,
++ cfg.g_w * cfg.g_h);
++
+ cfg.g_w = state->width;
+ cfg.g_h = state->height;
+ cfg.g_timebase.num = state->fps_d;
+@@ -755,7 +760,6 @@
+ } else {
+ cfg.rc_min_quantizer = (gint) (63 - encoder->quality * 6.2);
+ cfg.rc_max_quantizer = (gint) (63 - encoder->quality * 6.2);
+- cfg.rc_target_bitrate = encoder->bitrate;
+ }
+ cfg.rc_dropframe_thresh = encoder->drop_frame;
+ cfg.rc_resize_allowed = encoder->resize_allowed;