From f331412a373093a7c6c7bd99c3fe87eea9d6a4b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim-Philipp=20M=C3=BCller?= Date: Fri, 26 Feb 2016 00:20:10 +0000 Subject: opus: move Opus audio decoder and encoder from -bad to -base Hook into build system after moving history. https://bugzilla.gnome.org/show_bug.cgi?id=756282 --- configure.ac | 15 +++++++++++++++ ext/Makefile.am | 8 ++++++++ ext/opus/Makefile.am | 10 +++++----- ext/opus/gstopus.c | 16 ---------------- tests/check/Makefile.am | 7 +++++++ tests/check/elements/.gitignore | 2 ++ 6 files changed, 37 insertions(+), 21 deletions(-) diff --git a/configure.ac b/configure.ac index 7da88e04f..11c46b5c7 100644 --- a/configure.ac +++ b/configure.ac @@ -687,6 +687,19 @@ AG_GST_CHECK_FEATURE(OGG, [Xiph Ogg library], ogg, [ AG_GST_PKG_CHECK_MODULES(OGG, ogg >= 1.0) ]) +dnl *** Opus *** +translit(dnm, m, l) AM_CONDITIONAL(USE_OPUS, true) +AG_GST_CHECK_FEATURE(OPUS, [opus], opus, [ + PKG_CHECK_MODULES(OPUS, opus >= 0.9.4, [ + AC_DEFINE([HAVE_OPUS], 1, [Define if Opus >= 0.9.4 is installed]) + HAVE_OPUS="yes" + ], [ + HAVE_OPUS="no" + ]) + AC_SUBST(OPUS_CFLAGS) + AC_SUBST(OPUS_LIBS) +]) + dnl *** pango *** translit(dnm, m, l) AM_CONDITIONAL(USE_PANGO, true) AG_GST_CHECK_FEATURE(PANGO, [Pango font rendering], pango, [ @@ -731,6 +744,7 @@ AM_CONDITIONAL(USE_CDPARANOIA, false) AM_CONDITIONAL(USE_IVORBIS, false) AM_CONDITIONAL(USE_LIBVISUAL, false) AM_CONDITIONAL(USE_OGG, false) +AM_CONDITIONAL(USE_OPUS, false) AM_CONDITIONAL(USE_PANGO, false) AM_CONDITIONAL(USE_THEORA, false) AM_CONDITIONAL(USE_VORBIS, false) @@ -849,6 +863,7 @@ ext/alsa/Makefile ext/cdparanoia/Makefile ext/libvisual/Makefile ext/ogg/Makefile +ext/opus/Makefile ext/pango/Makefile ext/theora/Makefile ext/vorbis/Makefile diff --git a/ext/Makefile.am b/ext/Makefile.am index dc8af0e3b..59fe8e656 100644 --- a/ext/Makefile.am +++ b/ext/Makefile.am @@ -22,6 +22,12 @@ else OGG_DIR= endif +if USE_OPUS +OPUS_DIR=opus +else +OPUS_DIR= +endif + if USE_PANGO PANGO_DIR = pango else @@ -53,6 +59,7 @@ SUBDIRS = \ $(CDPARANOIA_DIR) \ $(LIBVISUAL_DIR) \ $(OGG_DIR) \ + $(OPUS_DIR) \ $(PANGO_DIR) \ $(THEORA_DIR) \ $(VORBIS_DIR) @@ -62,6 +69,7 @@ DIST_SUBDIRS = \ cdparanoia \ libvisual \ ogg \ + opus \ pango \ theora \ vorbis diff --git a/ext/opus/Makefile.am b/ext/opus/Makefile.am index c64369252..27ae39d91 100644 --- a/ext/opus/Makefile.am +++ b/ext/opus/Makefile.am @@ -1,6 +1,6 @@ plugin_LTLIBRARIES = libgstopus.la -libgstopus_la_SOURCES = gstopus.c gstopusdec.c gstopusenc.c gstopusparse.c gstopusheader.c gstopuscommon.c gstrtpopuspay.c gstrtpopusdepay.c +libgstopus_la_SOURCES = gstopus.c gstopusdec.c gstopusenc.c gstopusheader.c gstopuscommon.c libgstopus_la_CFLAGS = \ -DGST_USE_UNSTABLE_API \ $(GST_PLUGINS_BAD_CFLAGS) \ @@ -8,13 +8,13 @@ libgstopus_la_CFLAGS = \ $(GST_CFLAGS) \ $(OPUS_CFLAGS) libgstopus_la_LIBADD = \ - $(GST_PLUGINS_BASE_LIBS) -lgstaudio-$(GST_API_VERSION) \ - -lgsttag-$(GST_API_VERSION) -lgstrtp-$(GST_API_VERSION) \ - -lgstpbutils-$(GST_API_VERSION) \ + $(top_builddir)/gst-libs/gst/tag/libgsttag-$(GST_API_VERSION).la \ + $(top_builddir)/gst-libs/gst/pbutils/libgstpbutils-$(GST_API_VERSION).la \ + $(top_builddir)/gst-libs/gst/audio/libgstaudio-$(GST_API_VERSION).la \ $(GST_BASE_LIBS) \ $(GST_LIBS) \ $(OPUS_LIBS) libgstopus_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS) $(LIBM) libgstopus_la_LIBTOOLFLAGS = $(GST_PLUGIN_LIBTOOLFLAGS) -noinst_HEADERS = gstopusenc.h gstopusdec.h gstopusparse.h gstopusheader.h gstopuscommon.h gstrtpopuspay.h gstrtpopusdepay.h +noinst_HEADERS = gstopusenc.h gstopusdec.h gstopusheader.h gstopuscommon.h diff --git a/ext/opus/gstopus.c b/ext/opus/gstopus.c index a3427b284..e16acea9f 100644 --- a/ext/opus/gstopus.c +++ b/ext/opus/gstopus.c @@ -23,10 +23,6 @@ #include "gstopusdec.h" #include "gstopusenc.h" -#include "gstopusparse.h" - -#include "gstrtpopuspay.h" -#include "gstrtpopusdepay.h" #include @@ -42,18 +38,6 @@ plugin_init (GstPlugin * plugin) GST_TYPE_OPUS_DEC)) return FALSE; - if (!gst_element_register (plugin, "opusparse", GST_RANK_NONE, - GST_TYPE_OPUS_PARSE)) - return FALSE; - - if (!gst_element_register (plugin, "rtpopusdepay", GST_RANK_SECONDARY, - GST_TYPE_RTP_OPUS_DEPAY)) - return FALSE; - - if (!gst_element_register (plugin, "rtpopuspay", GST_RANK_SECONDARY, - GST_TYPE_RTP_OPUS_PAY)) - return FALSE; - gst_tag_register_musicbrainz_tags (); return TRUE; diff --git a/tests/check/Makefile.am b/tests/check/Makefile.am index 64cf29499..ed1d02654 100644 --- a/tests/check/Makefile.am +++ b/tests/check/Makefile.am @@ -42,6 +42,12 @@ else check_ogg = endif +if USE_OPUS +check_opus = elements/opus +else +check_opus = +endif + if USE_PANGO check_pango = elements/textoverlay else @@ -224,6 +230,7 @@ check_PROGRAMS = \ $(check_encodebin) \ $(check_gio) \ $(check_ogg) \ + $(check_opus) \ $(check_pango) \ $(check_playback) \ $(check_subparse) \ diff --git a/tests/check/elements/.gitignore b/tests/check/elements/.gitignore index a7594ea97..b4346b894 100644 --- a/tests/check/elements/.gitignore +++ b/tests/check/elements/.gitignore @@ -12,6 +12,7 @@ encodebin libvisual multifdsink multisocketsink +opus videorate videotestsrc volume @@ -24,5 +25,6 @@ vorbistag playbin playbin-compressed playbin-complex +playsink streamsynchronizer subparse -- cgit v1.2.1