changeset 9264:1853405d2b86

8134996: GSTREAMER_LITE conditional compilation should be used for all changes in GStreamer Reviewed-by: stayer
author almatvee
date Mon, 21 Sep 2015 16:17:03 -0700
parents 61c180bd4744
children d32c32056ba1
files modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/build/win32/dirent/dirent.c modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/build/win32/dirent/dirent.h modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/build/win32/dirent/wdirent.c modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/deprecated/gthread.h modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gbacktrace.c modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gfileutils.c modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/ggettext.c modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gmarkup.c modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gstrfuncs.c modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gtimezone.c modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gutils.c modules/media/src/main/native/gstreamer/3rd_party/libffi/src/x86/ffi.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-bad/COPYING modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/ext/alsa/gstalsaplugin.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/ext/alsa/gstalsasink.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/ext/alsa/gstalsasrc.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/ext/alsa/gstalsasrc.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/audio/gstaudiobasesink.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/audio/gstaudioringbuffer.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/pbutils/gstdiscoverer.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/riff/riff-ids.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/tag/gsttagdemux.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/tag/gsttageditingprivate.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/video/gstvideosink.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/video/video.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/typefind/gsttypefindfunctions.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolume.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolumeorc-dist.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolumeorc-dist.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolumeorc.orc modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audioamplify.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiochebband.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiochebband.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiocheblimit.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiocheblimit.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiodynamic.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiodynamic.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audioecho.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audioecho.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofirfilter.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofirfilter.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofx.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofxbasefirfilter.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofxbasefirfilter.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofxbaseiirfilter.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofxbaseiirfilter.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audioiirfilter.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audioiirfilter.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audioinvert.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audioinvert.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiokaraoke.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiokaraoke.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiopanorama.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiowsincband.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiowsincband.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiowsinclimit.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiowsinclimit.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/gstscaletempo.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/gstscaletempo.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/math_compat.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/isomp4/qtdemux.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/isomp4/qtdemux.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/sys/osxaudio/gstosxaudioringbuffer.c modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/sys/osxaudio/gstosxaudiosrc.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/sys/osxvideo/cocoawindow.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/sys/osxvideo/cocoawindow.m modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/sys/osxvideo/osxvideosink.h modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/sys/osxvideo/osxvideosink.m modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/gst/gst.c modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/gst/gstbufferlist.c modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/gst/gstcaps.c modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/gst/gstcaps.h modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/gst/gstelement.h modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/gst/gstmessage.c modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/gst/gstpad.c modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/gst/gstpadtemplate.c modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/gst/gstsegment.c modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/gst/gstutils.c modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/gst/gstvalue.c modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/libs/gst/base/gstbaseparse.c modules/media/src/main/native/gstreamer/gstreamer-lite/gstreamer/libs/gst/base/gstbasetransform.c modules/media/src/main/native/gstreamer/projects/linux/gstreamer-lite/Makefile modules/media/src/main/native/gstreamer/projects/mac/gstreamer-lite/Makefile modules/media/src/main/native/gstreamer/projects/mac/libffi/Makefile modules/media/src/main/native/gstreamer/projects/win/glib-lite/Makefile.ffi
diffstat 85 files changed, 1897 insertions(+), 12334 deletions(-) [+]
line wrap: on
line diff
--- a/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/build/win32/dirent/dirent.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/build/win32/dirent/dirent.c	Mon Sep 21 16:17:03 2015 -0700
@@ -1,341 +1,341 @@
-/*
- * dirent.c
- * This file has no copyright assigned and is placed in the Public Domain.
- * This file is a part of the mingw-runtime package.
- * No warranty is given; refer to the file DISCLAIMER within the package.
- *
- * Derived from DIRLIB.C by Matt J. Weinstein
- * This note appears in the DIRLIB.H
- * DIRLIB.H by M. J. Weinstein   Released to public domain 1-Jan-89
- *
- * Updated by Jeremy Bettis <jeremy@hksys.com>
- * Significantly revised and rewinddir, seekdir and telldir added by Colin
- * Peters <colin@fu.is.saga-u.ac.jp>
- *	
- */
-
-#include <stdlib.h>
-#include <errno.h>
-#include <string.h>
-#include <io.h>
-#include <direct.h>
-
-#include "dirent.h"
-
-#define WIN32_LEAN_AND_MEAN
-#include <windows.h> /* for GetFileAttributes */
-
-#include <tchar.h>
-
-#ifdef _UNICODE
-#define _tdirent	_wdirent
-#define _TDIR 		_WDIR
-#define _topendir	_wopendir
-#define _tclosedir	_wclosedir
-#define _treaddir	_wreaddir
-#define _trewinddir	_wrewinddir
-#define _ttelldir	_wtelldir
-#define _tseekdir	_wseekdir
-#else
-#define _tdirent	dirent
-#define _TDIR 		DIR
-#define _topendir	opendir
-#define _tclosedir	closedir
-#define _treaddir	readdir
-#define _trewinddir	rewinddir
-#define _ttelldir	telldir
-#define _tseekdir	seekdir
-#endif
-
-#define SUFFIX	_T("*")
-#define	SLASH	_T("\\")
-
-
-/*
- * opendir
- *
- * Returns a pointer to a DIR structure appropriately filled in to begin
- * searching a directory.
- */
-_TDIR *
-_topendir (const _TCHAR *szPath)
-{
-  _TDIR *nd;
-  unsigned int rc;
-  _TCHAR szFullPath[MAX_PATH];
-	
-  errno = 0;
-
-  if (!szPath)
-    {
-      errno = EFAULT;
-      return (_TDIR *) 0;
-    }
-
-  if (szPath[0] == _T('\0'))
-    {
-      errno = ENOTDIR;
-      return (_TDIR *) 0;
-    }
-
-  /* Attempt to determine if the given path really is a directory. */
-  rc = GetFileAttributes (szPath);
-  if (rc == (unsigned int)-1)
-    {
-      /* call GetLastError for more error info */
-      errno = ENOENT;
-      return (_TDIR *) 0;
-    }
-  if (!(rc & FILE_ATTRIBUTE_DIRECTORY))
-    {
-      /* Error, entry exists but not a directory. */
-      errno = ENOTDIR;
-      return (_TDIR *) 0;
-    }
-
-  /* Make an absolute pathname.  */
-  _tfullpath (szFullPath, szPath, MAX_PATH);
-
-  /* Allocate enough space to store DIR structure and the complete
-   * directory path given. */
-  nd = (_TDIR *) malloc (sizeof (_TDIR) + (_tcslen(szFullPath) + _tcslen (SLASH) +
-			 _tcslen(SUFFIX) + 1) * sizeof(_TCHAR));
-
-  if (!nd)
-    {
-      /* Error, out of memory. */
-      errno = ENOMEM;
-      return (_TDIR *) 0;
-    }
-
-  /* Create the search expression. */
-  _tcscpy (nd->dd_name, szFullPath);
-
-  /* Add on a slash if the path does not end with one. */
-  if (nd->dd_name[0] != _T('\0') &&
-      nd->dd_name[_tcslen (nd->dd_name) - 1] != _T('/') &&
-      nd->dd_name[_tcslen (nd->dd_name) - 1] != _T('\\'))
-    {
-      _tcscat (nd->dd_name, SLASH);
-    }
-
-  /* Add on the search pattern */
-  _tcscat (nd->dd_name, SUFFIX);
-
-  /* Initialize handle to -1 so that a premature closedir doesn't try
-   * to call _findclose on it. */
-  nd->dd_handle = -1;
-
-  /* Initialize the status. */
-  nd->dd_stat = 0;
-
-  /* Initialize the dirent structure. ino and reclen are invalid under
-   * Win32, and name simply points at the appropriate part of the
-   * findfirst_t structure. */
-  nd->dd_dir.d_ino = 0;
-  nd->dd_dir.d_reclen = 0;
-  nd->dd_dir.d_namlen = 0;
-  memset (nd->dd_dir.d_name, 0, FILENAME_MAX);
-
-  return nd;
-}
-
-
-/*
- * readdir
- *
- * Return a pointer to a dirent structure filled with the information on the
- * next entry in the directory.
- */
-struct _tdirent *
-_treaddir (_TDIR * dirp)
-{
-  errno = 0;
-
-  /* Check for valid DIR struct. */
-  if (!dirp)
-    {
-      errno = EFAULT;
-      return (struct _tdirent *) 0;
-    }
-
-  if (dirp->dd_stat < 0)
-    {
-      /* We have already returned all files in the directory
-       * (or the structure has an invalid dd_stat). */
-      return (struct _tdirent *) 0;
-    }
-  else if (dirp->dd_stat == 0)
-    {
-      /* We haven't started the search yet. */
-      /* Start the search */
-      dirp->dd_handle = _tfindfirst (dirp->dd_name, &(dirp->dd_dta));
-
-  	  if (dirp->dd_handle == -1)
-	{
-	  /* Whoops! Seems there are no files in that
-	   * directory. */
-	  dirp->dd_stat = -1;
-	}
-      else
-	{
-	  dirp->dd_stat = 1;
-	}
-    }
-  else
-    {
-      /* Get the next search entry. */
-      if (_tfindnext (dirp->dd_handle, &(dirp->dd_dta)))
-	{
-	  /* We are off the end or otherwise error.	
-	     _findnext sets errno to ENOENT if no more file
-	     Undo this. */
-	  DWORD winerr = GetLastError();
-	  if (winerr == ERROR_NO_MORE_FILES)
-	    errno = 0;	
-	  _findclose (dirp->dd_handle);
-	  dirp->dd_handle = -1;
-	  dirp->dd_stat = -1;
-	}
-      else
-	{
-	  /* Update the status to indicate the correct
-	   * number. */
-	  dirp->dd_stat++;
-	}
-    }
-
-  if (dirp->dd_stat > 0)
-    {
-      /* Successfully got an entry. Everything about the file is
-       * already appropriately filled in except the length of the
-       * file name. */
-      dirp->dd_dir.d_namlen = _tcslen (dirp->dd_dta.name);
-      _tcscpy (dirp->dd_dir.d_name, dirp->dd_dta.name);
-      return &dirp->dd_dir;
-    }
-
-  return (struct _tdirent *) 0;
-}
-
-
-/*
- * closedir
- *
- * Frees up resources allocated by opendir.
- */
-int
-_tclosedir (_TDIR * dirp)
-{
-  int rc;
-
-  errno = 0;
-  rc = 0;
-
-  if (!dirp)
-    {
-      errno = EFAULT;
-      return -1;
-    }
-
-  if (dirp->dd_handle != -1)
-    {
-      rc = _findclose (dirp->dd_handle);
-    }
-
-  /* Delete the dir structure. */
-  free (dirp);
-
-  return rc;
-}
-
-/*
- * rewinddir
- *
- * Return to the beginning of the directory "stream". We simply call findclose
- * and then reset things like an opendir.
- */
-void
-_trewinddir (_TDIR * dirp)
-{
-  errno = 0;
-
-  if (!dirp)
-    {
-      errno = EFAULT;
-      return;
-    }
-
-  if (dirp->dd_handle != -1)
-    {
-      _findclose (dirp->dd_handle);
-    }
-
-  dirp->dd_handle = -1;
-  dirp->dd_stat = 0;
-}
-
-/*
- * telldir
- *
- * Returns the "position" in the "directory stream" which can be used with
- * seekdir to go back to an old entry. We simply return the value in stat.
- */
-long
-_ttelldir (_TDIR * dirp)
-{
-  errno = 0;
-
-  if (!dirp)
-    {
-      errno = EFAULT;
-      return -1;
-    }
-  return dirp->dd_stat;
-}
-
-/*
- * seekdir
- *
- * Seek to an entry previously returned by telldir. We rewind the directory
- * and call readdir repeatedly until either dd_stat is the position number
- * or -1 (off the end). This is not perfect, in that the directory may
- * have changed while we weren't looking. But that is probably the case with
- * any such system.
- */
-void
-_tseekdir (_TDIR * dirp, long lPos)
-{
-  errno = 0;
-
-  if (!dirp)
-    {
-      errno = EFAULT;
-      return;
-    }
-
-  if (lPos < -1)
-    {
-      /* Seeking to an invalid position. */
-      errno = EINVAL;
-      return;
-    }
-  else if (lPos == -1)
-    {
-      /* Seek past end. */
-      if (dirp->dd_handle != -1)
-	{
-	  _findclose (dirp->dd_handle);
-	}
-      dirp->dd_handle = -1;
-      dirp->dd_stat = -1;
-    }
-  else
-    {
-      /* Rewind and read forward to the appropriate index. */
-      _trewinddir (dirp);
-
-      while ((dirp->dd_stat < lPos) && _treaddir (dirp))
-	;
-    }
-}
+/*
+ * dirent.c
+ * This file has no copyright assigned and is placed in the Public Domain.
+ * This file is a part of the mingw-runtime package.
+ * No warranty is given; refer to the file DISCLAIMER within the package.
+ *
+ * Derived from DIRLIB.C by Matt J. Weinstein
+ * This note appears in the DIRLIB.H
+ * DIRLIB.H by M. J. Weinstein   Released to public domain 1-Jan-89
+ *
+ * Updated by Jeremy Bettis <jeremy@hksys.com>
+ * Significantly revised and rewinddir, seekdir and telldir added by Colin
+ * Peters <colin@fu.is.saga-u.ac.jp>
+ *	
+ */
+
+#include <stdlib.h>
+#include <errno.h>
+#include <string.h>
+#include <io.h>
+#include <direct.h>
+
+#include "dirent.h"
+
+#define WIN32_LEAN_AND_MEAN
+#include <windows.h> /* for GetFileAttributes */
+
+#include <tchar.h>
+
+#ifdef _UNICODE
+#define _tdirent	_wdirent
+#define _TDIR 		_WDIR
+#define _topendir	_wopendir
+#define _tclosedir	_wclosedir
+#define _treaddir	_wreaddir
+#define _trewinddir	_wrewinddir
+#define _ttelldir	_wtelldir
+#define _tseekdir	_wseekdir
+#else
+#define _tdirent	dirent
+#define _TDIR 		DIR
+#define _topendir	opendir
+#define _tclosedir	closedir
+#define _treaddir	readdir
+#define _trewinddir	rewinddir
+#define _ttelldir	telldir
+#define _tseekdir	seekdir
+#endif
+
+#define SUFFIX	_T("*")
+#define	SLASH	_T("\\")
+
+
+/*
+ * opendir
+ *
+ * Returns a pointer to a DIR structure appropriately filled in to begin
+ * searching a directory.
+ */
+_TDIR *
+_topendir (const _TCHAR *szPath)
+{
+  _TDIR *nd;
+  unsigned int rc;
+  _TCHAR szFullPath[MAX_PATH];
+	
+  errno = 0;
+
+  if (!szPath)
+    {
+      errno = EFAULT;
+      return (_TDIR *) 0;
+    }
+
+  if (szPath[0] == _T('\0'))
+    {
+      errno = ENOTDIR;
+      return (_TDIR *) 0;
+    }
+
+  /* Attempt to determine if the given path really is a directory. */
+  rc = GetFileAttributes (szPath);
+  if (rc == (unsigned int)-1)
+    {
+      /* call GetLastError for more error info */
+      errno = ENOENT;
+      return (_TDIR *) 0;
+    }
+  if (!(rc & FILE_ATTRIBUTE_DIRECTORY))
+    {
+      /* Error, entry exists but not a directory. */
+      errno = ENOTDIR;
+      return (_TDIR *) 0;
+    }
+
+  /* Make an absolute pathname.  */
+  _tfullpath (szFullPath, szPath, MAX_PATH);
+
+  /* Allocate enough space to store DIR structure and the complete
+   * directory path given. */
+  nd = (_TDIR *) malloc (sizeof (_TDIR) + (_tcslen(szFullPath) + _tcslen (SLASH) +
+			 _tcslen(SUFFIX) + 1) * sizeof(_TCHAR));
+
+  if (!nd)
+    {
+      /* Error, out of memory. */
+      errno = ENOMEM;
+      return (_TDIR *) 0;
+    }
+
+  /* Create the search expression. */
+  _tcscpy (nd->dd_name, szFullPath);
+
+  /* Add on a slash if the path does not end with one. */
+  if (nd->dd_name[0] != _T('\0') &&
+      nd->dd_name[_tcslen (nd->dd_name) - 1] != _T('/') &&
+      nd->dd_name[_tcslen (nd->dd_name) - 1] != _T('\\'))
+    {
+      _tcscat (nd->dd_name, SLASH);
+    }
+
+  /* Add on the search pattern */
+  _tcscat (nd->dd_name, SUFFIX);
+
+  /* Initialize handle to -1 so that a premature closedir doesn't try
+   * to call _findclose on it. */
+  nd->dd_handle = -1;
+
+  /* Initialize the status. */
+  nd->dd_stat = 0;
+
+  /* Initialize the dirent structure. ino and reclen are invalid under
+   * Win32, and name simply points at the appropriate part of the
+   * findfirst_t structure. */
+  nd->dd_dir.d_ino = 0;
+  nd->dd_dir.d_reclen = 0;
+  nd->dd_dir.d_namlen = 0;
+  memset (nd->dd_dir.d_name, 0, FILENAME_MAX);
+
+  return nd;
+}
+
+
+/*
+ * readdir
+ *
+ * Return a pointer to a dirent structure filled with the information on the
+ * next entry in the directory.
+ */
+struct _tdirent *
+_treaddir (_TDIR * dirp)
+{
+  errno = 0;
+
+  /* Check for valid DIR struct. */
+  if (!dirp)
+    {
+      errno = EFAULT;
+      return (struct _tdirent *) 0;
+    }
+
+  if (dirp->dd_stat < 0)
+    {
+      /* We have already returned all files in the directory
+       * (or the structure has an invalid dd_stat). */
+      return (struct _tdirent *) 0;
+    }
+  else if (dirp->dd_stat == 0)
+    {
+      /* We haven't started the search yet. */
+      /* Start the search */
+      dirp->dd_handle = _tfindfirst (dirp->dd_name, &(dirp->dd_dta));
+
+  	  if (dirp->dd_handle == -1)
+	{
+	  /* Whoops! Seems there are no files in that
+	   * directory. */
+	  dirp->dd_stat = -1;
+	}
+      else
+	{
+	  dirp->dd_stat = 1;
+	}
+    }
+  else
+    {
+      /* Get the next search entry. */
+      if (_tfindnext (dirp->dd_handle, &(dirp->dd_dta)))
+	{
+	  /* We are off the end or otherwise error.	
+	     _findnext sets errno to ENOENT if no more file
+	     Undo this. */
+	  DWORD winerr = GetLastError();
+	  if (winerr == ERROR_NO_MORE_FILES)
+	    errno = 0;	
+	  _findclose (dirp->dd_handle);
+	  dirp->dd_handle = -1;
+	  dirp->dd_stat = -1;
+	}
+      else
+	{
+	  /* Update the status to indicate the correct
+	   * number. */
+	  dirp->dd_stat++;
+	}
+    }
+
+  if (dirp->dd_stat > 0)
+    {
+      /* Successfully got an entry. Everything about the file is
+       * already appropriately filled in except the length of the
+       * file name. */
+      dirp->dd_dir.d_namlen = _tcslen (dirp->dd_dta.name);
+      _tcscpy (dirp->dd_dir.d_name, dirp->dd_dta.name);
+      return &dirp->dd_dir;
+    }
+
+  return (struct _tdirent *) 0;
+}
+
+
+/*
+ * closedir
+ *
+ * Frees up resources allocated by opendir.
+ */
+int
+_tclosedir (_TDIR * dirp)
+{
+  int rc;
+
+  errno = 0;
+  rc = 0;
+
+  if (!dirp)
+    {
+      errno = EFAULT;
+      return -1;
+    }
+
+  if (dirp->dd_handle != -1)
+    {
+      rc = _findclose (dirp->dd_handle);
+    }
+
+  /* Delete the dir structure. */
+  free (dirp);
+
+  return rc;
+}
+
+/*
+ * rewinddir
+ *
+ * Return to the beginning of the directory "stream". We simply call findclose
+ * and then reset things like an opendir.
+ */
+void
+_trewinddir (_TDIR * dirp)
+{
+  errno = 0;
+
+  if (!dirp)
+    {
+      errno = EFAULT;
+      return;
+    }
+
+  if (dirp->dd_handle != -1)
+    {
+      _findclose (dirp->dd_handle);
+    }
+
+  dirp->dd_handle = -1;
+  dirp->dd_stat = 0;
+}
+
+/*
+ * telldir
+ *
+ * Returns the "position" in the "directory stream" which can be used with
+ * seekdir to go back to an old entry. We simply return the value in stat.
+ */
+long
+_ttelldir (_TDIR * dirp)
+{
+  errno = 0;
+
+  if (!dirp)
+    {
+      errno = EFAULT;
+      return -1;
+    }
+  return dirp->dd_stat;
+}
+
+/*
+ * seekdir
+ *
+ * Seek to an entry previously returned by telldir. We rewind the directory
+ * and call readdir repeatedly until either dd_stat is the position number
+ * or -1 (off the end). This is not perfect, in that the directory may
+ * have changed while we weren't looking. But that is probably the case with
+ * any such system.
+ */
+void
+_tseekdir (_TDIR * dirp, long lPos)
+{
+  errno = 0;
+
+  if (!dirp)
+    {
+      errno = EFAULT;
+      return;
+    }
+
+  if (lPos < -1)
+    {
+      /* Seeking to an invalid position. */
+      errno = EINVAL;
+      return;
+    }
+  else if (lPos == -1)
+    {
+      /* Seek past end. */
+      if (dirp->dd_handle != -1)
+	{
+	  _findclose (dirp->dd_handle);
+	}
+      dirp->dd_handle = -1;
+      dirp->dd_stat = -1;
+    }
+  else
+    {
+      /* Rewind and read forward to the appropriate index. */
+      _trewinddir (dirp);
+
+      while ((dirp->dd_stat < lPos) && _treaddir (dirp))
+	;
+    }
+}
--- a/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/build/win32/dirent/dirent.h	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/build/win32/dirent/dirent.h	Mon Sep 21 16:17:03 2015 -0700
@@ -1,127 +1,127 @@
-/*
- * DIRENT.H (formerly DIRLIB.H)
- * This file has no copyright assigned and is placed in the Public Domain.
- * This file is a part of the mingw-runtime package.
- * No warranty is given; refer to the file DISCLAIMER within the package.
- *
- */
-#ifndef _DIRENT_H_
-#define _DIRENT_H_
-
-#include <stdio.h>
-#include <io.h>
-
-#ifndef RC_INVOKED
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-struct dirent
-{
-	long		d_ino;		/* Always zero. */
-	unsigned short	d_reclen;	/* Always zero. */
-	unsigned short	d_namlen;	/* Length of name in d_name. */
-	char		d_name[FILENAME_MAX]; /* File name. */
-};
-
-#ifdef _WIN64
-#define INTPTR __int64
-#else
-#define INTPTR long
-#endif
-
-/*
- * This is an internal data structure. Good programmers will not use it
- * except as an argument to one of the functions below.
- * dd_stat field is now int (was short in older versions).
- */
-typedef struct
-{
-	/* disk transfer area for this dir */
-	struct _finddata_t	dd_dta;
-
-	/* dirent struct to return from dir (NOTE: this makes this thread
-	 * safe as long as only one thread uses a particular DIR struct at
-	 * a time) */
-	struct dirent		dd_dir;
-
-	/* _findnext handle */
-	INTPTR			dd_handle;
-
-	/*
-         * Status of search:
-	 *   0 = not started yet (next entry to read is first entry)
-	 *  -1 = off the end
-	 *   positive = 0 based index of next entry
-	 */
-	int			dd_stat;
-
-	/* given path for dir with search pattern (struct is extended) */
-	char			dd_name[1];
-} DIR;
-
-DIR* __cdecl opendir (const char*);
-struct dirent* __cdecl readdir (DIR*);
-int __cdecl closedir (DIR*);
-void __cdecl rewinddir (DIR*);
-long __cdecl telldir (DIR*);
-void __cdecl seekdir (DIR*, long);
-
-
-/* wide char versions */
-
-struct _wdirent
-{
-	long		d_ino;		/* Always zero. */
-	unsigned short	d_reclen;	/* Always zero. */
-	unsigned short	d_namlen;	/* Length of name in d_name. */
-	wchar_t		d_name[FILENAME_MAX]; /* File name. */
-};
-
-/*
- * This is an internal data structure. Good programmers will not use it
- * except as an argument to one of the functions below.
- */
-typedef struct
-{
-	/* disk transfer area for this dir */
-	struct _wfinddata_t	dd_dta;
-
-	/* dirent struct to return from dir (NOTE: this makes this thread
-	 * safe as long as only one thread uses a particular DIR struct at
-	 * a time) */
-	struct _wdirent		dd_dir;
-
-	/* _findnext handle */
-	INTPTR			dd_handle;
-
-	/*
-         * Status of search:
-	 *   0 = not started yet (next entry to read is first entry)
-	 *  -1 = off the end
-	 *   positive = 0 based index of next entry
-	 */
-	int			dd_stat;
-
-	/* given path for dir with search pattern (struct is extended) */
-	wchar_t			dd_name[1];
-} _WDIR;
-
-
-
-_WDIR* __cdecl _wopendir (const wchar_t*);
-struct _wdirent*  __cdecl _wreaddir (_WDIR*);
-int __cdecl _wclosedir (_WDIR*);
-void __cdecl _wrewinddir (_WDIR*);
-long __cdecl _wtelldir (_WDIR*);
-void __cdecl _wseekdir (_WDIR*, long);
-
-
-#ifdef	__cplusplus
-}
-#endif
-
-#endif	/* Not RC_INVOKED */
-
-#endif	/* Not _DIRENT_H_ */
+/*
+ * DIRENT.H (formerly DIRLIB.H)
+ * This file has no copyright assigned and is placed in the Public Domain.
+ * This file is a part of the mingw-runtime package.
+ * No warranty is given; refer to the file DISCLAIMER within the package.
+ *
+ */
+#ifndef _DIRENT_H_
+#define _DIRENT_H_
+
+#include <stdio.h>
+#include <io.h>
+
+#ifndef RC_INVOKED
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+struct dirent
+{
+	long		d_ino;		/* Always zero. */
+	unsigned short	d_reclen;	/* Always zero. */
+	unsigned short	d_namlen;	/* Length of name in d_name. */
+	char		d_name[FILENAME_MAX]; /* File name. */
+};
+
+#ifdef _WIN64
+#define INTPTR __int64
+#else
+#define INTPTR long
+#endif
+
+/*
+ * This is an internal data structure. Good programmers will not use it
+ * except as an argument to one of the functions below.
+ * dd_stat field is now int (was short in older versions).
+ */
+typedef struct
+{
+	/* disk transfer area for this dir */
+	struct _finddata_t	dd_dta;
+
+	/* dirent struct to return from dir (NOTE: this makes this thread
+	 * safe as long as only one thread uses a particular DIR struct at
+	 * a time) */
+	struct dirent		dd_dir;
+
+	/* _findnext handle */
+	INTPTR			dd_handle;
+
+	/*
+         * Status of search:
+	 *   0 = not started yet (next entry to read is first entry)
+	 *  -1 = off the end
+	 *   positive = 0 based index of next entry
+	 */
+	int			dd_stat;
+
+	/* given path for dir with search pattern (struct is extended) */
+	char			dd_name[1];
+} DIR;
+
+DIR* __cdecl opendir (const char*);
+struct dirent* __cdecl readdir (DIR*);
+int __cdecl closedir (DIR*);
+void __cdecl rewinddir (DIR*);
+long __cdecl telldir (DIR*);
+void __cdecl seekdir (DIR*, long);
+
+
+/* wide char versions */
+
+struct _wdirent
+{
+	long		d_ino;		/* Always zero. */
+	unsigned short	d_reclen;	/* Always zero. */
+	unsigned short	d_namlen;	/* Length of name in d_name. */
+	wchar_t		d_name[FILENAME_MAX]; /* File name. */
+};
+
+/*
+ * This is an internal data structure. Good programmers will not use it
+ * except as an argument to one of the functions below.
+ */
+typedef struct
+{
+	/* disk transfer area for this dir */
+	struct _wfinddata_t	dd_dta;
+
+	/* dirent struct to return from dir (NOTE: this makes this thread
+	 * safe as long as only one thread uses a particular DIR struct at
+	 * a time) */
+	struct _wdirent		dd_dir;
+
+	/* _findnext handle */
+	INTPTR			dd_handle;
+
+	/*
+         * Status of search:
+	 *   0 = not started yet (next entry to read is first entry)
+	 *  -1 = off the end
+	 *   positive = 0 based index of next entry
+	 */
+	int			dd_stat;
+
+	/* given path for dir with search pattern (struct is extended) */
+	wchar_t			dd_name[1];
+} _WDIR;
+
+
+
+_WDIR* __cdecl _wopendir (const wchar_t*);
+struct _wdirent*  __cdecl _wreaddir (_WDIR*);
+int __cdecl _wclosedir (_WDIR*);
+void __cdecl _wrewinddir (_WDIR*);
+long __cdecl _wtelldir (_WDIR*);
+void __cdecl _wseekdir (_WDIR*, long);
+
+
+#ifdef	__cplusplus
+}
+#endif
+
+#endif	/* Not RC_INVOKED */
+
+#endif	/* Not _DIRENT_H_ */
--- a/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/build/win32/dirent/wdirent.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/build/win32/dirent/wdirent.c	Mon Sep 21 16:17:03 2015 -0700
@@ -1,3 +1,3 @@
-#define _UNICODE 1
-#define UNICODE 1
-#include "dirent.c"
+#define _UNICODE 1
+#define UNICODE 1
+#include "dirent.c"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/deprecated/gthread.h	Mon Sep 21 16:17:03 2015 -0700
@@ -0,0 +1,299 @@
+/* GLIB - Library of useful routines for C programming
+ * Copyright (C) 1995-1997  Peter Mattis, Spencer Kimball and Josh MacDonald
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, see <http://www.gnu.org/licenses/>.
+ */
+
+/*
+ * Modified by the GLib Team and others 1997-2000.  See the AUTHORS
+ * file for a list of people on the GLib Team.  See the ChangeLog
+ * files for a list of changes.  These files are distributed with
+ * GLib at ftp://ftp.gtk.org/pub/gtk/.
+ */
+
+#ifndef __G_DEPRECATED_THREAD_H__
+#define __G_DEPRECATED_THREAD_H__
+
+#if !defined (__GLIB_H_INSIDE__) && !defined (GLIB_COMPILATION)
+#error "Only <glib.h> can be included directly."
+#endif
+
+#include <glib/gthread.h>
+
+G_BEGIN_DECLS
+
+#ifndef G_DISABLE_DEPRECATED
+
+typedef enum
+{
+  G_THREAD_PRIORITY_LOW,
+  G_THREAD_PRIORITY_NORMAL,
+  G_THREAD_PRIORITY_HIGH,
+  G_THREAD_PRIORITY_URGENT
+} GThreadPriority;
+
+#endif
+
+struct  _GThread
+{
+  /*< private >*/
+  GThreadFunc func;
+  gpointer data;
+  gboolean joinable;
+#ifdef GSTREAMER_LITE
+#ifndef G_DISABLE_DEPRECATED
+  GThreadPriority priority;
+#endif // G_DISABLE_DEPRECATED
+#else // GSTREAMER_LITE
+  GThreadPriority priority;
+#endif // GSTREAMER_LITE
+};
+
+#ifndef G_DISABLE_DEPRECATED
+
+typedef struct _GThreadFunctions GThreadFunctions;
+struct _GThreadFunctions
+{
+  GMutex*  (*mutex_new)           (void);
+  void     (*mutex_lock)          (GMutex               *mutex);
+  gboolean (*mutex_trylock)       (GMutex               *mutex);
+  void     (*mutex_unlock)        (GMutex               *mutex);
+  void     (*mutex_free)          (GMutex               *mutex);
+  GCond*   (*cond_new)            (void);
+  void     (*cond_signal)         (GCond                *cond);
+  void     (*cond_broadcast)      (GCond                *cond);
+  void     (*cond_wait)           (GCond                *cond,
+                                   GMutex               *mutex);
+  gboolean (*cond_timed_wait)     (GCond                *cond,
+                                   GMutex               *mutex,
+                                   GTimeVal             *end_time);
+  void      (*cond_free)          (GCond                *cond);
+  GPrivate* (*private_new)        (GDestroyNotify        destructor);
+  gpointer  (*private_get)        (GPrivate             *private_key);
+  void      (*private_set)        (GPrivate             *private_key,
+                                   gpointer              data);
+  void      (*thread_create)      (GThreadFunc           func,
+                                   gpointer              data,
+                                   gulong                stack_size,
+                                   gboolean              joinable,
+                                   gboolean              bound,
+                                   GThreadPriority       priority,
+                                   gpointer              thread,
+                                   GError              **error);
+  void      (*thread_yield)       (void);
+  void      (*thread_join)        (gpointer              thread);
+  void      (*thread_exit)        (void);
+  void      (*thread_set_priority)(gpointer              thread,
+                                   GThreadPriority       priority);
+  void      (*thread_self)        (gpointer              thread);
+  gboolean  (*thread_equal)       (gpointer              thread1,
+                                   gpointer              thread2);
+};
+
+GLIB_VAR GThreadFunctions       g_thread_functions_for_glib_use;
+GLIB_VAR gboolean               g_thread_use_default_impl;
+
+GLIB_VAR guint64   (*g_thread_gettime) (void);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_thread_new)
+GThread *g_thread_create       (GThreadFunc       func,
+                                gpointer          data,
+                                gboolean          joinable,
+                                GError          **error);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_thread_new)
+GThread *g_thread_create_full  (GThreadFunc       func,
+                                gpointer          data,
+                                gulong            stack_size,
+                                gboolean          joinable,
+                                gboolean          bound,
+                                GThreadPriority   priority,
+                                GError          **error);
+
+GLIB_DEPRECATED_IN_2_32
+void     g_thread_set_priority (GThread          *thread,
+                                GThreadPriority   priority);
+
+GLIB_DEPRECATED_IN_2_32
+void     g_thread_foreach      (GFunc             thread_func,
+                                gpointer          user_data);
+
+#ifndef G_OS_WIN32
+#include <sys/types.h>
+#include <pthread.h>
+#endif
+
+#define g_static_mutex_get_mutex g_static_mutex_get_mutex_impl
+#define G_STATIC_MUTEX_INIT { NULL }
+typedef struct
+{
+  GMutex *mutex;
+#ifndef G_OS_WIN32
+  /* only for ABI compatibility reasons */
+  pthread_mutex_t unused;
+#endif
+} GStaticMutex;
+
+#define g_static_mutex_lock(mutex) \
+    g_mutex_lock (g_static_mutex_get_mutex (mutex))
+#define g_static_mutex_trylock(mutex) \
+    g_mutex_trylock (g_static_mutex_get_mutex (mutex))
+#define g_static_mutex_unlock(mutex) \
+    g_mutex_unlock (g_static_mutex_get_mutex (mutex))
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_mutex_init)
+void    g_static_mutex_init           (GStaticMutex *mutex);
+GLIB_DEPRECATED_IN_2_32_FOR(g_mutex_clear)
+void    g_static_mutex_free           (GStaticMutex *mutex);
+GLIB_DEPRECATED_IN_2_32_FOR(GMutex)
+GMutex *g_static_mutex_get_mutex_impl (GStaticMutex *mutex);
+
+typedef struct _GStaticRecMutex GStaticRecMutex;
+struct _GStaticRecMutex
+{
+  /*< private >*/
+  GStaticMutex mutex;
+  guint depth;
+
+  /* ABI compat only */
+  union {
+#ifdef G_OS_WIN32
+    void *owner;
+#else
+    pthread_t owner;
+#endif
+    gdouble dummy;
+  } unused;
+};
+
+#define G_STATIC_REC_MUTEX_INIT { G_STATIC_MUTEX_INIT }
+GLIB_DEPRECATED_IN_2_32_FOR(g_rec_mutex_init)
+void     g_static_rec_mutex_init        (GStaticRecMutex *mutex);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rec_mutex_lock)
+void     g_static_rec_mutex_lock        (GStaticRecMutex *mutex);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rec_mutex_try_lock)
+gboolean g_static_rec_mutex_trylock     (GStaticRecMutex *mutex);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rec_mutex_unlock)
+void     g_static_rec_mutex_unlock      (GStaticRecMutex *mutex);
+
+GLIB_DEPRECATED_IN_2_32
+void     g_static_rec_mutex_lock_full   (GStaticRecMutex *mutex,
+                                         guint            depth);
+
+GLIB_DEPRECATED_IN_2_32
+guint    g_static_rec_mutex_unlock_full (GStaticRecMutex *mutex);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rec_mutex_free)
+void     g_static_rec_mutex_free        (GStaticRecMutex *mutex);
+
+typedef struct _GStaticRWLock GStaticRWLock;
+struct _GStaticRWLock
+{
+  /*< private >*/
+  GStaticMutex mutex;
+  GCond *read_cond;
+  GCond *write_cond;
+  guint read_counter;
+  gboolean have_writer;
+  guint want_to_read;
+  guint want_to_write;
+};
+
+#define G_STATIC_RW_LOCK_INIT { G_STATIC_MUTEX_INIT, NULL, NULL, 0, FALSE, 0, 0 }
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rw_lock_init)
+void      g_static_rw_lock_init           (GStaticRWLock *lock);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rw_lock_reader_lock)
+void      g_static_rw_lock_reader_lock    (GStaticRWLock *lock);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rw_lock_reader_trylock)
+gboolean  g_static_rw_lock_reader_trylock (GStaticRWLock *lock);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rw_lock_reader_unlock)
+void      g_static_rw_lock_reader_unlock  (GStaticRWLock *lock);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rw_lock_writer_lock)
+void      g_static_rw_lock_writer_lock    (GStaticRWLock *lock);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rw_lock_writer_trylock)
+gboolean  g_static_rw_lock_writer_trylock (GStaticRWLock *lock);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rw_lock_writer_unlock)
+void      g_static_rw_lock_writer_unlock  (GStaticRWLock *lock);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_rw_lock_free)
+void      g_static_rw_lock_free           (GStaticRWLock *lock);
+
+GLIB_DEPRECATED_IN_2_32
+GPrivate *      g_private_new             (GDestroyNotify notify);
+
+typedef struct _GStaticPrivate  GStaticPrivate;
+struct _GStaticPrivate
+{
+  /*< private >*/
+  guint index;
+};
+
+#define G_STATIC_PRIVATE_INIT { 0 }
+GLIB_DEPRECATED_IN_2_32
+void     g_static_private_init           (GStaticPrivate *private_key);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_private_get)
+gpointer g_static_private_get            (GStaticPrivate *private_key);
+
+GLIB_DEPRECATED_IN_2_32_FOR(g_private_set)
+void     g_static_private_set            (GStaticPrivate *private_key,
+                                          gpointer        data,
+                                          GDestroyNotify  notify);
+
+GLIB_DEPRECATED_IN_2_32
+void     g_static_private_free           (GStaticPrivate *private_key);
+
+GLIB_DEPRECATED_IN_2_32
+gboolean g_once_init_enter_impl          (volatile gsize *location);
+
+GLIB_DEPRECATED_IN_2_32
+void     g_thread_init                   (gpointer vtable);
+GLIB_DEPRECATED_IN_2_32
+void    g_thread_init_with_errorcheck_mutexes (gpointer vtable);
+
+GLIB_DEPRECATED_IN_2_32
+gboolean g_thread_get_initialized        (void);
+
+GLIB_VAR gboolean g_threads_got_initialized;
+
+#define g_thread_supported()     (1)
+
+GLIB_DEPRECATED_IN_2_32
+GMutex *        g_mutex_new             (void);
+GLIB_DEPRECATED_IN_2_32
+void            g_mutex_free            (GMutex *mutex);
+GLIB_DEPRECATED_IN_2_32
+GCond *         g_cond_new              (void);
+GLIB_DEPRECATED_IN_2_32
+void            g_cond_free             (GCond  *cond);
+GLIB_DEPRECATED_IN_2_32
+gboolean        g_cond_timed_wait       (GCond          *cond,
+                                         GMutex         *mutex,
+                                         GTimeVal       *timeval);
+
+#endif
+
+G_END_DECLS
+
+#endif /* __G_DEPRECATED_THREAD_H__ */
--- a/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gbacktrace.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gbacktrace.c	Mon Sep 21 16:17:03 2015 -0700
@@ -251,12 +251,19 @@
 
   waitpid (pid, &status, 0);
 #else
-#ifdef G_ENABLE_DEBUG // GSTREAMER_LITE exception
+#ifdef GSTREAMER_LITE
+  #ifdef G_ENABLE_DEBUG
+    if (IsDebuggerPresent ())
+      G_BREAKPOINT ();
+    else
+  #endif // G_ENABLE_DEBUG
+    abort ();
+#else // GSTREAMER_LITE
   if (IsDebuggerPresent ())
     G_BREAKPOINT ();
   else
-#endif // GSTREAMER_LITE exception
     abort ();
+#endif // GSTREAMER_LITE
 #endif
 }
 
--- a/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gfileutils.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gfileutils.c	Mon Sep 21 16:17:03 2015 -0700
@@ -610,10 +610,15 @@
                       const gchar  *format_string,
                       int           saved_errno) G_GNUC_FORMAT(2);
 
+#ifdef GSTREAMER_LITE
 #ifndef G_OS_WIN32
 #pragma GCC diagnostic push
 #pragma GCC diagnostic ignored "-Wformat-nonliteral"
 #endif // G_OS_WIN32
+#else // GSTREAMER_LITE
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wformat-nonliteral"
+#endif // GSTREAMER_LITE
 
 static char *
 format_error_message (const gchar  *filename,
@@ -630,9 +635,13 @@
   return msg;
 }
 
+#ifdef GSTREAMER_LITE
 #ifndef G_OS_WIN32
 #pragma GCC diagnostic pop
 #endif // G_OS_WIN32
+#else // GSTREAMER_LITE
+#pragma GCC diagnostic pop
+#endif // GSTREAMER_LITE
 
 /* format string must have two '%s':
  *
--- a/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/ggettext.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/ggettext.c	Mon Sep 21 16:17:03 2015 -0700
@@ -40,9 +40,13 @@
 
 #include <string.h>
 #include <locale.h>
+#ifdef GSTREAMER_LITE
 #ifdef ENABLE_NLS
 #include <libintl.h>
 #endif
+#else // GSTREAMER_LITE
+#include <libintl.h>
+#endif // GSTREAMER_LITE
 #ifdef G_OS_WIN32
 
 /**
--- a/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gmarkup.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gmarkup.c	Mon Sep 21 16:17:03 2015 -0700
@@ -2382,10 +2382,15 @@
  * Since: 2.4
  */
 
+#ifdef GSTREAMER_LITE
 #ifndef G_OS_WIN32
 #pragma GCC diagnostic push
 #pragma GCC diagnostic ignored "-Wformat-nonliteral"
 #endif // G_OS_WIN32
+#else // GSTREAMER_LITE
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wformat-nonliteral"
+#endif // GSTREAMER_LITE
 
 gchar *
 g_markup_vprintf_escaped (const gchar *format,
@@ -2513,9 +2518,13 @@
     return NULL;
 }
 
+#ifdef GSTREAMER_LITE
 #ifndef G_OS_WIN32
 #pragma GCC diagnostic pop
 #endif // G_OS_WIN32
+#else // GSTREAMER_LITE
+#pragma GCC diagnostic pop
+#endif // GSTREAMER_LITE
 
 /**
  * g_markup_printf_escaped:
--- a/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gstrfuncs.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gstrfuncs.c	Mon Sep 21 16:17:03 2015 -0700
@@ -878,10 +878,15 @@
   return g_ascii_formatd (buffer, buf_len, "%.17g", d);
 }
 
+#ifdef GSTREAMER_LITE
 #ifndef G_OS_WIN32
 #pragma GCC diagnostic push
 #pragma GCC diagnostic ignored "-Wformat-nonliteral"
 #endif // G_OS_WIN32
+#else // GSTREAMER_LITE
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wformat-nonliteral"
+#endif // GSTREAMER_LITE
 
 /**
  * g_ascii_formatd:
@@ -991,9 +996,13 @@
 #endif
 }
 
+#ifdef GSTREAMER_LITE
 #ifndef G_OS_WIN32
 #pragma GCC diagnostic pop
 #endif // G_OS_WIN32
+#else // GSTREAMER_LITE
+#pragma GCC diagnostic pop
+#endif // GSTREAMER_LITE
 
 #define ISSPACE(c)              ((c) == ' ' || (c) == '\f' || (c) == '\n' || \
                                  (c) == '\r' || (c) == '\t' || (c) == '\v')
--- a/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gtimezone.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gtimezone.c	Mon Sep 21 16:17:03 2015 -0700
@@ -761,7 +761,11 @@
   else /* M.W.D */
     {
       guint days;
+#ifdef GSTREAMER_LITE
       guint days_in_month = g_date_get_days_in_month (buffer->mon, buffer->year);
+#else // GSTREAMER_LITE
+      guint days_in_month = g_date_days_in_month (buffer->mon, buffer->year);
+#endif // GSTREAMER_LITE
       GDateWeekday first_wday;
 
       g_date_set_dmy (&date, 1, buffer->mon, buffer->year);
--- a/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gutils.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/3rd_party/glib/glib-2.42.1/glib/gutils.c	Mon Sep 21 16:17:03 2015 -0700
@@ -181,7 +181,7 @@
  * Deprecated:2.40: Just use memmove().
  */
 
-#ifndef G_DISABLE_DEPRECATED
+#ifndef GSTREAMER_LITE
 
 #ifdef G_OS_WIN32
 #undef g_atexit
@@ -237,7 +237,7 @@
     }
 }
 
-#endif  /* G_DISABLE_DEPRECATED */
+#endif // GSTREAMER_LITE
 
 /* Based on execvp() from GNU Libc.
  * Some of this code is cut-and-pasted into gspawn.c
@@ -2090,10 +2090,15 @@
  * Flags to modify the format of the string returned by g_format_size_full().
  */
 
+#ifdef GSTREAMER_LITE
 #ifndef G_OS_WIN32 
 #pragma GCC diagnostic push
 #pragma GCC diagnostic ignored "-Wformat-nonliteral"
 #endif // G_OS_WIN32
+#else // GSTREAMER_LITE
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wformat-nonliteral"
+#endif // GSTREAMER_LITE
 
 /**
  * g_format_size_full:
@@ -2228,9 +2233,13 @@
   return g_string_free (string, FALSE);
 }
 
+#ifdef GSTREAMER_LITE
 #ifndef G_OS_WIN32
 #pragma GCC diagnostic pop
 #endif // G_OS_WIN32
+#else // GSTREAMER_LITE
+#pragma GCC diagnostic pop
+#endif // GSTREAMER_LITE
 
 /**
  * g_format_size_for_display:
--- a/modules/media/src/main/native/gstreamer/3rd_party/libffi/src/x86/ffi.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/3rd_party/libffi/src/x86/ffi.c	Mon Sep 21 16:17:03 2015 -0700
@@ -99,13 +99,19 @@
        i != 0;
        i--, p_arg += dir, p_argv += dir)
     {
+#ifdef GSTREAMER_LITE
       size_t z = 0;
+#endif // GSTREAMER_LITE
       
       /* Align if necessary */
       if ((sizeof(void*) - 1) & (size_t) argp)
         argp = (char *) ALIGN(argp, sizeof(void*));
 
+#ifdef GSTREAMER_LITE
       z = (*p_arg)->size;
+#else // GSTREAMER_LITE
+      size_t z = (*p_arg)->size;
+#endif // GSTREAMER_LITE
 
 #ifdef X86_WIN64
       if (z > FFI_SIZEOF_ARG
@@ -204,7 +210,9 @@
      on top of stack, so that those can be moved to registers by call-handler.  */
   if (stack_args_count > 0)
     {
+#ifdef GSTREAMER_LITE
       int i;
+#endif // GSTREAMER_LITE
       if (dir < 0 && stack_args_count > 1)
         {
           /* Reverse order if iterating arguments backwards */
@@ -212,7 +220,10 @@
           *(ffi_arg*) p_stack_data[0] = *(ffi_arg*) p_stack_data[stack_args_count - 1];
           *(ffi_arg*) p_stack_data[stack_args_count - 1] = tmp;
         }
-      
+
+#ifndef GSTREAMER_LITE
+      int i;
+#endif // GSTREAMER_LITE
       for (i = 0; i < stack_args_count; i++)
         {
           if (p_stack_data[i] != argp2)
@@ -570,13 +581,19 @@
   for (i = 0, p_arg = cif->arg_types; 
        i < cif->nargs && passed_regs < max_stack_count;
        i++, p_arg++)
-    {
+  {
+#ifdef GSTREAMER_LITE
       size_t sz = 0;
+#endif // GSTREAMER_LITE
       if ((*p_arg)->type == FFI_TYPE_FLOAT
          || (*p_arg)->type == FFI_TYPE_STRUCT)
         continue;
 
+#ifdef GSTREAMER_LITE
       sz = (*p_arg)->size;
+#else // GSTREAMER_LITE
+      size_t sz = (*p_arg)->size;
+#endif // GSTREAMER_LITE
       if(sz == 0 || sz > FFI_SIZEOF_ARG)
         continue;
 
@@ -602,12 +619,18 @@
        i != 0;
        i--, p_arg += dir, p_argv += dir)
     {
+#ifdef GSTREAMER_LITE
       size_t z = 0;
+#endif // GSTREAMER_LITE
       /* Align if necessary */
       if ((sizeof(void*) - 1) & (size_t) argp)
         argp = (char *) ALIGN(argp, sizeof(void*));
 
+#ifdef GSTREAMER_LITE
       z = (*p_arg)->size;
+#else // GSTREAMER_LITE
+      size_t z = (*p_arg)->size;
+#endif // GSTREAMER_LITE
 
 #ifdef X86_WIN64
       if (z > FFI_SIZEOF_ARG
@@ -859,12 +882,18 @@
   
   for (i = 0; i < cif->nargs && passed_regs <= max_regs; i++)
     {
+#ifdef GSTREAMER_LITE
       size_t sz = 0;
+#endif // GSTREAMER_LITE
       if (cif->arg_types[i]->type == FFI_TYPE_FLOAT
          || cif->arg_types[i]->type == FFI_TYPE_STRUCT)
         continue;
 
+#ifdef GSTREAMER_LITE
       sz = cif->arg_types[i]->size;
+#else // GSTREAMER_LITE
+      size_t sz = cif->arg_types[i]->size;
+#endif // GSTREAMER_LITE
       if (sz == 0 || sz > FFI_SIZEOF_ARG)
         continue;
 
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-bad/COPYING	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-bad/COPYING	Mon Sep 21 16:17:03 2015 -0700
@@ -2,7 +2,7 @@
 		       Version 2, June 1991
 
  Copyright (C) 1989, 1991 Free Software Foundation, Inc.
-                       59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  Everyone is permitted to copy and distribute verbatim copies
  of this license document, but changing it is not allowed.
 
@@ -305,7 +305,7 @@
 
     You should have received a copy of the GNU General Public License
     along with this program; if not, write to the Free Software
-    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 
 
 Also add information on how to contact you by electronic and paper mail.
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/ext/alsa/gstalsaplugin.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/ext/alsa/gstalsaplugin.c	Mon Sep 21 16:17:03 2015 -0700
@@ -24,7 +24,9 @@
 #endif
 
 #include "gstalsasink.h"
+#ifndef GSTREAMER_LITE
 #include "gstalsasrc.h"
+#endif // GSTREAMER_LITE
 
 #include <gst/gst-i18n-plugin.h>
 
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/ext/alsa/gstalsasink.h	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/ext/alsa/gstalsasink.h	Mon Sep 21 16:17:03 2015 -0700
@@ -1,7 +1,7 @@
 /* GStreamer
  * Copyright (C)  2005 Wim Taymans <wim@fluendo.com>
  *
- * gstalsasink.h:
+ * gstalsasink.h: 
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Library General Public
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/ext/alsa/gstalsasrc.c	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,859 +0,0 @@
-/* GStreamer
- * Copyright (C) 2005 Wim Taymans <wim@fluendo.com>
- *
- * gstalsasrc.c:
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
- */
-
-/**
- * SECTION:element-alsasrc
- * @see_also: alsasink, alsamixer
- *
- * This element reads data from an audio card using the ALSA API.
- *
- * <refsect2>
- * <title>Example pipelines</title>
- * |[
- * gst-launch -v alsasrc ! audioconvert ! vorbisenc ! oggmux ! filesink location=alsasrc.ogg
- * ]| Record from a sound card using ALSA and encode to Ogg/Vorbis.
- * </refsect2>
- *
- * Last reviewed on 2006-03-01 (0.10.4)
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-#include <sys/ioctl.h>
-#include <fcntl.h>
-#include <errno.h>
-#include <unistd.h>
-#include <string.h>
-#include <getopt.h>
-#include <alsa/asoundlib.h>
-
-#include "gstalsasrc.h"
-#include "gstalsadeviceprobe.h"
-
-#include <gst/gst-i18n-plugin.h>
-
-#define DEFAULT_PROP_DEVICE		"default"
-#define DEFAULT_PROP_DEVICE_NAME	""
-#define DEFAULT_PROP_CARD_NAME	        ""
-
-enum
-{
-  PROP_0,
-  PROP_DEVICE,
-  PROP_DEVICE_NAME,
-  PROP_CARD_NAME,
-  PROP_LAST
-};
-
-static void gst_alsasrc_init_interfaces (GType type);
-
-GST_BOILERPLATE_FULL (GstAlsaSrc, gst_alsasrc, GstAudioSrc,
-    GST_TYPE_AUDIO_SRC, gst_alsasrc_init_interfaces);
-
-GST_IMPLEMENT_ALSA_MIXER_METHODS (GstAlsaSrc, gst_alsasrc_mixer);
-
-static void gst_alsasrc_finalize (GObject * object);
-static void gst_alsasrc_set_property (GObject * object,
-    guint prop_id, const GValue * value, GParamSpec * pspec);
-static void gst_alsasrc_get_property (GObject * object,
-    guint prop_id, GValue * value, GParamSpec * pspec);
-
-static GstCaps *gst_alsasrc_getcaps (GstBaseSrc * bsrc);
-
-static gboolean gst_alsasrc_open (GstAudioSrc * asrc);
-static gboolean gst_alsasrc_prepare (GstAudioSrc * asrc,
-    GstRingBufferSpec * spec);
-static gboolean gst_alsasrc_unprepare (GstAudioSrc * asrc);
-static gboolean gst_alsasrc_close (GstAudioSrc * asrc);
-static guint gst_alsasrc_read (GstAudioSrc * asrc, gpointer data, guint length);
-static guint gst_alsasrc_delay (GstAudioSrc * asrc);
-static void gst_alsasrc_reset (GstAudioSrc * asrc);
-
-/* AlsaSrc signals and args */
-enum
-{
-  LAST_SIGNAL
-};
-
-#if (G_BYTE_ORDER == G_LITTLE_ENDIAN)
-# define ALSA_SRC_FACTORY_ENDIANNESS   "LITTLE_ENDIAN, BIG_ENDIAN"
-#else
-# define ALSA_SRC_FACTORY_ENDIANNESS   "BIG_ENDIAN, LITTLE_ENDIAN"
-#endif
-
-static GstStaticPadTemplate alsasrc_src_factory =
-    GST_STATIC_PAD_TEMPLATE ("src",
-    GST_PAD_SRC,
-    GST_PAD_ALWAYS,
-    GST_STATIC_CAPS ("audio/x-raw-int, "
-        "endianness = (int) { " ALSA_SRC_FACTORY_ENDIANNESS " }, "
-        "signed = (boolean) { TRUE, FALSE }, "
-        "width = (int) 32, "
-        "depth = (int) 32, "
-        "rate = (int) [ 1, MAX ], " "channels = (int) [ 1, MAX ]; "
-        "audio/x-raw-int, "
-        "endianness = (int) { " ALSA_SRC_FACTORY_ENDIANNESS " }, "
-        "signed = (boolean) { TRUE, FALSE }, "
-        "width = (int) 32, "
-        "depth = (int) 24, "
-        "rate = (int) [ 1, MAX ], " "channels = (int) [ 1, MAX ]; "
-        "audio/x-raw-int, "
-        "endianness = (int) { " ALSA_SRC_FACTORY_ENDIANNESS " }, "
-        "signed = (boolean) { TRUE, FALSE }, "
-        "width = (int) 24, "
-        "depth = (int) 24, "
-        "rate = (int) [ 1, MAX ], " "channels = (int) [ 1, MAX ]; "
-        "audio/x-raw-int, "
-        "endianness = (int) { " ALSA_SRC_FACTORY_ENDIANNESS " }, "
-        "signed = (boolean) { TRUE, FALSE }, "
-        "width = (int) 16, "
-        "depth = (int) 16, "
-        "rate = (int) [ 1, MAX ], " "channels = (int) [ 1, MAX ]; "
-        "audio/x-raw-int, "
-        "signed = (boolean) { TRUE, FALSE }, "
-        "width = (int) 8, "
-        "depth = (int) 8, "
-        "rate = (int) [ 1, MAX ], " "channels = (int) [ 1, MAX ]")
-    );
-
-static void
-gst_alsasrc_finalize (GObject * object)
-{
-  GstAlsaSrc *src = GST_ALSA_SRC (object);
-
-  g_free (src->device);
-  g_mutex_free (src->alsa_lock);
-
-  G_OBJECT_CLASS (parent_class)->finalize (object);
-}
-
-static gboolean
-gst_alsasrc_interface_supported (GstAlsaSrc * this, GType interface_type)
-{
-  /* only support this one interface (wrapped by GstImplementsInterface) */
-  g_assert (interface_type == GST_TYPE_MIXER);
-
-  return gst_alsasrc_mixer_supported (this, interface_type);
-}
-
-static void
-gst_implements_interface_init (GstImplementsInterfaceClass * klass)
-{
-  klass->supported = (gpointer) gst_alsasrc_interface_supported;
-}
-
-static void
-gst_alsasrc_init_interfaces (GType type)
-{
-  static const GInterfaceInfo implements_iface_info = {
-    (GInterfaceInitFunc) gst_implements_interface_init,
-    NULL,
-    NULL,
-  };
-  static const GInterfaceInfo mixer_iface_info = {
-    (GInterfaceInitFunc) gst_alsasrc_mixer_interface_init,
-    NULL,
-    NULL,
-  };
-
-  g_type_add_interface_static (type, GST_TYPE_IMPLEMENTS_INTERFACE,
-      &implements_iface_info);
-  g_type_add_interface_static (type, GST_TYPE_MIXER, &mixer_iface_info);
-
-  gst_alsa_type_add_device_property_probe_interface (type);
-}
-
-static void
-gst_alsasrc_base_init (gpointer g_class)
-{
-  GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
-
-  gst_element_class_set_details_simple (element_class,
-      "Audio source (ALSA)", "Source/Audio",
-      "Read from a sound card via ALSA", "Wim Taymans <wim@fluendo.com>");
-
-  gst_element_class_add_pad_template (element_class,
-      gst_static_pad_template_get (&alsasrc_src_factory));
-}
-
-static void
-gst_alsasrc_class_init (GstAlsaSrcClass * klass)
-{
-  GObjectClass *gobject_class;
-  GstBaseSrcClass *gstbasesrc_class;
-  GstAudioSrcClass *gstaudiosrc_class;
-
-  gobject_class = (GObjectClass *) klass;
-  gstbasesrc_class = (GstBaseSrcClass *) klass;
-  gstaudiosrc_class = (GstAudioSrcClass *) klass;
-
-  gobject_class->finalize = gst_alsasrc_finalize;
-  gobject_class->get_property = gst_alsasrc_get_property;
-  gobject_class->set_property = gst_alsasrc_set_property;
-
-  gstbasesrc_class->get_caps = GST_DEBUG_FUNCPTR (gst_alsasrc_getcaps);
-
-  gstaudiosrc_class->open = GST_DEBUG_FUNCPTR (gst_alsasrc_open);
-  gstaudiosrc_class->prepare = GST_DEBUG_FUNCPTR (gst_alsasrc_prepare);
-  gstaudiosrc_class->unprepare = GST_DEBUG_FUNCPTR (gst_alsasrc_unprepare);
-  gstaudiosrc_class->close = GST_DEBUG_FUNCPTR (gst_alsasrc_close);
-  gstaudiosrc_class->read = GST_DEBUG_FUNCPTR (gst_alsasrc_read);
-  gstaudiosrc_class->delay = GST_DEBUG_FUNCPTR (gst_alsasrc_delay);
-  gstaudiosrc_class->reset = GST_DEBUG_FUNCPTR (gst_alsasrc_reset);
-
-  g_object_class_install_property (gobject_class, PROP_DEVICE,
-      g_param_spec_string ("device", "Device",
-          "ALSA device, as defined in an asound configuration file",
-          DEFAULT_PROP_DEVICE, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
-
-  g_object_class_install_property (gobject_class, PROP_DEVICE_NAME,
-      g_param_spec_string ("device-name", "Device name",
-          "Human-readable name of the sound device",
-          DEFAULT_PROP_DEVICE_NAME, G_PARAM_READABLE | G_PARAM_STATIC_STRINGS));
-
-  g_object_class_install_property (gobject_class, PROP_CARD_NAME,
-      g_param_spec_string ("card-name", "Card name",
-          "Human-readable name of the sound card",
-          DEFAULT_PROP_CARD_NAME, G_PARAM_READABLE | G_PARAM_STATIC_STRINGS));
-}
-
-static void
-gst_alsasrc_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec)
-{
-  GstAlsaSrc *src;
-
-  src = GST_ALSA_SRC (object);
-
-  switch (prop_id) {
-    case PROP_DEVICE:
-      g_free (src->device);
-      src->device = g_value_dup_string (value);
-      if (src->device == NULL) {
-        src->device = g_strdup (DEFAULT_PROP_DEVICE);
-      }
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-static void
-gst_alsasrc_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec)
-{
-  GstAlsaSrc *src;
-
-  src = GST_ALSA_SRC (object);
-
-  switch (prop_id) {
-    case PROP_DEVICE:
-      g_value_set_string (value, src->device);
-      break;
-    case PROP_DEVICE_NAME:
-      g_value_take_string (value,
-          gst_alsa_find_device_name (GST_OBJECT_CAST (src),
-              src->device, src->handle, SND_PCM_STREAM_CAPTURE));
-      break;
-    case PROP_CARD_NAME:
-      g_value_take_string (value,
-          gst_alsa_find_card_name (GST_OBJECT_CAST (src),
-              src->device, SND_PCM_STREAM_CAPTURE));
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-static void
-gst_alsasrc_init (GstAlsaSrc * alsasrc, GstAlsaSrcClass * g_class)
-{
-  GST_DEBUG_OBJECT (alsasrc, "initializing");
-
-  alsasrc->device = g_strdup (DEFAULT_PROP_DEVICE);
-  alsasrc->cached_caps = NULL;
-
-  alsasrc->alsa_lock = g_mutex_new ();
-}
-
-#define CHECK(call, error) \
-G_STMT_START {                  \
-if ((err = call) < 0)           \
-  goto error;                   \
-} G_STMT_END;
-
-
-static GstCaps *
-gst_alsasrc_getcaps (GstBaseSrc * bsrc)
-{
-  GstElementClass *element_class;
-  GstPadTemplate *pad_template;
-  GstAlsaSrc *src;
-  GstCaps *caps;
-
-  src = GST_ALSA_SRC (bsrc);
-
-  if (src->handle == NULL) {
-    GST_DEBUG_OBJECT (src, "device not open, using template caps");
-    return NULL;                /* base class will get template caps for us */
-  }
-
-  if (src->cached_caps) {
-    GST_LOG_OBJECT (src, "Returning cached caps");
-    return gst_caps_ref (src->cached_caps);
-  }
-
-  element_class = GST_ELEMENT_GET_CLASS (src);
-  pad_template = gst_element_class_get_pad_template (element_class, "src");
-  g_return_val_if_fail (pad_template != NULL, NULL);
-
-  caps = gst_alsa_probe_supported_formats (GST_OBJECT (src), src->handle,
-      gst_pad_template_get_caps (pad_template));
-
-  if (caps) {
-    src->cached_caps = gst_caps_ref (caps);
-  }
-
-  GST_INFO_OBJECT (src, "returning caps %" GST_PTR_FORMAT, caps);
-
-  return caps;
-}
-
-static int
-set_hwparams (GstAlsaSrc * alsa)
-{
-  guint rrate;
-  gint err;
-  snd_pcm_hw_params_t *params;
-
-  snd_pcm_hw_params_malloc (&params);
-
-  /* choose all parameters */
-  CHECK (snd_pcm_hw_params_any (alsa->handle, params), no_config);
-  /* set the interleaved read/write format */
-  CHECK (snd_pcm_hw_params_set_access (alsa->handle, params, alsa->access),
-      wrong_access);
-  /* set the sample format */
-  CHECK (snd_pcm_hw_params_set_format (alsa->handle, params, alsa->format),
-      no_sample_format);
-  /* set the count of channels */
-  CHECK (snd_pcm_hw_params_set_channels (alsa->handle, params, alsa->channels),
-      no_channels);
-  /* set the stream rate */
-  rrate = alsa->rate;
-  CHECK (snd_pcm_hw_params_set_rate_near (alsa->handle, params, &rrate, NULL),
-      no_rate);
-  if (rrate != alsa->rate)
-    goto rate_match;
-
-  if (alsa->buffer_time != -1) {
-    /* set the buffer time */
-    CHECK (snd_pcm_hw_params_set_buffer_time_near (alsa->handle, params,
-            &alsa->buffer_time, NULL), buffer_time);
-  }
-  if (alsa->period_time != -1) {
-    /* set the period time */
-    CHECK (snd_pcm_hw_params_set_period_time_near (alsa->handle, params,
-            &alsa->period_time, NULL), period_time);
-  }
-
-  /* write the parameters to device */
-  CHECK (snd_pcm_hw_params (alsa->handle, params), set_hw_params);
-
-  CHECK (snd_pcm_hw_params_get_buffer_size (params, &alsa->buffer_size),
-      buffer_size);
-
-  CHECK (snd_pcm_hw_params_get_period_size (params, &alsa->period_size, NULL),
-      period_size);
-
-  snd_pcm_hw_params_free (params);
-  return 0;
-
-  /* ERRORS */
-no_config:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Broken configuration for recording: no configurations available: %s",
-            snd_strerror (err)));
-    snd_pcm_hw_params_free (params);
-    return err;
-  }
-wrong_access:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Access type not available for recording: %s", snd_strerror (err)));
-    snd_pcm_hw_params_free (params);
-    return err;
-  }
-no_sample_format:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Sample format not available for recording: %s", snd_strerror (err)));
-    snd_pcm_hw_params_free (params);
-    return err;
-  }
-no_channels:
-  {
-    gchar *msg = NULL;
-
-    if ((alsa->channels) == 1)
-      msg = g_strdup (_("Could not open device for recording in mono mode."));
-    if ((alsa->channels) == 2)
-      msg = g_strdup (_("Could not open device for recording in stereo mode."));
-    if ((alsa->channels) > 2)
-      msg =
-          g_strdup_printf (_
-          ("Could not open device for recording in %d-channel mode"),
-          alsa->channels);
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, ("%s", msg),
-        ("%s", snd_strerror (err)));
-    g_free (msg);
-    snd_pcm_hw_params_free (params);
-    return err;
-  }
-no_rate:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Rate %iHz not available for recording: %s",
-            alsa->rate, snd_strerror (err)));
-    snd_pcm_hw_params_free (params);
-    return err;
-  }
-rate_match:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Rate doesn't match (requested %iHz, get %iHz)", alsa->rate, err));
-    snd_pcm_hw_params_free (params);
-    return -EINVAL;
-  }
-buffer_time:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Unable to set buffer time %i for recording: %s",
-            alsa->buffer_time, snd_strerror (err)));
-    snd_pcm_hw_params_free (params);
-    return err;
-  }
-buffer_size:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Unable to get buffer size for recording: %s", snd_strerror (err)));
-    snd_pcm_hw_params_free (params);
-    return err;
-  }
-period_time:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Unable to set period time %i for recording: %s", alsa->period_time,
-            snd_strerror (err)));
-    snd_pcm_hw_params_free (params);
-    return err;
-  }
-period_size:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Unable to get period size for recording: %s", snd_strerror (err)));
-    snd_pcm_hw_params_free (params);
-    return err;
-  }
-set_hw_params:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Unable to set hw params for recording: %s", snd_strerror (err)));
-    snd_pcm_hw_params_free (params);
-    return err;
-  }
-}
-
-static int
-set_swparams (GstAlsaSrc * alsa)
-{
-  int err;
-  snd_pcm_sw_params_t *params;
-
-  snd_pcm_sw_params_malloc (&params);
-
-  /* get the current swparams */
-  CHECK (snd_pcm_sw_params_current (alsa->handle, params), no_config);
-  /* allow the transfer when at least period_size samples can be processed */
-  CHECK (snd_pcm_sw_params_set_avail_min (alsa->handle, params,
-          alsa->period_size), set_avail);
-  /* start the transfer on first read */
-  CHECK (snd_pcm_sw_params_set_start_threshold (alsa->handle, params,
-          0), start_threshold);
-
-#if GST_CHECK_ALSA_VERSION(1,0,16)
-  /* snd_pcm_sw_params_set_xfer_align() is deprecated, alignment is always 1 */
-#else
-  /* align all transfers to 1 sample */
-  CHECK (snd_pcm_sw_params_set_xfer_align (alsa->handle, params, 1), set_align);
-#endif
-
-  /* write the parameters to the recording device */
-  CHECK (snd_pcm_sw_params (alsa->handle, params), set_sw_params);
-
-  snd_pcm_sw_params_free (params);
-  return 0;
-
-  /* ERRORS */
-no_config:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Unable to determine current swparams for playback: %s",
-            snd_strerror (err)));
-    snd_pcm_sw_params_free (params);
-    return err;
-  }
-start_threshold:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Unable to set start threshold mode for playback: %s",
-            snd_strerror (err)));
-    snd_pcm_sw_params_free (params);
-    return err;
-  }
-set_avail:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Unable to set avail min for playback: %s", snd_strerror (err)));
-    snd_pcm_sw_params_free (params);
-    return err;
-  }
-#if !GST_CHECK_ALSA_VERSION(1,0,16)
-set_align:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Unable to set transfer align for playback: %s", snd_strerror (err)));
-    snd_pcm_sw_params_free (params);
-    return err;
-  }
-#endif
-set_sw_params:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Unable to set sw params for playback: %s", snd_strerror (err)));
-    snd_pcm_sw_params_free (params);
-    return err;
-  }
-}
-
-static gboolean
-alsasrc_parse_spec (GstAlsaSrc * alsa, GstRingBufferSpec * spec)
-{
-  switch (spec->type) {
-    case GST_BUFTYPE_LINEAR:
-      alsa->format = snd_pcm_build_linear_format (spec->depth, spec->width,
-          spec->sign ? 0 : 1, spec->bigend ? 1 : 0);
-      break;
-    case GST_BUFTYPE_FLOAT:
-      switch (spec->format) {
-        case GST_FLOAT32_LE:
-          alsa->format = SND_PCM_FORMAT_FLOAT_LE;
-          break;
-        case GST_FLOAT32_BE:
-          alsa->format = SND_PCM_FORMAT_FLOAT_BE;
-          break;
-        case GST_FLOAT64_LE:
-          alsa->format = SND_PCM_FORMAT_FLOAT64_LE;
-          break;
-        case GST_FLOAT64_BE:
-          alsa->format = SND_PCM_FORMAT_FLOAT64_BE;
-          break;
-        default:
-          goto error;
-      }
-      break;
-    case GST_BUFTYPE_A_LAW:
-      alsa->format = SND_PCM_FORMAT_A_LAW;
-      break;
-    case GST_BUFTYPE_MU_LAW:
-      alsa->format = SND_PCM_FORMAT_MU_LAW;
-      break;
-    default:
-      goto error;
-
-  }
-  alsa->rate = spec->rate;
-  alsa->channels = spec->channels;
-  alsa->buffer_time = spec->buffer_time;
-  alsa->period_time = spec->latency_time;
-  alsa->access = SND_PCM_ACCESS_RW_INTERLEAVED;
-
-  return TRUE;
-
-  /* ERRORS */
-error:
-  {
-    return FALSE;
-  }
-}
-
-static gboolean
-gst_alsasrc_open (GstAudioSrc * asrc)
-{
-  GstAlsaSrc *alsa;
-  gint err;
-
-  alsa = GST_ALSA_SRC (asrc);
-
-  CHECK (snd_pcm_open (&alsa->handle, alsa->device, SND_PCM_STREAM_CAPTURE,
-          SND_PCM_NONBLOCK), open_error);
-
-  if (!alsa->mixer)
-    alsa->mixer = gst_alsa_mixer_new (alsa->device, GST_ALSA_MIXER_CAPTURE);
-
-  return TRUE;
-
-  /* ERRORS */
-open_error:
-  {
-    if (err == -EBUSY) {
-      GST_ELEMENT_ERROR (alsa, RESOURCE, BUSY,
-          (_("Could not open audio device for recording. "
-                  "Device is being used by another application.")),
-          ("Device '%s' is busy", alsa->device));
-    } else {
-      GST_ELEMENT_ERROR (alsa, RESOURCE, OPEN_READ,
-          (_("Could not open audio device for recording.")),
-          ("Recording open error on device '%s': %s", alsa->device,
-              snd_strerror (err)));
-    }
-    return FALSE;
-  }
-}
-
-static gboolean
-gst_alsasrc_prepare (GstAudioSrc * asrc, GstRingBufferSpec * spec)
-{
-  GstAlsaSrc *alsa;
-  gint err;
-
-  alsa = GST_ALSA_SRC (asrc);
-
-  if (!alsasrc_parse_spec (alsa, spec))
-    goto spec_parse;
-
-  CHECK (snd_pcm_nonblock (alsa->handle, 0), non_block);
-
-  CHECK (set_hwparams (alsa), hw_params_failed);
-  CHECK (set_swparams (alsa), sw_params_failed);
-  CHECK (snd_pcm_prepare (alsa->handle), prepare_failed);
-
-  alsa->bytes_per_sample = spec->bytes_per_sample;
-  spec->segsize = alsa->period_size * spec->bytes_per_sample;
-  spec->segtotal = alsa->buffer_size / alsa->period_size;
-  spec->silence_sample[0] = 0;
-  spec->silence_sample[1] = 0;
-  spec->silence_sample[2] = 0;
-  spec->silence_sample[3] = 0;
-
-  return TRUE;
-
-  /* ERRORS */
-spec_parse:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Error parsing spec"));
-    return FALSE;
-  }
-non_block:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Could not set device to blocking: %s", snd_strerror (err)));
-    return FALSE;
-  }
-hw_params_failed:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Setting of hwparams failed: %s", snd_strerror (err)));
-    return FALSE;
-  }
-sw_params_failed:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Setting of swparams failed: %s", snd_strerror (err)));
-    return FALSE;
-  }
-prepare_failed:
-  {
-    GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
-        ("Prepare failed: %s", snd_strerror (err)));
-    return FALSE;
-  }
-}
-
-static gboolean
-gst_alsasrc_unprepare (GstAudioSrc * asrc)
-{
-  GstAlsaSrc *alsa;
-
-  alsa = GST_ALSA_SRC (asrc);
-
-  snd_pcm_drop (alsa->handle);
-  snd_pcm_hw_free (alsa->handle);
-  snd_pcm_nonblock (alsa->handle, 1);
-
-  return TRUE;
-}
-
-static gboolean
-gst_alsasrc_close (GstAudioSrc * asrc)
-{
-  GstAlsaSrc *alsa = GST_ALSA_SRC (asrc);
-
-  snd_pcm_close (alsa->handle);
-  alsa->handle = NULL;
-
-  if (alsa->mixer) {
-    gst_alsa_mixer_free (alsa->mixer);
-    alsa->mixer = NULL;
-  }
-
-  gst_caps_replace (&alsa->cached_caps, NULL);
-
-  return TRUE;
-}
-
-/*
- *   Underrun and suspend recovery
- */
-static gint
-xrun_recovery (GstAlsaSrc * alsa, snd_pcm_t * handle, gint err)
-{
-  GST_DEBUG_OBJECT (alsa, "xrun recovery %d", err);
-
-  if (err == -EPIPE) {          /* under-run */
-    err = snd_pcm_prepare (handle);
-    if (err < 0)
-      GST_WARNING_OBJECT (alsa,
-          "Can't recovery from underrun, prepare failed: %s",
-          snd_strerror (err));
-    return 0;
-  } else if (err == -ESTRPIPE) {
-    while ((err = snd_pcm_resume (handle)) == -EAGAIN)
-      g_usleep (100);           /* wait until the suspend flag is released */
-
-    if (err < 0) {
-      err = snd_pcm_prepare (handle);
-      if (err < 0)
-        GST_WARNING_OBJECT (alsa,
-            "Can't recovery from suspend, prepare failed: %s",
-            snd_strerror (err));
-    }
-    return 0;
-  }
-  return err;
-}
-
-static guint
-gst_alsasrc_read (GstAudioSrc * asrc, gpointer data, guint length)
-{
-  GstAlsaSrc *alsa;
-  gint err;
-  gint cptr;
-  gint16 *ptr;
-
-  alsa = GST_ALSA_SRC (asrc);
-
-  cptr = length / alsa->bytes_per_sample;
-  ptr = data;
-
-  GST_ALSA_SRC_LOCK (asrc);
-  while (cptr > 0) {
-    if ((err = snd_pcm_readi (alsa->handle, ptr, cptr)) < 0) {
-      if (err == -EAGAIN) {
-        GST_DEBUG_OBJECT (asrc, "Read error: %s", snd_strerror (err));
-        continue;
-      } else if (xrun_recovery (alsa, alsa->handle, err) < 0) {
-        goto read_error;
-      }
-      continue;
-    }
-
-    ptr += err * alsa->channels;
-    cptr -= err;
-  }
-  GST_ALSA_SRC_UNLOCK (asrc);
-
-  return length - (cptr * alsa->bytes_per_sample);
-
-read_error:
-  {
-    GST_ALSA_SRC_UNLOCK (asrc);
-    return length;              /* skip one period */
-  }
-}
-
-static guint
-gst_alsasrc_delay (GstAudioSrc * asrc)
-{
-  GstAlsaSrc *alsa;
-  snd_pcm_sframes_t delay;
-  int res;
-
-  alsa = GST_ALSA_SRC (asrc);
-
-  res = snd_pcm_delay (alsa->handle, &delay);
-  if (G_UNLIKELY (res < 0)) {
-    GST_DEBUG_OBJECT (alsa, "snd_pcm_delay returned %d", res);
-    delay = 0;
-  }
-
-  return CLAMP (delay, 0, alsa->buffer_size);
-}
-
-static void
-gst_alsasrc_reset (GstAudioSrc * asrc)
-{
-  GstAlsaSrc *alsa;
-  gint err;
-
-  alsa = GST_ALSA_SRC (asrc);
-
-  GST_ALSA_SRC_LOCK (asrc);
-  GST_DEBUG_OBJECT (alsa, "drop");
-  CHECK (snd_pcm_drop (alsa->handle), drop_error);
-  GST_DEBUG_OBJECT (alsa, "prepare");
-  CHECK (snd_pcm_prepare (alsa->handle), prepare_error);
-  GST_DEBUG_OBJECT (alsa, "reset done");
-  GST_ALSA_SRC_UNLOCK (asrc);
-
-  return;
-
-  /* ERRORS */
-drop_error:
-  {
-    GST_ERROR_OBJECT (alsa, "alsa-reset: pcm drop error: %s",
-        snd_strerror (err));
-    GST_ALSA_SRC_UNLOCK (asrc);
-    return;
-  }
-prepare_error:
-  {
-    GST_ERROR_OBJECT (alsa, "alsa-reset: pcm prepare error: %s",
-        snd_strerror (err));
-    GST_ALSA_SRC_UNLOCK (asrc);
-    return;
-  }
-}
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/ext/alsa/gstalsasrc.h	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,84 +0,0 @@
-/* GStreamer
- * Copyright (C)  2005 Wim Taymans <wim@fluendo.com>
- *
- * gstalsasrc.h:
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-
-#ifndef __GST_ALSASRC_H__
-#define __GST_ALSASRC_H__
-
-#include <gst/audio/audio.h>
-#include "gstalsa.h"
-
-G_BEGIN_DECLS
-
-#define GST_TYPE_ALSA_SRC            (gst_alsasrc_get_type())
-#define GST_ALSA_SRC(obj)            (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_ALSA_SRC,GstAlsaSrc))
-#define GST_ALSA_SRC_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_ALSA_SRC,GstAlsaSrcClass))
-#define GST_IS_ALSA_SRC(obj)         (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_ALSA_SRC))
-#define GST_IS_ALSA_SRC_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_ALSA_SRC))
-#define GST_ALSA_SRC_CAST(obj)       ((GstAlsaSrc *)(obj))
-
-#define GST_ALSA_SRC_GET_LOCK(obj)  (&GST_ALSA_SRC_CAST (obj)->alsa_lock)
-#define GST_ALSA_SRC_LOCK(obj)      (g_mutex_lock (GST_ALSA_SRC_GET_LOCK (obj)))
-#define GST_ALSA_SRC_UNLOCK(obj)    (g_mutex_unlock (GST_ALSA_SRC_GET_LOCK (obj)))
-
-typedef struct _GstAlsaSrc GstAlsaSrc;
-typedef struct _GstAlsaSrcClass GstAlsaSrcClass;
-
-/**
- * GstAlsaSrc:
- *
- * Opaque data structure
- */
-struct _GstAlsaSrc {
-  GstAudioSrc           src;
-
-  gchar                 *device;
-
-  snd_pcm_t             *handle;
-  snd_pcm_hw_params_t   *hwparams;
-  snd_pcm_sw_params_t   *swparams;
-
-  GstCaps               *cached_caps;
-
-  snd_pcm_access_t      access;
-  snd_pcm_format_t      format;
-  guint                 rate;
-  guint                 channels;
-  gint                  bpf;
-  gboolean              driver_timestamps;
-
-  guint                 buffer_time;
-  guint                 period_time;
-  snd_pcm_uframes_t     buffer_size;
-  snd_pcm_uframes_t     period_size;
-
-  GMutex                alsa_lock;
-};
-
-struct _GstAlsaSrcClass {
-  GstAudioSrcClass parent_class;
-};
-
-GType gst_alsasrc_get_type(void);
-
-G_END_DECLS
-
-#endif /* __GST_ALSASRC_H__ */
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/audio/gstaudiobasesink.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/audio/gstaudiobasesink.c	Mon Sep 21 16:17:03 2015 -0700
@@ -322,7 +322,7 @@
     GST_OBJECT_FLAG_SET (basesink, GST_ELEMENT_FLAG_PROVIDE_CLOCK);
   else
     GST_OBJECT_FLAG_UNSET (basesink, GST_ELEMENT_FLAG_PROVIDE_CLOCK);
-      }
+}
 
 static void
 gst_audio_base_sink_dispose (GObject * object)
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/audio/gstaudioringbuffer.h	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/audio/gstaudioringbuffer.h	Mon Sep 21 16:17:03 2015 -0700
@@ -262,15 +262,15 @@
 /* callback stuff */
 void            gst_audio_ring_buffer_set_callback    (GstAudioRingBuffer *buf,
                                                        GstAudioRingBufferCallback cb,
-                                                 gpointer user_data);
+                                                       gpointer user_data);
 
 gboolean        gst_audio_ring_buffer_parse_caps      (GstAudioRingBufferSpec *spec, GstCaps *caps);
 void            gst_audio_ring_buffer_debug_spec_caps (GstAudioRingBufferSpec *spec);
 void            gst_audio_ring_buffer_debug_spec_buff (GstAudioRingBufferSpec *spec);
 
 gboolean        gst_audio_ring_buffer_convert         (GstAudioRingBuffer * buf, GstFormat src_fmt,
-                                                 gint64 src_val, GstFormat dest_fmt,
-						 gint64 * dest_val);
+                                                       gint64 src_val, GstFormat dest_fmt,
+                                                       gint64 * dest_val);
 
 /* device state */
 gboolean        gst_audio_ring_buffer_open_device     (GstAudioRingBuffer *buf);
@@ -312,14 +312,14 @@
 /* commit samples */
 guint           gst_audio_ring_buffer_commit          (GstAudioRingBuffer * buf, guint64 *sample,
                                                        guint8 * data, gint in_samples,
-						 gint out_samples, gint * accum);
+                                                       gint out_samples, gint * accum);
 
 /* read samples */
 guint           gst_audio_ring_buffer_read            (GstAudioRingBuffer *buf, guint64 sample,
                                                        guint8 *data, guint len, GstClockTime *timestamp);
 
 /* Set timestamp on buffer */
-void            gst_audio_ring_buffer_set_timestamp   (GstAudioRingBuffer * buf, gint readseg, GstClockTime
+void            gst_audio_ring_buffer_set_timestamp   (GstAudioRingBuffer * buf, gint readseg, GstClockTime 
                                                        timestamp);
 
 /* mostly protected */
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/pbutils/gstdiscoverer.h	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/pbutils/gstdiscoverer.h	Mon Sep 21 16:17:03 2015 -0700
@@ -202,7 +202,7 @@
 GstClockTime              gst_discoverer_info_get_duration(const GstDiscovererInfo* info);
 gboolean                  gst_discoverer_info_get_seekable(const GstDiscovererInfo* info);
 const GstStructure*       gst_discoverer_info_get_misc(const GstDiscovererInfo* info);
-const GstTagList*         gst_discoverer_info_get_tags(const GstDiscovererInfo* info);
+const GstTagList*         gst_discoverer_info_get_tags(const GstDiscovererInfo* info); 
 const GstToc*             gst_discoverer_info_get_toc(const GstDiscovererInfo* info);
 const gchar**             gst_discoverer_info_get_missing_elements_installer_details(const GstDiscovererInfo* info);
 
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/riff/riff-ids.h	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/riff/riff-ids.h	Mon Sep 21 16:17:03 2015 -0700
@@ -324,7 +324,7 @@
 #define GST_RIFF_WAVE_FORMAT_DOLBY_AC2      (0x0030)
 #define GST_RIFF_WAVE_FORMAT_GSM610         (0x0031)
 #define GST_RIFF_WAVE_FORMAT_MSN            (0x0032)
-#define GST_RIFF_WAVE_FORMAT_ANTEX_ADPCME   (0x0033
+#define GST_RIFF_WAVE_FORMAT_ANTEX_ADPCME   (0x0033 
 #define GST_RIFF_WAVE_FORMAT_CONTROL_RES_VQLPC (0x0034)
 #define GST_RIFF_WAVE_FORMAT_DIGIREAL       (0x0035)
 #define GST_RIFF_WAVE_FORMAT_DIGIADPCM      (0x0036)
@@ -466,7 +466,7 @@
 #endif
 } gst_riff_strf_auds;
 
-typedef struct _gst_riff_strf_iavs {
+typedef struct _gst_riff_strf_iavs {    
   guint32 DVAAuxSrc;
   guint32 DVAAuxCtl;
   guint32 DVAAuxSrc1;
@@ -477,7 +477,7 @@
   guint32 DVReserved2;
 } gst_riff_strf_iavs;
 
-typedef struct _gst_riff_index_entry {
+typedef struct _gst_riff_index_entry {  
   guint32 id;
   guint32 flags;
 #define GST_RIFF_IF_LIST                (0x00000001L)
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/tag/gsttagdemux.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/tag/gsttagdemux.c	Mon Sep 21 16:17:03 2015 -0700
@@ -947,7 +947,7 @@
 
 static gboolean
 gst_tag_demux_seek_push (GstTagDemux * tagdemux, GstEvent * event)
-    {
+{
   gboolean res = FALSE;
       gdouble rate;
       GstFormat format;
@@ -1589,7 +1589,7 @@
   if (!gst_pad_peer_query (sinkpad, query)) {
     gst_query_unref (query);
     goto activate_push;
-}
+  }
 
   pull_mode = gst_query_has_scheduling_mode_with_flags (query,
       GST_PAD_MODE_PULL, GST_SCHEDULING_FLAG_SEEKABLE);
@@ -1630,7 +1630,7 @@
     default:
       res = TRUE;
       break;
-}
+  }
   return res;
 }
 
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/tag/gsttageditingprivate.h	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/tag/gsttageditingprivate.h	Mon Sep 21 16:17:03 2015 -0700
@@ -24,7 +24,7 @@
 #include <gst/tag/tag.h>
 
 G_BEGIN_DECLS
-
+  
 
 typedef struct _GstTagEntryMatch GstTagEntryMatch;
 struct _GstTagEntryMatch {
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/video/gstvideosink.h	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/video/gstvideosink.h	Mon Sep 21 16:17:03 2015 -0700
@@ -105,7 +105,7 @@
  * @parent_class: the parent class structure
  * @show_frame: render a video frame. Maps to #GstBaseSinkClass.render() and
  *     #GstBaseSinkClass.preroll() vfuncs. Rendering during preroll will be
- *     suppressed if the #GstVideoSink:show-preroll-frame property is set to
+ *     suppressed if the #GstVideoSink:show-preroll-frame property is set to 
  *     %FALSE.
  *
  * The video sink class structure. Derived classes should override the
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/video/video.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst-libs/gst/video/video.c	Mon Sep 21 16:17:03 2015 -0700
@@ -99,7 +99,7 @@
 
   /* ERRORS */
 error_overflow:
-{
+  {
     GST_WARNING ("overflow in multiply");
     return FALSE;
   }
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/typefind/gsttypefindfunctions.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/typefind/gsttypefindfunctions.c	Mon Sep 21 16:17:03 2015 -0700
@@ -1912,7 +1912,7 @@
   if (data != NULL && memcmp (data, "wvpk", 4) == 0) {
     GST_DEBUG ("found second block sync");
     base_prob = GST_TYPE_FIND_LIKELY;
-}
+  }
 
   GST_DEBUG ("wvc=%d, wv=%d", count_wvc, count_wv);
 
@@ -2765,11 +2765,11 @@
 
       if (seen_sps && seen_pps && seen_irap && good >= 10 && bad < 4) {
         gst_type_find_suggest (tf, GST_TYPE_FIND_LIKELY, H265_VIDEO_CAPS);
-    return;
-  }
+        return;
+      }
 
       data_scan_ctx_advance (tf, &c, 5);
-}
+    }
     data_scan_ctx_advance (tf, &c, 1);
   }
 
@@ -3509,9 +3509,9 @@
         mod_type = "stm";
         probability = GST_TYPE_FIND_MAXIMUM;
         goto suggest_audio_mod_caps;
+      }
     }
   }
-}
   /* AMF */
   if ((data = gst_type_find_peek (tf, 0, 19)) != NULL) {
     if (memcmp (data, "ASYLUM Music Format", 19) == 0) {
@@ -4158,7 +4158,7 @@
         else
           ++info->other;
         break;
-}
+      }
       case MATROSKA_STEREO_MODE:
         ++info->video_stereo;
         break;
@@ -4210,7 +4210,7 @@
     GST_INFO ("=== done with chunk %08x", id);
     if (id == MATROSKA_SEGMENT)
       break;
-}
+  }
 
   GST_INFO ("audio=%u video=%u other=%u chunks=%u doctype=%d all_tracks=%d",
       info.audio, info.video, info.other, info.chunks, info.doctype,
@@ -4227,7 +4227,7 @@
     type_name = "video/x-matroska-3d";
   } else {
     type_name = (is_audio) ? "audio/x-matroska" : "video/x-matroska";
-}
+  }
 
   if (info.doctype == EBML_DOCTYPE_UNKNOWN)
     prob = GST_TYPE_FIND_LIKELY;
@@ -4399,8 +4399,8 @@
       if (memcmp (c.data, markers[i].marker, markers[i].marker_size) == 0) {
         ++hdr_count[markers[i].stream_type];
         break;
-  }
-}
+      }
+    }
 
     if (i == G_N_ELEMENTS (markers)) {
       GST_MEMDUMP ("unknown Ogg stream marker", c.data, size);
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolume.h	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolume.h	Mon Sep 21 16:17:03 2015 -0700
@@ -67,7 +67,7 @@
   gint   current_vol_i24; /* the _i(nt) values get synchronized with the */
   gint   current_vol_i16; /* the _i(nt) values get synchronized with the */
   gint   current_vol_i8;   /* the _i(nt) values get synchronized with the */
-
+  
   GList *tracklist;
   gboolean negotiated;
 
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolumeorc-dist.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolumeorc-dist.c	Mon Sep 21 16:17:03 2015 -0700
@@ -79,10 +79,24 @@
 #endif
 #endif
 
+#ifndef ORC_INTERNAL
+#if defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590)
+#define ORC_INTERNAL __attribute__((visibility("hidden")))
+#elif defined(__SUNPRO_C) && (__SUNPRO_C >= 0x550)
+#define ORC_INTERNAL __hidden
+#elif defined (__GNUC__)
+#define ORC_INTERNAL __attribute__((visibility("hidden")))
+#else
+#define ORC_INTERNAL
+#endif
+#endif
+
+
 #ifndef DISABLE_ORC
 #include <orc/orc.h>
 #endif
-void volume_orc_scalarmultiply_f64_ns (double *ORC_RESTRICT d1, double p1, int n);
+void volume_orc_scalarmultiply_f64_ns (double *ORC_RESTRICT d1, double p1,
+    int n);
 void volume_orc_scalarmultiply_f32_ns (float *ORC_RESTRICT d1, float p1, int n);
 void volume_orc_process_int32 (gint32 * ORC_RESTRICT d1, int p1, int n);
 void volume_orc_process_int32_clamp (gint32 * ORC_RESTRICT d1, int p1, int n);
@@ -110,8 +124,6 @@
 void volume_orc_process_controlled_int8_2ch (gint8 * ORC_RESTRICT d1,
     const gdouble * ORC_RESTRICT s1, int n);
 
-void gst_volume_orc_init (void);
-
 
 /* begin Orc C target preamble */
 #define ORC_CLAMP(x,a,b) ((x)<(a) ? (a) : ((x)>(b) ? (b) : (x)))
@@ -136,8 +148,8 @@
 #define ORC_CLAMP_UW(x) ORC_CLAMP(x,ORC_UW_MIN,ORC_UW_MAX)
 #define ORC_CLAMP_SL(x) ORC_CLAMP(x,ORC_SL_MIN,ORC_SL_MAX)
 #define ORC_CLAMP_UL(x) ORC_CLAMP(x,ORC_UL_MIN,ORC_UL_MAX)
-#define ORC_SWAP_W(x) ((((x)&0xff)<<8) | (((x)&0xff00)>>8))
-#define ORC_SWAP_L(x) ((((x)&0xff)<<24) | (((x)&0xff00)<<8) | (((x)&0xff0000)>>8) | (((x)&0xff000000)>>24))
+#define ORC_SWAP_W(x) ((((x)&0xffU)<<8) | (((x)&0xff00U)>>8))
+#define ORC_SWAP_L(x) ((((x)&0xffU)<<24) | (((x)&0xff00U)<<8) | (((x)&0xff0000U)>>8) | (((x)&0xff000000U)>>24))
 #define ORC_SWAP_Q(x) ((((x)&ORC_UINT64_C(0xff))<<56) | (((x)&ORC_UINT64_C(0xff00))<<40) | (((x)&ORC_UINT64_C(0xff0000))<<24) | (((x)&ORC_UINT64_C(0xff000000))<<8) | (((x)&ORC_UINT64_C(0xff00000000))>>8) | (((x)&ORC_UINT64_C(0xff0000000000))>>24) | (((x)&ORC_UINT64_C(0xff000000000000))>>40) | (((x)&ORC_UINT64_C(0xff00000000000000))>>56))
 #define ORC_PTR_OFFSET(ptr,offset) ((void *)(((unsigned char *)(ptr)) + (offset)))
 #define ORC_DENORMAL(x) ((x) & ((((x)&0x7f800000) == 0) ? 0xff800000 : 0xffffffff))
@@ -194,7 +206,7 @@
 
 #else
 static void
-_backup_orc_scalarmultiply_f64_ns (OrcExecutor * ORC_RESTRICT ex)
+_backup_volume_orc_scalarmultiply_f64_ns (OrcExecutor * ORC_RESTRICT ex)
 {
   int i;
   int n = ex->n;
@@ -229,15 +241,50 @@
 
 }
 
-static OrcProgram *_orc_program_orc_scalarmultiply_f64_ns;
 void
 volume_orc_scalarmultiply_f64_ns (double *ORC_RESTRICT d1, double p1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_orc_scalarmultiply_f64_ns;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 32, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 115, 99,
+        97, 108, 97, 114, 109, 117, 108, 116, 105, 112, 108, 121, 95, 102, 54,
+            52,
+        95, 110, 115, 11, 8, 8, 18, 8, 214, 0, 0, 24, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_scalarmultiply_f64_ns);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_scalarmultiply_f64_ns");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_scalarmultiply_f64_ns);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_parameter_double (p, 8, "p1");
+
+      orc_program_append_2 (p, "muld", 0, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_P1,
+          ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
@@ -248,7 +295,7 @@
     ex->params[ORC_VAR_T1] = tmp.x2[1];
   }
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -291,7 +338,7 @@
 
 #else
 static void
-_backup_orc_scalarmultiply_f32_ns (OrcExecutor * ORC_RESTRICT ex)
+_backup_volume_orc_scalarmultiply_f32_ns (OrcExecutor * ORC_RESTRICT ex)
 {
   int i;
   int n = ex->n;
@@ -324,15 +371,50 @@
 
 }
 
-static OrcProgram *_orc_program_orc_scalarmultiply_f32_ns;
 void
 volume_orc_scalarmultiply_f32_ns (float *ORC_RESTRICT d1, float p1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_orc_scalarmultiply_f32_ns;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 32, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 115, 99,
+        97, 108, 97, 114, 109, 117, 108, 116, 105, 112, 108, 121, 95, 102, 51,
+            50,
+        95, 110, 115, 11, 4, 4, 17, 4, 202, 0, 0, 24, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_scalarmultiply_f32_ns);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_scalarmultiply_f32_ns");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_scalarmultiply_f32_ns);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_parameter_float (p, 4, "p1");
+
+      orc_program_append_2 (p, "mulf", 0, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_P1,
+          ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
@@ -342,7 +424,7 @@
     ex->params[ORC_VAR_P1] = tmp.i;
   }
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -414,21 +496,60 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_int32;
 void
 volume_orc_process_int32 (gint32 * ORC_RESTRICT d1, int p1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_int32;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 24, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 105, 110, 116, 51, 50, 11, 4, 4, 14, 4,
+        27, 0, 0, 0, 16, 4, 20, 8, 178, 32, 0, 24, 147, 32, 32, 16,
+        169, 0, 32, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p, _backup_volume_orc_process_int32);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_int32");
+      orc_program_set_backup_function (p, _backup_volume_orc_process_int32);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_constant (p, 4, 0x0000001b, "c1");
+      orc_program_add_parameter (p, 4, "p1");
+      orc_program_add_temporary (p, 8, "t1");
+
+      orc_program_append_2 (p, "mulslq", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "shrsq", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convql", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->params[ORC_VAR_P1] = p1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -500,21 +621,62 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_int32_clamp;
 void
 volume_orc_process_int32_clamp (gint32 * ORC_RESTRICT d1, int p1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_int32_clamp;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 30, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 105, 110, 116, 51, 50, 95, 99, 108, 97, 109,
+        112, 11, 4, 4, 14, 4, 27, 0, 0, 0, 16, 4, 20, 8, 178, 32,
+        0, 24, 147, 32, 32, 16, 170, 0, 32, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_int32_clamp);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_int32_clamp");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_int32_clamp);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_constant (p, 4, 0x0000001b, "c1");
+      orc_program_add_parameter (p, 4, "p1");
+      orc_program_add_temporary (p, 8, "t1");
+
+      orc_program_append_2 (p, "mulslq", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "shrsq", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convsssql", 0, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->params[ORC_VAR_P1] = p1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -544,7 +706,7 @@
     /* 2: mulswl */
     var36.i = var33.i * var34.i;
     /* 3: shrsl */
-    var37.i = var36.i >> 13;
+    var37.i = var36.i >> 11;
     /* 4: convlw */
     var35.i = var37.i;
     /* 5: storew */
@@ -577,7 +739,7 @@
     /* 2: mulswl */
     var36.i = var33.i * var34.i;
     /* 3: shrsl */
-    var37.i = var36.i >> 13;
+    var37.i = var36.i >> 11;
     /* 4: convlw */
     var35.i = var37.i;
     /* 5: storew */
@@ -586,21 +748,60 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_int16;
 void
 volume_orc_process_int16 (gint16 * ORC_RESTRICT d1, int p1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_int16;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 24, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 105, 110, 116, 49, 54, 11, 2, 2, 14, 4,
+        11, 0, 0, 0, 16, 2, 20, 4, 176, 32, 0, 24, 125, 32, 32, 16,
+        163, 0, 32, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p, _backup_volume_orc_process_int16);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_int16");
+      orc_program_set_backup_function (p, _backup_volume_orc_process_int16);
+      orc_program_add_destination (p, 2, "d1");
+      orc_program_add_constant (p, 4, 0x0000000b, "c1");
+      orc_program_add_parameter (p, 2, "p1");
+      orc_program_add_temporary (p, 4, "t1");
+
+      orc_program_append_2 (p, "mulswl", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "shrsl", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convlw", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->params[ORC_VAR_P1] = p1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -630,7 +831,7 @@
     /* 2: mulswl */
     var36.i = var33.i * var34.i;
     /* 3: shrsl */
-    var37.i = var36.i >> 13;
+    var37.i = var36.i >> 11;
     /* 4: convssslw */
     var35.i = ORC_CLAMP_SW (var37.i);
     /* 5: storew */
@@ -663,7 +864,7 @@
     /* 2: mulswl */
     var36.i = var33.i * var34.i;
     /* 3: shrsl */
-    var37.i = var36.i >> 13;
+    var37.i = var36.i >> 11;
     /* 4: convssslw */
     var35.i = ORC_CLAMP_SW (var37.i);
     /* 5: storew */
@@ -672,21 +873,62 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_int16_clamp;
 void
 volume_orc_process_int16_clamp (gint16 * ORC_RESTRICT d1, int p1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_int16_clamp;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 30, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 105, 110, 116, 49, 54, 95, 99, 108, 97, 109,
+        112, 11, 2, 2, 14, 4, 11, 0, 0, 0, 16, 2, 20, 4, 176, 32,
+        0, 24, 125, 32, 32, 16, 165, 0, 32, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_int16_clamp);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_int16_clamp");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_int16_clamp);
+      orc_program_add_destination (p, 2, "d1");
+      orc_program_add_constant (p, 4, 0x0000000b, "c1");
+      orc_program_add_parameter (p, 2, "p1");
+      orc_program_add_temporary (p, 4, "t1");
+
+      orc_program_append_2 (p, "mulswl", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "shrsl", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convssslw", 0, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->params[ORC_VAR_P1] = p1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -716,7 +958,7 @@
     /* 2: mulsbw */
     var36.i = var33 * var34;
     /* 3: shrsw */
-    var37.i = var36.i >> 5;
+    var37.i = var36.i >> 3;
     /* 4: convwb */
     var35 = var37.i;
     /* 5: storeb */
@@ -749,7 +991,7 @@
     /* 2: mulsbw */
     var36.i = var33 * var34;
     /* 3: shrsw */
-    var37.i = var36.i >> 5;
+    var37.i = var36.i >> 3;
     /* 4: convwb */
     var35 = var37.i;
     /* 5: storeb */
@@ -758,21 +1000,60 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_int8;
 void
 volume_orc_process_int8 (gint8 * ORC_RESTRICT d1, int p1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_int8;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 23, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 105, 110, 116, 56, 11, 1, 1, 14, 4, 3,
+        0, 0, 0, 16, 1, 20, 2, 174, 32, 0, 24, 94, 32, 32, 16, 157,
+        0, 32, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p, _backup_volume_orc_process_int8);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_int8");
+      orc_program_set_backup_function (p, _backup_volume_orc_process_int8);
+      orc_program_add_destination (p, 1, "d1");
+      orc_program_add_constant (p, 4, 0x00000003, "c1");
+      orc_program_add_parameter (p, 1, "p1");
+      orc_program_add_temporary (p, 2, "t1");
+
+      orc_program_append_2 (p, "mulsbw", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convwb", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->params[ORC_VAR_P1] = p1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -802,7 +1083,7 @@
     /* 2: mulsbw */
     var36.i = var33 * var34;
     /* 3: shrsw */
-    var37.i = var36.i >> 5;
+    var37.i = var36.i >> 3;
     /* 4: convssswb */
     var35 = ORC_CLAMP_SB (var37.i);
     /* 5: storeb */
@@ -835,7 +1116,7 @@
     /* 2: mulsbw */
     var36.i = var33 * var34;
     /* 3: shrsw */
-    var37.i = var36.i >> 5;
+    var37.i = var36.i >> 3;
     /* 4: convssswb */
     var35 = ORC_CLAMP_SB (var37.i);
     /* 5: storeb */
@@ -844,21 +1125,63 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_int8_clamp;
 void
 volume_orc_process_int8_clamp (gint8 * ORC_RESTRICT d1, int p1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_int8_clamp;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 29, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 105, 110, 116, 56, 95, 99, 108, 97, 109,
+            112,
+        11, 1, 1, 14, 4, 3, 0, 0, 0, 16, 1, 20, 2, 174, 32, 0,
+        24, 94, 32, 32, 16, 159, 0, 32, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_int8_clamp);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_int8_clamp");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_int8_clamp);
+      orc_program_add_destination (p, 1, "d1");
+      orc_program_add_constant (p, 4, 0x00000003, "c1");
+      orc_program_add_parameter (p, 1, "p1");
+      orc_program_add_temporary (p, 2, "t1");
+
+      orc_program_append_2 (p, "mulsbw", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convssswb", 0, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->params[ORC_VAR_P1] = p1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -890,7 +1213,7 @@
 
 #else
 static void
-_backup_orc_memset_f64 (OrcExecutor * ORC_RESTRICT ex)
+_backup_volume_orc_memset_f64 (OrcExecutor * ORC_RESTRICT ex)
 {
   int i;
   int n = ex->n;
@@ -914,15 +1237,47 @@
 
 }
 
-static OrcProgram *_orc_program_orc_memset_f64;
 void
 volume_orc_memset_f64 (gdouble * ORC_RESTRICT d1, double p1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_orc_memset_f64;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 21, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 109, 101,
+        109, 115, 101, 116, 95, 102, 54, 52, 11, 8, 8, 18, 8, 137, 0, 24,
+        2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p, _backup_volume_orc_memset_f64);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_memset_f64");
+      orc_program_set_backup_function (p, _backup_volume_orc_memset_f64);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_parameter_double (p, 8, "p1");
+
+      orc_program_append_2 (p, "copyq", 0, ORC_VAR_D1, ORC_VAR_P1, ORC_VAR_D1,
+          ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
@@ -933,7 +1288,7 @@
     ex->params[ORC_VAR_T1] = tmp.x2[1];
   }
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -949,7 +1304,11 @@
   orc_union64 *ORC_RESTRICT ptr0;
   const orc_union32 *ORC_RESTRICT ptr4;
   orc_union32 var33;
+#if defined(__APPLE__) && __GNUC__ == 4 && __GNUC_MINOR__ == 2 && defined (__i386__)
+  volatile orc_union64 var34;
+#else
   orc_union64 var34;
+#endif
   orc_union64 var35;
   orc_union64 var36;
   orc_union64 var37;
@@ -996,14 +1355,18 @@
 
 #else
 static void
-_backup_orc_prepare_volumes (OrcExecutor * ORC_RESTRICT ex)
+_backup_volume_orc_prepare_volumes (OrcExecutor * ORC_RESTRICT ex)
 {
   int i;
   int n = ex->n;
   orc_union64 *ORC_RESTRICT ptr0;
   const orc_union32 *ORC_RESTRICT ptr4;
   orc_union32 var33;
+#if defined(__APPLE__) && __GNUC__ == 4 && __GNUC_MINOR__ == 2 && defined (__i386__)
+  volatile orc_union64 var34;
+#else
   orc_union64 var34;
+#endif
   orc_union64 var35;
   orc_union64 var36;
   orc_union64 var37;
@@ -1048,22 +1411,61 @@
 
 }
 
-static OrcProgram *_orc_program_orc_prepare_volumes;
 void
 volume_orc_prepare_volumes (gdouble * ORC_RESTRICT d1,
     const gboolean * ORC_RESTRICT s1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_orc_prepare_volumes;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 26, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        101, 112, 97, 114, 101, 95, 118, 111, 108, 117, 109, 101, 115, 11, 8, 8,
+        12, 4, 4, 15, 8, 0, 0, 0, 0, 0, 0, 240, 63, 20, 8, 223,
+        32, 4, 213, 32, 16, 32, 214, 0, 0, 32, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p, _backup_volume_orc_prepare_volumes);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_prepare_volumes");
+      orc_program_set_backup_function (p, _backup_volume_orc_prepare_volumes);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_constant_int64 (p, 8, 0x3ff0000000000000ULL, "c1");
+      orc_program_add_temporary (p, 8, "t1");
+
+      orc_program_append_2 (p, "convld", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "subd", 0, ORC_VAR_T1, ORC_VAR_C1, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "muld", 0, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->arrays[ORC_VAR_S1] = (void *) s1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -1144,22 +1546,58 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_controlled_f64_1ch;
 void
 volume_orc_process_controlled_f64_1ch (gdouble * ORC_RESTRICT d1,
     const gdouble * ORC_RESTRICT s1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_controlled_f64_1ch;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 37, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 99, 111, 110, 116, 114, 111, 108, 108, 101,
+            100,
+        95, 102, 54, 52, 95, 49, 99, 104, 11, 8, 8, 12, 8, 8, 214, 0,
+        0, 4, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_f64_1ch);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_controlled_f64_1ch");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_f64_1ch);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_source (p, 8, "s1");
+
+      orc_program_append_2 (p, "muld", 0, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_S1,
+          ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->arrays[ORC_VAR_S1] = (void *) s1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -1258,22 +1696,61 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_controlled_f32_1ch;
 void
 volume_orc_process_controlled_f32_1ch (gfloat * ORC_RESTRICT d1,
     const gdouble * ORC_RESTRICT s1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_controlled_f32_1ch;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 37, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 99, 111, 110, 116, 114, 111, 108, 108, 101,
+            100,
+        95, 102, 51, 50, 95, 49, 99, 104, 11, 4, 4, 12, 8, 8, 20, 4,
+        225, 32, 4, 202, 0, 0, 32, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_f32_1ch);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_controlled_f32_1ch");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_f32_1ch);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 4, "t1");
+
+      orc_program_append_2 (p, "convdf", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mulf", 0, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->arrays[ORC_VAR_S1] = (void *) s1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -1406,22 +1883,65 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_controlled_f32_2ch;
 void
 volume_orc_process_controlled_f32_2ch (gfloat * ORC_RESTRICT d1,
     const gdouble * ORC_RESTRICT s1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_controlled_f32_2ch;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 37, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 99, 111, 110, 116, 114, 111, 108, 108, 101,
+            100,
+        95, 102, 51, 50, 95, 50, 99, 104, 11, 8, 8, 12, 8, 8, 20, 4,
+        20, 8, 225, 32, 4, 194, 33, 32, 32, 21, 1, 202, 0, 0, 33, 2,
+        0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_f32_2ch);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_controlled_f32_2ch");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_f32_2ch);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 4, "t1");
+      orc_program_add_temporary (p, 8, "t2");
+
+      orc_program_append_2 (p, "convdf", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergelq", 0, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mulf", 1, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_T2,
+          ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->arrays[ORC_VAR_S1] = (void *) s1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -1526,22 +2046,63 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_controlled_int32_1ch;
 void
 volume_orc_process_controlled_int32_1ch (gint32 * ORC_RESTRICT d1,
     const gdouble * ORC_RESTRICT s1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_controlled_int32_1ch;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 39, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 99, 111, 110, 116, 114, 111, 108, 108, 101,
+            100,
+        95, 105, 110, 116, 51, 50, 95, 49, 99, 104, 11, 4, 4, 12, 8, 8,
+        20, 8, 223, 32, 0, 214, 32, 32, 4, 222, 0, 32, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_int32_1ch);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_controlled_int32_1ch");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_int32_1ch);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 8, "t1");
+
+      orc_program_append_2 (p, "convld", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "muld", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convdl", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->arrays[ORC_VAR_S1] = (void *) s1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -1676,22 +2237,71 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_controlled_int16_1ch;
 void
 volume_orc_process_controlled_int16_1ch (gint16 * ORC_RESTRICT d1,
     const gdouble * ORC_RESTRICT s1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_controlled_int16_1ch;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 39, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 99, 111, 110, 116, 114, 111, 108, 108, 101,
+            100,
+        95, 105, 110, 116, 49, 54, 95, 49, 99, 104, 11, 2, 2, 12, 8, 8,
+        20, 4, 20, 4, 153, 32, 0, 211, 32, 32, 225, 33, 4, 202, 32, 32,
+        33, 210, 32, 32, 165, 0, 32, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_int16_1ch);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_controlled_int16_1ch");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_int16_1ch);
+      orc_program_add_destination (p, 2, "d1");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 4, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+
+      orc_program_append_2 (p, "convswl", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convlf", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convdf", 0, ORC_VAR_T2, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mulf", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convfl", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convssslw", 0, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->arrays[ORC_VAR_S1] = (void *) s1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -1880,22 +2490,75 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_controlled_int16_2ch;
 void
 volume_orc_process_controlled_int16_2ch (gint16 * ORC_RESTRICT d1,
     const gdouble * ORC_RESTRICT s1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_controlled_int16_2ch;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 39, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 99, 111, 110, 116, 114, 111, 108, 108, 101,
+            100,
+        95, 105, 110, 116, 49, 54, 95, 50, 99, 104, 11, 4, 4, 12, 8, 8,
+        20, 8, 20, 4, 20, 8, 21, 1, 153, 32, 0, 21, 1, 211, 32, 32,
+        225, 33, 4, 194, 34, 33, 33, 21, 1, 202, 34, 34, 32, 21, 1, 210,
+        34, 34, 21, 1, 165, 0, 34, 2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_int16_2ch);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_controlled_int16_2ch");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_int16_2ch);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 8, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+      orc_program_add_temporary (p, 8, "t3");
+
+      orc_program_append_2 (p, "convswl", 1, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convlf", 1, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convdf", 0, ORC_VAR_T2, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergelq", 0, ORC_VAR_T3, ORC_VAR_T2, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mulf", 1, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convfl", 1, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convssslw", 1, ORC_VAR_D1, ORC_VAR_T3,
+          ORC_VAR_D1, ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->arrays[ORC_VAR_S1] = (void *) s1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -2042,22 +2705,77 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_controlled_int8_1ch;
 void
 volume_orc_process_controlled_int8_1ch (gint8 * ORC_RESTRICT d1,
     const gdouble * ORC_RESTRICT s1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_controlled_int8_1ch;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 38, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 99, 111, 110, 116, 114, 111, 108, 108, 101,
+            100,
+        95, 105, 110, 116, 56, 95, 49, 99, 104, 11, 1, 1, 12, 8, 8, 20,
+        2, 20, 4, 20, 4, 149, 32, 0, 153, 33, 32, 211, 33, 33, 225, 34,
+        4, 202, 33, 33, 34, 210, 33, 33, 163, 32, 33, 159, 0, 32, 2, 0,
+
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_int8_1ch);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_controlled_int8_1ch");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_int8_1ch);
+      orc_program_add_destination (p, 1, "d1");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+      orc_program_add_temporary (p, 4, "t3");
+
+      orc_program_append_2 (p, "convsbw", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convswl", 0, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convlf", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convdf", 0, ORC_VAR_T3, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mulf", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_T3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convfl", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convlw", 0, ORC_VAR_T1, ORC_VAR_T2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convssswb", 0, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->arrays[ORC_VAR_S1] = (void *) s1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
@@ -2262,460 +2980,80 @@
 
 }
 
-static OrcProgram *_orc_program_volume_orc_process_controlled_int8_2ch;
 void
 volume_orc_process_controlled_int8_2ch (gint8 * ORC_RESTRICT d1,
     const gdouble * ORC_RESTRICT s1, int n)
 {
   OrcExecutor _ex, *ex = &_ex;
-  OrcProgram *p = _orc_program_volume_orc_process_controlled_int8_2ch;
+  static volatile int p_inited = 0;
+  static OrcCode *c = 0;
   void (*func) (OrcExecutor *);
 
-  ex->program = p;
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+      OrcProgram *p;
+
+#if 1
+      static const orc_uint8 bc[] = {
+        1, 9, 38, 118, 111, 108, 117, 109, 101, 95, 111, 114, 99, 95, 112, 114,
+        111, 99, 101, 115, 115, 95, 99, 111, 110, 116, 114, 111, 108, 108, 101,
+            100,
+        95, 105, 110, 116, 56, 95, 50, 99, 104, 11, 2, 2, 12, 8, 8, 20,
+        4, 20, 8, 20, 8, 21, 1, 149, 32, 0, 21, 1, 153, 33, 32, 21,
+        1, 211, 33, 33, 225, 32, 4, 194, 34, 32, 32, 21, 1, 202, 33, 33,
+        34, 21, 1, 210, 33, 33, 21, 1, 163, 32, 33, 21, 1, 159, 0, 32,
+        2, 0,
+      };
+      p = orc_program_new_from_static_bytecode (bc);
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_int8_2ch);
+#else
+      p = orc_program_new ();
+      orc_program_set_name (p, "volume_orc_process_controlled_int8_2ch");
+      orc_program_set_backup_function (p,
+          _backup_volume_orc_process_controlled_int8_2ch);
+      orc_program_add_destination (p, 2, "d1");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 4, "t1");
+      orc_program_add_temporary (p, 8, "t2");
+      orc_program_add_temporary (p, 8, "t3");
+
+      orc_program_append_2 (p, "convsbw", 1, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convswl", 1, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convlf", 1, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convdf", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergelq", 0, ORC_VAR_T3, ORC_VAR_T1, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mulf", 1, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_T3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convfl", 1, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convlw", 1, ORC_VAR_T1, ORC_VAR_T2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convssswb", 1, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+#endif
+
+      orc_program_compile (p);
+      c = orc_program_take_code (p);
+      orc_program_free (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->arrays[ORC_VAR_A2] = c;
+  ex->program = 0;
 
   ex->n = n;
   ex->arrays[ORC_VAR_D1] = d1;
   ex->arrays[ORC_VAR_S1] = (void *) s1;
 
-  func = p->code_exec;
+  func = c->exec;
   func (ex);
 }
 #endif
-
-
-void
-gst_volume_orc_init (void)
-{
-#ifndef DISABLE_ORC
-  {
-    /* volume_orc_scalarmultiply_f64_ns */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_scalarmultiply_f64_ns");
-    orc_program_set_backup_function (p, _backup_orc_scalarmultiply_f64_ns);
-    orc_program_add_destination (p, 8, "d1");
-    orc_program_add_parameter_double (p, 8, "p1");
-
-    orc_program_append_2 (p, "muld", 0, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_P1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_orc_scalarmultiply_f64_ns = p;
-  }
-  {
-    /* volume_orc_scalarmultiply_f32_ns */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_scalarmultiply_f32_ns");
-    orc_program_set_backup_function (p, _backup_orc_scalarmultiply_f32_ns);
-    orc_program_add_destination (p, 4, "d1");
-    orc_program_add_parameter_float (p, 4, "p1");
-
-    orc_program_append_2 (p, "mulf", 0, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_P1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_orc_scalarmultiply_f32_ns = p;
-  }
-  {
-    /* volume_orc_process_int32 */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_int32");
-    orc_program_set_backup_function (p, _backup_volume_orc_process_int32);
-    orc_program_add_destination (p, 4, "d1");
-    orc_program_add_constant (p, 4, 0x0000001b, "c1");
-    orc_program_add_parameter (p, 4, "p1");
-    orc_program_add_temporary (p, 8, "t1");
-
-    orc_program_append_2 (p, "mulslq", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "shrsq", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convql", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_int32 = p;
-  }
-  {
-    /* volume_orc_process_int32_clamp */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_int32_clamp");
-    orc_program_set_backup_function (p, _backup_volume_orc_process_int32_clamp);
-    orc_program_add_destination (p, 4, "d1");
-    orc_program_add_constant (p, 4, 0x0000001b, "c1");
-    orc_program_add_parameter (p, 4, "p1");
-    orc_program_add_temporary (p, 8, "t1");
-
-    orc_program_append_2 (p, "mulslq", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "shrsq", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convsssql", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_int32_clamp = p;
-  }
-  {
-    /* volume_orc_process_int16 */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_int16");
-    orc_program_set_backup_function (p, _backup_volume_orc_process_int16);
-    orc_program_add_destination (p, 2, "d1");
-    orc_program_add_constant (p, 4, 0x0000000d, "c1");
-    orc_program_add_parameter (p, 2, "p1");
-    orc_program_add_temporary (p, 4, "t1");
-
-    orc_program_append_2 (p, "mulswl", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "shrsl", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convlw", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_int16 = p;
-  }
-  {
-    /* volume_orc_process_int16_clamp */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_int16_clamp");
-    orc_program_set_backup_function (p, _backup_volume_orc_process_int16_clamp);
-    orc_program_add_destination (p, 2, "d1");
-    orc_program_add_constant (p, 4, 0x0000000d, "c1");
-    orc_program_add_parameter (p, 2, "p1");
-    orc_program_add_temporary (p, 4, "t1");
-
-    orc_program_append_2 (p, "mulswl", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "shrsl", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convssslw", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_int16_clamp = p;
-  }
-  {
-    /* volume_orc_process_int8 */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_int8");
-    orc_program_set_backup_function (p, _backup_volume_orc_process_int8);
-    orc_program_add_destination (p, 1, "d1");
-    orc_program_add_constant (p, 4, 0x00000005, "c1");
-    orc_program_add_parameter (p, 1, "p1");
-    orc_program_add_temporary (p, 2, "t1");
-
-    orc_program_append_2 (p, "mulsbw", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convwb", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_int8 = p;
-  }
-  {
-    /* volume_orc_process_int8_clamp */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_int8_clamp");
-    orc_program_set_backup_function (p, _backup_volume_orc_process_int8_clamp);
-    orc_program_add_destination (p, 1, "d1");
-    orc_program_add_constant (p, 4, 0x00000005, "c1");
-    orc_program_add_parameter (p, 1, "p1");
-    orc_program_add_temporary (p, 2, "t1");
-
-    orc_program_append_2 (p, "mulsbw", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_P1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convssswb", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_int8_clamp = p;
-  }
-  {
-    /* volume_orc_memset_f64 */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_memset_f64");
-    orc_program_set_backup_function (p, _backup_orc_memset_f64);
-    orc_program_add_destination (p, 8, "d1");
-    orc_program_add_parameter_double (p, 8, "p1");
-
-    orc_program_append_2 (p, "copyq", 0, ORC_VAR_D1, ORC_VAR_P1, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_orc_memset_f64 = p;
-  }
-  {
-    /* volume_orc_prepare_volumes */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_prepare_volumes");
-    orc_program_set_backup_function (p, _backup_orc_prepare_volumes);
-    orc_program_add_destination (p, 8, "d1");
-    orc_program_add_source (p, 4, "s1");
-    orc_program_add_constant_int64 (p, 8, 0x3ff0000000000000ULL, "c1");
-    orc_program_add_temporary (p, 8, "t1");
-
-    orc_program_append_2 (p, "convld", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "subd", 0, ORC_VAR_T1, ORC_VAR_C1, ORC_VAR_T1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "muld", 0, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_T1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_orc_prepare_volumes = p;
-  }
-  {
-    /* volume_orc_process_controlled_f64_1ch */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_controlled_f64_1ch");
-    orc_program_set_backup_function (p, _backup_volume_orc_process_controlled_f64_1ch);
-    orc_program_add_destination (p, 8, "d1");
-    orc_program_add_source (p, 8, "s1");
-
-    orc_program_append_2 (p, "muld", 0, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_S1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_controlled_f64_1ch = p;
-  }
-  {
-    /* volume_orc_process_controlled_f32_1ch */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_controlled_f32_1ch");
-    orc_program_set_backup_function (p, _backup_volume_orc_process_controlled_f32_1ch);
-    orc_program_add_destination (p, 4, "d1");
-    orc_program_add_source (p, 8, "s1");
-    orc_program_add_temporary (p, 4, "t1");
-
-    orc_program_append_2 (p, "convdf", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "mulf", 0, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_T1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_controlled_f32_1ch = p;
-  }
-  {
-    /* volume_orc_process_controlled_f32_2ch */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_controlled_f32_2ch");
-    orc_program_set_backup_function (p, _backup_volume_orc_process_controlled_f32_2ch);
-    orc_program_add_destination (p, 8, "d1");
-    orc_program_add_source (p, 8, "s1");
-    orc_program_add_temporary (p, 4, "t1");
-    orc_program_add_temporary (p, 8, "t2");
-
-    orc_program_append_2 (p, "convdf", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "mergelq", 0, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_T1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "mulf", 1, ORC_VAR_D1, ORC_VAR_D1, ORC_VAR_T2,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_controlled_f32_2ch = p;
-  }
-  {
-    /* volume_orc_process_controlled_int32_1ch */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_controlled_int32_1ch");
-    orc_program_set_backup_function (p,
-        _backup_volume_orc_process_controlled_int32_1ch);
-    orc_program_add_destination (p, 4, "d1");
-    orc_program_add_source (p, 8, "s1");
-    orc_program_add_temporary (p, 8, "t1");
-
-    orc_program_append_2 (p, "convld", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "muld", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_S1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convdl", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_controlled_int32_1ch = p;
-  }
-  {
-    /* volume_orc_process_controlled_int16_1ch */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_controlled_int16_1ch");
-    orc_program_set_backup_function (p,
-        _backup_volume_orc_process_controlled_int16_1ch);
-    orc_program_add_destination (p, 2, "d1");
-    orc_program_add_source (p, 8, "s1");
-    orc_program_add_temporary (p, 4, "t1");
-    orc_program_add_temporary (p, 4, "t2");
-
-    orc_program_append_2 (p, "convswl", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convlf", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convdf", 0, ORC_VAR_T2, ORC_VAR_S1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "mulf", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T2,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convfl", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convssslw", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_controlled_int16_1ch = p;
-  }
-  {
-    /* volume_orc_process_controlled_int16_2ch */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_controlled_int16_2ch");
-    orc_program_set_backup_function (p,
-        _backup_volume_orc_process_controlled_int16_2ch);
-    orc_program_add_destination (p, 4, "d1");
-    orc_program_add_source (p, 8, "s1");
-    orc_program_add_temporary (p, 8, "t1");
-    orc_program_add_temporary (p, 4, "t2");
-    orc_program_add_temporary (p, 8, "t3");
-
-    orc_program_append_2 (p, "convswl", 1, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convlf", 1, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convdf", 0, ORC_VAR_T2, ORC_VAR_S1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "mergelq", 0, ORC_VAR_T3, ORC_VAR_T2, ORC_VAR_T2,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "mulf", 1, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convfl", 1, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convssslw", 1, ORC_VAR_D1, ORC_VAR_T3, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_controlled_int16_2ch = p;
-  }
-  {
-    /* volume_orc_process_controlled_int8_1ch */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_controlled_int8_1ch");
-    orc_program_set_backup_function (p,
-        _backup_volume_orc_process_controlled_int8_1ch);
-    orc_program_add_destination (p, 1, "d1");
-    orc_program_add_source (p, 8, "s1");
-    orc_program_add_temporary (p, 2, "t1");
-    orc_program_add_temporary (p, 4, "t2");
-    orc_program_add_temporary (p, 4, "t3");
-
-    orc_program_append_2 (p, "convsbw", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convswl", 0, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convlf", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convdf", 0, ORC_VAR_T3, ORC_VAR_S1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "mulf", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_T3,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convfl", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convlw", 0, ORC_VAR_T1, ORC_VAR_T2, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convssswb", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_controlled_int8_1ch = p;
-  }
-  {
-    /* volume_orc_process_controlled_int8_2ch */
-    OrcProgram *p;
-
-    p = orc_program_new ();
-    orc_program_set_name (p, "volume_orc_process_controlled_int8_2ch");
-    orc_program_set_backup_function (p,
-        _backup_volume_orc_process_controlled_int8_2ch);
-    orc_program_add_destination (p, 2, "d1");
-    orc_program_add_source (p, 8, "s1");
-    orc_program_add_temporary (p, 4, "t1");
-    orc_program_add_temporary (p, 8, "t2");
-    orc_program_add_temporary (p, 8, "t3");
-
-    orc_program_append_2 (p, "convsbw", 1, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convswl", 1, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convlf", 1, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convdf", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "mergelq", 0, ORC_VAR_T3, ORC_VAR_T1, ORC_VAR_T1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "mulf", 1, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_T3,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convfl", 1, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convlw", 1, ORC_VAR_T1, ORC_VAR_T2, ORC_VAR_D1,
-        ORC_VAR_D1);
-    orc_program_append_2 (p, "convssswb", 1, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
-        ORC_VAR_D1);
-
-    orc_program_compile (p);
-
-    _orc_program_volume_orc_process_controlled_int8_2ch = p;
-  }
-#endif
-}
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolumeorc-dist.h	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolumeorc-dist.h	Mon Sep 21 16:17:03 2015 -0700
@@ -10,8 +10,6 @@
 extern "C" {
 #endif
 
-void gst_volume_orc_init (void);
-
 
 
 #ifndef _ORC_INTEGER_TYPEDEFS_
@@ -69,6 +67,19 @@
 #define ORC_RESTRICT
 #endif
 #endif
+
+#ifndef ORC_INTERNAL
+#if defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590)
+#define ORC_INTERNAL __attribute__((visibility("hidden")))
+#elif defined(__SUNPRO_C) && (__SUNPRO_C >= 0x550)
+#define ORC_INTERNAL __hidden
+#elif defined (__GNUC__)
+#define ORC_INTERNAL __attribute__((visibility("hidden")))
+#else
+#define ORC_INTERNAL
+#endif
+#endif
+
 void volume_orc_scalarmultiply_f64_ns (double * ORC_RESTRICT d1, double p1, int n);
 void volume_orc_scalarmultiply_f32_ns (float * ORC_RESTRICT d1, float p1, int n);
 void volume_orc_process_int32 (gint32 * ORC_RESTRICT d1, int p1, int n);
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolumeorc.orc	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-base/gst/volume/gstvolumeorc.orc	Mon Sep 21 16:17:03 2015 -0700
@@ -1,19 +1,17 @@
 
-.init gst_volume_orc_init
-
-.function orc_scalarmultiply_f64_ns
+.function volume_orc_scalarmultiply_f64_ns
 .dest 8 d1 double
 .doubleparam 8 p1
 
 muld d1, d1, p1
 
-.function orc_scalarmultiply_f32_ns
+.function volume_orc_scalarmultiply_f32_ns
 .dest 4 d1 float
 .floatparam 4 p1
 
 mulf d1, d1, p1
 
-.function orc_process_int32
+.function volume_orc_process_int32
 .dest 4 d1 gint32
 .param 4 p1
 .temp 8 t1
@@ -22,7 +20,7 @@
 shrsq t1, t1, 27
 convql d1, t1
 
-.function orc_process_int32_clamp
+.function volume_orc_process_int32_clamp
 .dest 4 d1 gint32
 .param 4 p1
 .temp 8 t1
@@ -31,51 +29,51 @@
 shrsq t1, t1, 27
 convsssql d1, t1
 
-.function orc_process_int16
+.function volume_orc_process_int16
 .dest 2 d1 gint16
 .param 2 p1
 .temp 4 t1
 
 mulswl t1, d1, p1
-shrsl t1, t1, 13
+shrsl t1, t1, 11
 convlw d1, t1
 
 
-.function orc_process_int16_clamp
+.function volume_orc_process_int16_clamp
 .dest 2 d1 gint16
 .param 2 p1
 .temp 4 t1
 
 mulswl t1, d1, p1
-shrsl t1, t1, 13
+shrsl t1, t1, 11
 convssslw d1, t1
 
-.function orc_process_int8
+.function volume_orc_process_int8
 .dest 1 d1 gint8
 .param 1 p1
 .temp 2 t1
 
 mulsbw t1, d1, p1
-shrsw t1, t1, 5
+shrsw t1, t1, 3
 convwb d1, t1
 
 
-.function orc_process_int8_clamp
+.function volume_orc_process_int8_clamp
 .dest 1 d1 gint8
 .param 1 p1
 .temp 2 t1
 
 mulsbw t1, d1, p1
-shrsw t1, t1, 5
+shrsw t1, t1, 3
 convssswb d1, t1
 
-.function orc_memset_f64
+.function volume_orc_memset_f64
 .dest 8 d1 gdouble
 .doubleparam 8 p1
 
 copyq d1, p1
 
-.function orc_prepare_volumes
+.function volume_orc_prepare_volumes
 .dest 8 d1 gdouble
 .source 4 s1 gboolean
 .temp 8 t1
@@ -84,13 +82,13 @@
 subd t1, 0x3FF0000000000000L, t1
 muld d1, d1, t1
 
-.function orc_process_controlled_f64_1ch
+.function volume_orc_process_controlled_f64_1ch
 .dest 8 d1 gdouble
 .source 8 s1 gdouble
 
 muld d1, d1, s1
 
-.function orc_process_controlled_f32_1ch
+.function volume_orc_process_controlled_f32_1ch
 .dest 4 d1 gfloat
 .source 8 s1 gdouble
 .temp 4 t1
@@ -98,7 +96,7 @@
 convdf t1, s1
 mulf d1, d1, t1
 
-.function orc_process_controlled_f32_2ch
+.function volume_orc_process_controlled_f32_2ch
 .dest 8 d1 gfloat
 .source 8 s1 gdouble
 .temp 4 t1
@@ -108,7 +106,7 @@
 mergelq t2, t1, t1
 x2 mulf d1, d1, t2
 
-.function orc_process_controlled_int32_1ch
+.function volume_orc_process_controlled_int32_1ch
 .dest 4 d1 gint32
 .source 8 s1 gdouble
 .temp 8 t1
@@ -117,7 +115,7 @@
 muld t1, t1, s1
 convdl d1, t1
 
-.function orc_process_controlled_int16_1ch
+.function volume_orc_process_controlled_int16_1ch
 .dest 2 d1 gint16
 .source 8 s1 gdouble
 .temp 4 t1
@@ -130,7 +128,7 @@
 convfl t1, t1
 convssslw d1, t1
 
-.function orc_process_controlled_int16_2ch
+.function volume_orc_process_controlled_int16_2ch
 .dest 4 d1 gint16
 .source 8 s1 gdouble
 .temp 8 t1
@@ -145,7 +143,7 @@
 x2 convfl t3, t3
 x2 convssslw d1, t3
 
-.function orc_process_controlled_int8_1ch
+.function volume_orc_process_controlled_int8_1ch
 .dest 1 d1 gint8
 .source 8 s1 gdouble
 .temp 2 t1
@@ -161,7 +159,7 @@
 convlw t1, t2
 convssswb d1, t1
 
-.function orc_process_controlled_int8_2ch
+.function volume_orc_process_controlled_int8_2ch
 .dest 2 d1 gint8
 .source 8 s1 gdouble
 .temp 4 t1
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audioamplify.c	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,476 +0,0 @@
-/* 
- * GStreamer
- * Copyright (C) 2007 Sebastian Dröge <slomo@circular-chaos.org>
- * Copyright (C) 2006 Stefan Kost <ensonic@users.sf.net>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-/**
- * SECTION:element-audioamplify
- *
- * Amplifies an audio stream by a given factor and allows the selection of different clipping modes.
- * The difference between the clipping modes is best evaluated by testing.
- *
- * <refsect2>
- * <title>Example launch line</title>
- * |[
- * gst-launch-1.0 audiotestsrc wave=saw ! audioamplify amplification=1.5 ! alsasink
- * gst-launch-1.0 filesrc location="melo1.ogg" ! oggdemux ! vorbisdec ! audioconvert ! audioamplify amplification=1.5 method=wrap-negative ! alsasink
- * gst-launch-1.0 audiotestsrc wave=saw ! audioconvert ! audioamplify amplification=1.5 method=wrap-positive ! audioconvert ! alsasink
- * ]|
- * </refsect2>
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include "audioamplify.h"
-
-#define GST_CAT_DEFAULT gst_audio_amplify_debug
-GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
-
-/* Filter signals and args */
-enum
-{
-  /* FILL ME */
-  LAST_SIGNAL
-};
-
-enum
-{
-  PROP_0,
-  PROP_AMPLIFICATION,
-  PROP_CLIPPING_METHOD
-};
-
-enum
-{
-  METHOD_CLIP = 0,
-  METHOD_WRAP_NEGATIVE,
-  METHOD_WRAP_POSITIVE,
-  METHOD_NOCLIP,
-  NUM_METHODS
-};
-
-#define GST_TYPE_AUDIO_AMPLIFY_CLIPPING_METHOD (gst_audio_amplify_clipping_method_get_type ())
-static GType
-gst_audio_amplify_clipping_method_get_type (void)
-{
-  static GType gtype = 0;
-
-  if (gtype == 0) {
-    static const GEnumValue values[] = {
-      {METHOD_CLIP, "Normal clipping (default)", "clip"},
-      {METHOD_WRAP_NEGATIVE,
-            "Push overdriven values back from the opposite side",
-          "wrap-negative"},
-      {METHOD_WRAP_POSITIVE, "Push overdriven values back from the same side",
-          "wrap-positive"},
-      {METHOD_NOCLIP, "No clipping", "none"},
-      {0, NULL, NULL}
-    };
-    gtype = g_enum_register_static ("GstAudioAmplifyClippingMethod", values);
-  }
-  return gtype;
-}
-
-#define ALLOWED_CAPS                                                  \
-    "audio/x-raw,"                                                    \
-    " format=(string) {S8,"GST_AUDIO_NE(S16)","GST_AUDIO_NE(S32)","   \
-                           GST_AUDIO_NE(F32)","GST_AUDIO_NE(F64)"},"  \
-    " rate=(int)[1,MAX],"                                             \
-    " channels=(int)[1,MAX], "                                        \
-    " layout=(string) {interleaved, non-interleaved}"
-
-G_DEFINE_TYPE (GstAudioAmplify, gst_audio_amplify, GST_TYPE_AUDIO_FILTER);
-
-static gboolean gst_audio_amplify_set_process_function (GstAudioAmplify *
-    filter, gint clipping, GstAudioFormat format);
-static void gst_audio_amplify_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec);
-static void gst_audio_amplify_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec);
-
-static gboolean gst_audio_amplify_setup (GstAudioFilter * filter,
-    const GstAudioInfo * info);
-static GstFlowReturn gst_audio_amplify_transform_ip (GstBaseTransform * base,
-    GstBuffer * buf);
-
-#define MIN_gint8 G_MININT8
-#define MAX_gint8 G_MAXINT8
-#define MIN_gint16 G_MININT16
-#define MAX_gint16 G_MAXINT16
-#define MIN_gint32 G_MININT32
-#define MAX_gint32 G_MAXINT32
-
-#define MAKE_INT_FUNCS(type,largetype)                                        \
-static void                                                                   \
-gst_audio_amplify_transform_##type##_clip (GstAudioAmplify * filter,          \
-    void * data, guint num_samples)                                           \
-{                                                                             \
-  type *d = data;                                                             \
-                                                                              \
-  while (num_samples--) {                                                     \
-    largetype val = *d * filter->amplification;                               \
-    *d++ =  CLAMP (val, MIN_##type, MAX_##type);                              \
-  }                                                                           \
-}                                                                             \
-static void                                                                   \
-gst_audio_amplify_transform_##type##_wrap_negative (GstAudioAmplify * filter, \
-    void * data, guint num_samples)                                           \
-{                                                                             \
-  type *d = data;                                                             \
-                                                                              \
-  while (num_samples--) {                                                     \
-    largetype val = *d * filter->amplification;                               \
-    if (val > MAX_##type)                                                     \
-      val = MIN_##type + (val - MIN_##type) % ((largetype) MAX_##type + 1 -   \
-          MIN_##type);                                                        \
-    else if (val < MIN_##type)                                                \
-      val = MAX_##type - (MAX_##type - val) % ((largetype) MAX_##type + 1 -   \
-          MIN_##type);                                                        \
-    *d++ = val;                                                               \
-  }                                                                           \
-}                                                                             \
-static void                                                                   \
-gst_audio_amplify_transform_##type##_wrap_positive (GstAudioAmplify * filter, \
-    void * data, guint num_samples)                                           \
-{                                                                             \
-  type *d = data;                                                             \
-                                                                              \
-  while (num_samples--) {                                                     \
-    largetype val = *d * filter->amplification;                               \
-    do {                                                                      \
-      if (val > MAX_##type)                                                   \
-        val = MAX_##type - (val - MAX_##type);                                \
-      else if (val < MIN_##type)                                              \
-        val = MIN_##type + (MIN_##type - val);                                \
-      else                                                                    \
-        break;                                                                \
-    } while (1);                                                              \
-    *d++ = val;                                                               \
-  }                                                                           \
-}                                                                             \
-static void                                                                   \
-gst_audio_amplify_transform_##type##_noclip (GstAudioAmplify * filter,        \
-    void * data, guint num_samples)                                           \
-{                                                                             \
-  type *d = data;                                                             \
-                                                                              \
-  while (num_samples--)                                                       \
-    *d++ *= filter->amplification;                                            \
-}
-
-#define MAKE_FLOAT_FUNCS(type)                                                \
-static void                                                                   \
-gst_audio_amplify_transform_##type##_clip (GstAudioAmplify * filter,          \
-    void * data, guint num_samples)                                           \
-{                                                                             \
-  type *d = data;                                                             \
-                                                                              \
-  while (num_samples--) {                                                     \
-    type val = *d* filter->amplification;                                     \
-    *d++ = CLAMP (val, -1.0, +1.0);                                           \
-  }                                                                           \
-}                                                                             \
-static void                                                                   \
-gst_audio_amplify_transform_##type##_wrap_negative (GstAudioAmplify *         \
-    filter, void * data, guint num_samples)                                   \
-{                                                                             \
-  type *d = data;                                                             \
-                                                                              \
-  while (num_samples--) {                                                     \
-    type val = *d * filter->amplification;                                    \
-    do {                                                                      \
-      if (val > 1.0)                                                          \
-        val = -1.0 + (val - 1.0);                                             \
-      else if (val < -1.0)                                                    \
-        val = 1.0 - (1.0 - val);                                              \
-      else                                                                    \
-        break;                                                                \
-    } while (1);                                                              \
-    *d++ = val;                                                               \
-  }                                                                           \
-}                                                                             \
-static void                                                                   \
-gst_audio_amplify_transform_##type##_wrap_positive (GstAudioAmplify * filter, \
-    void * data, guint num_samples)                                           \
-{                                                                             \
-  type *d = data;                                                             \
-                                                                              \
-  while (num_samples--) {                                                     \
-    type val = *d* filter->amplification;                                     \
-    do {                                                                      \
-      if (val > 1.0)                                                          \
-        val = 1.0 - (val - 1.0);                                              \
-      else if (val < -1.0)                                                    \
-        val = -1.0 + (-1.0 - val);                                            \
-      else                                                                    \
-        break;                                                                \
-    } while (1);                                                              \
-    *d++ = val;                                                               \
-  }                                                                           \
-}                                                                             \
-static void                                                                   \
-gst_audio_amplify_transform_##type##_noclip (GstAudioAmplify * filter,        \
-    void * data, guint num_samples)                                           \
-{                                                                             \
-  type *d = data;                                                             \
-                                                                              \
-  while (num_samples--)                                                       \
-    *d++ *= filter->amplification;                                            \
-}
-
-/* *INDENT-OFF* */
-MAKE_INT_FUNCS (gint8,gint)
-MAKE_INT_FUNCS (gint16,gint)
-MAKE_INT_FUNCS (gint32,gint64)
-MAKE_FLOAT_FUNCS (gfloat)
-MAKE_FLOAT_FUNCS (gdouble)
-/* *INDENT-ON* */
-
-/* GObject vmethod implementations */
-
-static void
-gst_audio_amplify_class_init (GstAudioAmplifyClass * klass)
-{
-  GObjectClass *gobject_class;
-  GstElementClass *gstelement_class;
-  GstCaps *caps;
-
-  GST_DEBUG_CATEGORY_INIT (gst_audio_amplify_debug, "audioamplify", 0,
-      "audioamplify element");
-
-  gobject_class = (GObjectClass *) klass;
-  gstelement_class = (GstElementClass *) klass;
-
-  gobject_class->set_property = gst_audio_amplify_set_property;
-  gobject_class->get_property = gst_audio_amplify_get_property;
-
-  g_object_class_install_property (gobject_class, PROP_AMPLIFICATION,
-      g_param_spec_float ("amplification", "Amplification",
-          "Factor of amplification", -G_MAXFLOAT, G_MAXFLOAT,
-          1.0,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-
-  /**
-   * GstAudioAmplify:clipping-method
-   *
-   * Clipping method: clip mode set values higher than the maximum to the
-   * maximum. The wrap-negative mode pushes those values back from the
-   * opposite side, wrap-positive pushes them back from the same side.
-   *
-   **/
-  g_object_class_install_property (gobject_class, PROP_CLIPPING_METHOD,
-      g_param_spec_enum ("clipping-method", "Clipping method",
-          "Selects how to handle values higher than the maximum",
-          GST_TYPE_AUDIO_AMPLIFY_CLIPPING_METHOD, METHOD_CLIP,
-          G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
-
-  gst_element_class_set_static_metadata (gstelement_class, "Audio amplifier",
-      "Filter/Effect/Audio",
-      "Amplifies an audio stream by a given factor",
-      "Sebastian Dröge <slomo@circular-chaos.org>");
-
-  caps = gst_caps_from_string (ALLOWED_CAPS);
-  gst_audio_filter_class_add_pad_templates (GST_AUDIO_FILTER_CLASS (klass),
-      caps);
-  gst_caps_unref (caps);
-
-  GST_BASE_TRANSFORM_CLASS (klass)->transform_ip =
-      GST_DEBUG_FUNCPTR (gst_audio_amplify_transform_ip);
-  GST_BASE_TRANSFORM_CLASS (klass)->transform_ip_on_passthrough = FALSE;
-
-  GST_AUDIO_FILTER_CLASS (klass)->setup =
-      GST_DEBUG_FUNCPTR (gst_audio_amplify_setup);
-}
-
-static void
-gst_audio_amplify_init (GstAudioAmplify * filter)
-{
-  filter->amplification = 1.0;
-  gst_audio_amplify_set_process_function (filter, METHOD_CLIP,
-      GST_AUDIO_FORMAT_S16);
-  gst_base_transform_set_in_place (GST_BASE_TRANSFORM (filter), TRUE);
-  gst_base_transform_set_gap_aware (GST_BASE_TRANSFORM (filter), TRUE);
-}
-
-static GstAudioAmplifyProcessFunc
-gst_audio_amplify_process_function (gint clipping, GstAudioFormat format)
-{
-  static const struct process
-  {
-    GstAudioFormat format;
-    gint clipping;
-    GstAudioAmplifyProcessFunc func;
-  } process[] = {
-    {
-    GST_AUDIO_FORMAT_F32, METHOD_CLIP, gst_audio_amplify_transform_gfloat_clip}, {
-    GST_AUDIO_FORMAT_F32, METHOD_WRAP_NEGATIVE,
-          gst_audio_amplify_transform_gfloat_wrap_negative}, {
-    GST_AUDIO_FORMAT_F32, METHOD_WRAP_POSITIVE,
-          gst_audio_amplify_transform_gfloat_wrap_positive}, {
-    GST_AUDIO_FORMAT_F32, METHOD_NOCLIP,
-          gst_audio_amplify_transform_gfloat_noclip}, {
-    GST_AUDIO_FORMAT_F64, METHOD_CLIP,
-          gst_audio_amplify_transform_gdouble_clip}, {
-    GST_AUDIO_FORMAT_F64, METHOD_WRAP_NEGATIVE,
-          gst_audio_amplify_transform_gdouble_wrap_negative}, {
-    GST_AUDIO_FORMAT_F64, METHOD_WRAP_POSITIVE,
-          gst_audio_amplify_transform_gdouble_wrap_positive}, {
-    GST_AUDIO_FORMAT_F64, METHOD_NOCLIP,
-          gst_audio_amplify_transform_gdouble_noclip}, {
-    GST_AUDIO_FORMAT_S8, METHOD_CLIP, gst_audio_amplify_transform_gint8_clip}, {
-    GST_AUDIO_FORMAT_S8, METHOD_WRAP_NEGATIVE,
-          gst_audio_amplify_transform_gint8_wrap_negative}, {
-    GST_AUDIO_FORMAT_S8, METHOD_WRAP_POSITIVE,
-          gst_audio_amplify_transform_gint8_wrap_positive}, {
-    GST_AUDIO_FORMAT_S8, METHOD_NOCLIP,
-          gst_audio_amplify_transform_gint8_noclip}, {
-    GST_AUDIO_FORMAT_S16, METHOD_CLIP, gst_audio_amplify_transform_gint16_clip}, {
-    GST_AUDIO_FORMAT_S16, METHOD_WRAP_NEGATIVE,
-          gst_audio_amplify_transform_gint16_wrap_negative}, {
-    GST_AUDIO_FORMAT_S16, METHOD_WRAP_POSITIVE,
-          gst_audio_amplify_transform_gint16_wrap_positive}, {
-    GST_AUDIO_FORMAT_S16, METHOD_NOCLIP,
-          gst_audio_amplify_transform_gint16_noclip}, {
-    GST_AUDIO_FORMAT_S32, METHOD_CLIP, gst_audio_amplify_transform_gint32_clip}, {
-    GST_AUDIO_FORMAT_S32, METHOD_WRAP_NEGATIVE,
-          gst_audio_amplify_transform_gint32_wrap_negative}, {
-    GST_AUDIO_FORMAT_S32, METHOD_WRAP_POSITIVE,
-          gst_audio_amplify_transform_gint32_wrap_positive}, {
-    GST_AUDIO_FORMAT_S32, METHOD_NOCLIP,
-          gst_audio_amplify_transform_gint32_noclip}, {
-    0, 0, NULL}
-  };
-  const struct process *p;
-
-  for (p = process; p->func; p++)
-    if (p->format == format && p->clipping == clipping)
-      return p->func;
-  return NULL;
-}
-
-static gboolean
-gst_audio_amplify_set_process_function (GstAudioAmplify * filter, gint
-    clipping_method, GstAudioFormat format)
-{
-  GstAudioAmplifyProcessFunc process;
-
-  /* set processing function */
-
-  process = gst_audio_amplify_process_function (clipping_method, format);
-  if (!process) {
-    GST_DEBUG ("wrong format");
-    return FALSE;
-  }
-
-  filter->process = process;
-  filter->clipping_method = clipping_method;
-  filter->format = format;
-
-  return TRUE;
-}
-
-static void
-gst_audio_amplify_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec)
-{
-  GstAudioAmplify *filter = GST_AUDIO_AMPLIFY (object);
-
-  switch (prop_id) {
-    case PROP_AMPLIFICATION:
-      filter->amplification = g_value_get_float (value);
-      gst_base_transform_set_passthrough (GST_BASE_TRANSFORM (filter),
-          filter->amplification == 1.0);
-      break;
-    case PROP_CLIPPING_METHOD:
-      gst_audio_amplify_set_process_function (filter, g_value_get_enum (value),
-          filter->format);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-static void
-gst_audio_amplify_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec)
-{
-  GstAudioAmplify *filter = GST_AUDIO_AMPLIFY (object);
-
-  switch (prop_id) {
-    case PROP_AMPLIFICATION:
-      g_value_set_float (value, filter->amplification);
-      break;
-    case PROP_CLIPPING_METHOD:
-      g_value_set_enum (value, filter->clipping_method);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-/* GstAudioFilter vmethod implementations */
-static gboolean
-gst_audio_amplify_setup (GstAudioFilter * base, const GstAudioInfo * info)
-{
-  GstAudioAmplify *filter = GST_AUDIO_AMPLIFY (base);
-
-  return gst_audio_amplify_set_process_function (filter,
-      filter->clipping_method, GST_AUDIO_INFO_FORMAT (info));
-}
-
-/* GstBaseTransform vmethod implementations */
-static GstFlowReturn
-gst_audio_amplify_transform_ip (GstBaseTransform * base, GstBuffer * buf)
-{
-  GstAudioAmplify *filter = GST_AUDIO_AMPLIFY (base);
-  guint num_samples;
-  GstClockTime timestamp, stream_time;
-  GstMapInfo map;
-
-  timestamp = GST_BUFFER_TIMESTAMP (buf);
-  stream_time =
-      gst_segment_to_stream_time (&base->segment, GST_FORMAT_TIME, timestamp);
-
-  GST_DEBUG_OBJECT (filter, "sync to %" GST_TIME_FORMAT,
-      GST_TIME_ARGS (timestamp));
-
-  if (GST_CLOCK_TIME_IS_VALID (stream_time))
-    gst_object_sync_values (GST_OBJECT (filter), stream_time);
-
-  if (G_UNLIKELY (GST_BUFFER_FLAG_IS_SET (buf, GST_BUFFER_FLAG_GAP)))
-    return GST_FLOW_OK;
-
-  gst_buffer_map (buf, &map, GST_MAP_READWRITE);
-  num_samples = map.size / GST_AUDIO_FILTER_BPS (filter);
-
-  filter->process (filter, map.data, num_samples);
-
-  gst_buffer_unmap (buf, &map);
-
-  return GST_FLOW_OK;
-}
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiochebband.c	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,660 +0,0 @@
-/* 
- * GStreamer
- * Copyright (C) 2007-2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-/* 
- * Chebyshev type 1 filter design based on
- * "The Scientist and Engineer's Guide to DSP", Chapter 20.
- * http://www.dspguide.com/
- *
- * For type 2 and Chebyshev filters in general read
- * http://en.wikipedia.org/wiki/Chebyshev_filter
- *
- * Transformation from lowpass to bandpass/bandreject:
- * http://docs.dewresearch.com/DspHelp/html/IDH_LinearSystems_LowpassToBandPassZ.htm
- * http://docs.dewresearch.com/DspHelp/html/IDH_LinearSystems_LowpassToBandStopZ.htm
- * 
- */
-
-/**
- * SECTION:element-audiochebband
- *
- * Attenuates all frequencies outside (bandpass) or inside (bandreject) of a frequency
- * band. The number of poles and the ripple parameter control the rolloff.
- *
- * This element has the advantage over the windowed sinc bandpass and bandreject filter that it is
- * much faster and produces almost as good results. It's only disadvantages are the highly
- * non-linear phase and the slower rolloff compared to a windowed sinc filter with a large kernel.
- *
- * For type 1 the ripple parameter specifies how much ripple in dB is allowed in the passband, i.e.
- * some frequencies in the passband will be amplified by that value. A higher ripple value will allow
- * a faster rolloff.
- *
- * For type 2 the ripple parameter specifies the stopband attenuation. In the stopband the gain will
- * be at most this value. A lower ripple value will allow a faster rolloff.
- *
- * As a special case, a Chebyshev type 1 filter with no ripple is a Butterworth filter.
- *
- * <note>
- * Be warned that a too large number of poles can produce noise. The most poles are possible with
- * a cutoff frequency at a quarter of the sampling rate.
- * </note>
- *
- * <refsect2>
- * <title>Example launch line</title>
- * |[
- * gst-launch-1.0 audiotestsrc freq=1500 ! audioconvert ! audiochebband mode=band-pass lower-frequency=1000 upper-frequenc=6000 poles=4 ! audioconvert ! alsasink
- * gst-launch-1.0 filesrc location="melo1.ogg" ! oggdemux ! vorbisdec ! audioconvert ! audiochebband mode=band-reject lower-frequency=1000 upper-frequency=4000 ripple=0.2 ! audioconvert ! alsasink
- * gst-launch-1.0 audiotestsrc wave=white-noise ! audioconvert ! audiochebband mode=band-pass lower-frequency=1000 upper-frequency=4000 type=2 ! audioconvert ! alsasink
- * ]|
- * </refsect2>
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <string.h>
-
-#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include <math.h>
-
-#include "math_compat.h"
-
-#include "audiochebband.h"
-
-#include "gst/glib-compat-private.h"
-
-#define GST_CAT_DEFAULT gst_audio_cheb_band_debug
-GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
-
-enum
-{
-  PROP_0,
-  PROP_MODE,
-  PROP_TYPE,
-  PROP_LOWER_FREQUENCY,
-  PROP_UPPER_FREQUENCY,
-  PROP_RIPPLE,
-  PROP_POLES
-};
-
-#define gst_audio_cheb_band_parent_class parent_class
-G_DEFINE_TYPE (GstAudioChebBand, gst_audio_cheb_band,
-    GST_TYPE_AUDIO_FX_BASE_IIR_FILTER);
-
-static void gst_audio_cheb_band_set_property (GObject * object,
-    guint prop_id, const GValue * value, GParamSpec * pspec);
-static void gst_audio_cheb_band_get_property (GObject * object,
-    guint prop_id, GValue * value, GParamSpec * pspec);
-static void gst_audio_cheb_band_finalize (GObject * object);
-
-static gboolean gst_audio_cheb_band_setup (GstAudioFilter * filter,
-    const GstAudioInfo * info);
-
-enum
-{
-  MODE_BAND_PASS = 0,
-  MODE_BAND_REJECT
-};
-
-#define GST_TYPE_AUDIO_CHEBYSHEV_FREQ_BAND_MODE (gst_audio_cheb_band_mode_get_type ())
-static GType
-gst_audio_cheb_band_mode_get_type (void)
-{
-  static GType gtype = 0;
-
-  if (gtype == 0) {
-    static const GEnumValue values[] = {
-      {MODE_BAND_PASS, "Band pass (default)",
-          "band-pass"},
-      {MODE_BAND_REJECT, "Band reject",
-          "band-reject"},
-      {0, NULL, NULL}
-    };
-
-    gtype = g_enum_register_static ("GstAudioChebBandMode", values);
-  }
-  return gtype;
-}
-
-/* GObject vmethod implementations */
-
-static void
-gst_audio_cheb_band_class_init (GstAudioChebBandClass * klass)
-{
-  GObjectClass *gobject_class = (GObjectClass *) klass;
-  GstElementClass *gstelement_class = (GstElementClass *) klass;
-  GstAudioFilterClass *filter_class = (GstAudioFilterClass *) klass;
-
-  GST_DEBUG_CATEGORY_INIT (gst_audio_cheb_band_debug, "audiochebband", 0,
-      "audiochebband element");
-
-  gobject_class->set_property = gst_audio_cheb_band_set_property;
-  gobject_class->get_property = gst_audio_cheb_band_get_property;
-  gobject_class->finalize = gst_audio_cheb_band_finalize;
-
-  g_object_class_install_property (gobject_class, PROP_MODE,
-      g_param_spec_enum ("mode", "Mode",
-          "Low pass or high pass mode", GST_TYPE_AUDIO_CHEBYSHEV_FREQ_BAND_MODE,
-          MODE_BAND_PASS,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-  g_object_class_install_property (gobject_class, PROP_TYPE,
-      g_param_spec_int ("type", "Type", "Type of the chebychev filter", 1, 2, 1,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-
-  /* FIXME: Don't use the complete possible range but restrict the upper boundary
-   * so automatically generated UIs can use a slider without */
-  g_object_class_install_property (gobject_class, PROP_LOWER_FREQUENCY,
-      g_param_spec_float ("lower-frequency", "Lower frequency",
-          "Start frequency of the band (Hz)", 0.0, 100000.0,
-          0.0,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-  g_object_class_install_property (gobject_class, PROP_UPPER_FREQUENCY,
-      g_param_spec_float ("upper-frequency", "Upper frequency",
-          "Stop frequency of the band (Hz)", 0.0, 100000.0, 0.0,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-  g_object_class_install_property (gobject_class, PROP_RIPPLE,
-      g_param_spec_float ("ripple", "Ripple", "Amount of ripple (dB)", 0.0,
-          200.0, 0.25,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-  /* FIXME: What to do about this upper boundary? With a frequencies near
-   * rate/4 32 poles are completely possible, with frequencies very low
-   * or very high 16 poles already produces only noise */
-  g_object_class_install_property (gobject_class, PROP_POLES,
-      g_param_spec_int ("poles", "Poles",
-          "Number of poles to use, will be rounded up to the next multiply of four",
-          4, 32, 4,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-
-  gst_element_class_set_static_metadata (gstelement_class,
-      "Band pass & band reject filter", "Filter/Effect/Audio",
-      "Chebyshev band pass and band reject filter",
-      "Sebastian Dröge <sebastian.droege@collabora.co.uk>");
-
-  filter_class->setup = GST_DEBUG_FUNCPTR (gst_audio_cheb_band_setup);
-}
-
-static void
-gst_audio_cheb_band_init (GstAudioChebBand * filter)
-{
-  filter->lower_frequency = filter->upper_frequency = 0.0;
-  filter->mode = MODE_BAND_PASS;
-  filter->type = 1;
-  filter->poles = 4;
-  filter->ripple = 0.25;
-
-  g_mutex_init (&filter->lock);
-}
-
-static void
-generate_biquad_coefficients (GstAudioChebBand * filter,
-    gint p, gint rate, gdouble * b0, gdouble * b1, gdouble * b2, gdouble * b3,
-    gdouble * b4, gdouble * a1, gdouble * a2, gdouble * a3, gdouble * a4)
-{
-  gint np = filter->poles / 2;
-  gdouble ripple = filter->ripple;
-
-  /* pole location in s-plane */
-  gdouble rp, ip;
-
-  /* zero location in s-plane */
-  gdouble iz = 0.0;
-
-  /* transfer function coefficients for the z-plane */
-  gdouble x0, x1, x2, y1, y2;
-  gint type = filter->type;
-
-  /* Calculate pole location for lowpass at frequency 1 */
-  {
-    gdouble angle = (G_PI / 2.0) * (2.0 * p - 1) / np;
-
-    rp = -sin (angle);
-    ip = cos (angle);
-  }
-
-  /* If we allow ripple, move the pole from the unit
-   * circle to an ellipse and keep cutoff at frequency 1 */
-  if (ripple > 0 && type == 1) {
-    gdouble es, vx;
-
-    es = sqrt (pow (10.0, ripple / 10.0) - 1.0);
-
-    vx = (1.0 / np) * asinh (1.0 / es);
-    rp = rp * sinh (vx);
-    ip = ip * cosh (vx);
-  } else if (type == 2) {
-    gdouble es, vx;
-
-    es = sqrt (pow (10.0, ripple / 10.0) - 1.0);
-    vx = (1.0 / np) * asinh (es);
-    rp = rp * sinh (vx);
-    ip = ip * cosh (vx);
-  }
-
-  /* Calculate inverse of the pole location to move from
-   * type I to type II */
-  if (type == 2) {
-    gdouble mag2 = rp * rp + ip * ip;
-
-    rp /= mag2;
-    ip /= mag2;
-  }
-
-  /* Calculate zero location for frequency 1 on the
-   * unit circle for type 2 */
-  if (type == 2) {
-    gdouble angle = G_PI / (np * 2.0) + ((p - 1) * G_PI) / (np);
-    gdouble mag2;
-
-    iz = cos (angle);
-    mag2 = iz * iz;
-    iz /= mag2;
-  }
-
-  /* Convert from s-domain to z-domain by
-   * using the bilinear Z-transform, i.e.
-   * substitute s by (2/t)*((z-1)/(z+1))
-   * with t = 2 * tan(0.5).
-   */
-  if (type == 1) {
-    gdouble t, m, d;
-
-    t = 2.0 * tan (0.5);
-    m = rp * rp + ip * ip;
-    d = 4.0 - 4.0 * rp * t + m * t * t;
-
-    x0 = (t * t) / d;
-    x1 = 2.0 * x0;
-    x2 = x0;
-    y1 = (8.0 - 2.0 * m * t * t) / d;
-    y2 = (-4.0 - 4.0 * rp * t - m * t * t) / d;
-  } else {
-    gdouble t, m, d;
-
-    t = 2.0 * tan (0.5);
-    m = rp * rp + ip * ip;
-    d = 4.0 - 4.0 * rp * t + m * t * t;
-
-    x0 = (t * t * iz * iz + 4.0) / d;
-    x1 = (-8.0 + 2.0 * iz * iz * t * t) / d;
-    x2 = x0;
-    y1 = (8.0 - 2.0 * m * t * t) / d;
-    y2 = (-4.0 - 4.0 * rp * t - m * t * t) / d;
-  }
-
-  /* Convert from lowpass at frequency 1 to either bandpass
-   * or band reject.
-   *
-   * For bandpass substitute z^(-1) with:
-   *
-   *   -2            -1
-   * -z   + alpha * z   - beta
-   * ----------------------------
-   *         -2            -1
-   * beta * z   - alpha * z   + 1
-   *
-   * alpha = (2*a*b)/(1+b)
-   * beta = (b-1)/(b+1)
-   * a = cos((w1 + w0)/2) / cos((w1 - w0)/2)
-   * b = tan(1/2) * cot((w1 - w0)/2)
-   *
-   * For bandreject substitute z^(-1) with:
-   * 
-   *  -2            -1
-   * z   - alpha * z   + beta
-   * ----------------------------
-   *         -2            -1
-   * beta * z   - alpha * z   + 1
-   *
-   * alpha = (2*a)/(1+b)
-   * beta = (1-b)/(1+b)
-   * a = cos((w1 + w0)/2) / cos((w1 - w0)/2)
-   * b = tan(1/2) * tan((w1 - w0)/2)
-   *
-   */
-  {
-    gdouble a, b, d;
-    gdouble alpha, beta;
-    gdouble w0 = 2.0 * G_PI * (filter->lower_frequency / rate);
-    gdouble w1 = 2.0 * G_PI * (filter->upper_frequency / rate);
-
-    if (filter->mode == MODE_BAND_PASS) {
-      a = cos ((w1 + w0) / 2.0) / cos ((w1 - w0) / 2.0);
-      b = tan (1.0 / 2.0) / tan ((w1 - w0) / 2.0);
-
-      alpha = (2.0 * a * b) / (1.0 + b);
-      beta = (b - 1.0) / (b + 1.0);
-
-      d = 1.0 + beta * (y1 - beta * y2);
-
-      *b0 = (x0 + beta * (-x1 + beta * x2)) / d;
-      *b1 = (alpha * (-2.0 * x0 + x1 + beta * x1 - 2.0 * beta * x2)) / d;
-      *b2 =
-          (-x1 - beta * beta * x1 + 2.0 * beta * (x0 + x2) +
-          alpha * alpha * (x0 - x1 + x2)) / d;
-      *b3 = (alpha * (x1 + beta * (-2.0 * x0 + x1) - 2.0 * x2)) / d;
-      *b4 = (beta * (beta * x0 - x1) + x2) / d;
-      *a1 = (alpha * (2.0 + y1 + beta * y1 - 2.0 * beta * y2)) / d;
-      *a2 =
-          (-y1 - beta * beta * y1 - alpha * alpha * (1.0 + y1 - y2) +
-          2.0 * beta * (-1.0 + y2)) / d;
-      *a3 = (alpha * (y1 + beta * (2.0 + y1) - 2.0 * y2)) / d;
-      *a4 = (-beta * beta - beta * y1 + y2) / d;
-    } else {
-      a = cos ((w1 + w0) / 2.0) / cos ((w1 - w0) / 2.0);
-      b = tan (1.0 / 2.0) * tan ((w1 - w0) / 2.0);
-
-      alpha = (2.0 * a) / (1.0 + b);
-      beta = (1.0 - b) / (1.0 + b);
-
-      d = -1.0 + beta * (beta * y2 + y1);
-
-      *b0 = (-x0 - beta * x1 - beta * beta * x2) / d;
-      *b1 = (alpha * (2.0 * x0 + x1 + beta * x1 + 2.0 * beta * x2)) / d;
-      *b2 =
-          (-x1 - beta * beta * x1 - 2.0 * beta * (x0 + x2) -
-          alpha * alpha * (x0 + x1 + x2)) / d;
-      *b3 = (alpha * (x1 + beta * (2.0 * x0 + x1) + 2.0 * x2)) / d;
-      *b4 = (-beta * beta * x0 - beta * x1 - x2) / d;
-      *a1 = (alpha * (-2.0 + y1 + beta * y1 + 2.0 * beta * y2)) / d;
-      *a2 =
-          -(y1 + beta * beta * y1 + 2.0 * beta * (-1.0 + y2) +
-          alpha * alpha * (-1.0 + y1 + y2)) / d;
-      *a3 = (alpha * (beta * (-2.0 + y1) + y1 + 2.0 * y2)) / d;
-      *a4 = -(-beta * beta + beta * y1 + y2) / d;
-    }
-  }
-}
-
-static void
-generate_coefficients (GstAudioChebBand * filter, const GstAudioInfo * info)
-{
-  gint rate;
-
-  if (info) {
-    rate = GST_AUDIO_INFO_RATE (info);
-  } else {
-    rate = GST_AUDIO_FILTER_RATE (filter);
-  }
-
-  if (rate == 0) {
-    gdouble *a = g_new0 (gdouble, 1);
-    gdouble *b = g_new0 (gdouble, 1);
-
-    a[0] = 1.0;
-    b[0] = 1.0;
-    gst_audio_fx_base_iir_filter_set_coefficients (GST_AUDIO_FX_BASE_IIR_FILTER
-        (filter), a, 1, b, 1);
-    GST_LOG_OBJECT (filter, "rate was not set yet");
-    return;
-  }
-
-  if (filter->upper_frequency <= filter->lower_frequency) {
-    gdouble *a = g_new0 (gdouble, 1);
-    gdouble *b = g_new0 (gdouble, 1);
-
-    a[0] = 1.0;
-    b[0] = (filter->mode == MODE_BAND_PASS) ? 0.0 : 1.0;
-    gst_audio_fx_base_iir_filter_set_coefficients (GST_AUDIO_FX_BASE_IIR_FILTER
-        (filter), a, 1, b, 1);
-
-    GST_LOG_OBJECT (filter, "frequency band had no or negative dimension");
-    return;
-  }
-
-  if (filter->upper_frequency > rate / 2) {
-    filter->upper_frequency = rate / 2;
-    GST_LOG_OBJECT (filter, "clipped upper frequency to nyquist frequency");
-  }
-
-  if (filter->lower_frequency < 0.0) {
-    filter->lower_frequency = 0.0;
-    GST_LOG_OBJECT (filter, "clipped lower frequency to 0.0");
-  }
-
-  /* Calculate coefficients for the chebyshev filter */
-  {
-    gint np = filter->poles;
-    gdouble *a, *b;
-    gint i, p;
-
-    a = g_new0 (gdouble, np + 5);
-    b = g_new0 (gdouble, np + 5);
-
-    /* Calculate transfer function coefficients */
-    a[4] = 1.0;
-    b[4] = 1.0;
-
-    for (p = 1; p <= np / 4; p++) {
-      gdouble b0, b1, b2, b3, b4, a1, a2, a3, a4;
-      gdouble *ta = g_new0 (gdouble, np + 5);
-      gdouble *tb = g_new0 (gdouble, np + 5);
-
-      generate_biquad_coefficients (filter, p, rate,
-          &b0, &b1, &b2, &b3, &b4, &a1, &a2, &a3, &a4);
-
-      memcpy (ta, a, sizeof (gdouble) * (np + 5));
-      memcpy (tb, b, sizeof (gdouble) * (np + 5));
-
-      /* add the new coefficients for the new two poles
-       * to the cascade by multiplication of the transfer
-       * functions */
-      for (i = 4; i < np + 5; i++) {
-        b[i] =
-            b0 * tb[i] + b1 * tb[i - 1] + b2 * tb[i - 2] + b3 * tb[i - 3] +
-            b4 * tb[i - 4];
-        a[i] =
-            ta[i] - a1 * ta[i - 1] - a2 * ta[i - 2] - a3 * ta[i - 3] -
-            a4 * ta[i - 4];
-      }
-      g_free (ta);
-      g_free (tb);
-    }
-
-    /* Move coefficients to the beginning of the array to move from
-     * the transfer function's coefficients to the difference
-     * equation's coefficients */
-    for (i = 0; i <= np; i++) {
-      a[i] = a[i + 4];
-      b[i] = b[i + 4];
-    }
-
-    /* Normalize to unity gain at frequency 0 and frequency
-     * 0.5 for bandreject and unity gain at band center frequency
-     * for bandpass */
-    if (filter->mode == MODE_BAND_REJECT) {
-      /* gain is sqrt(H(0)*H(0.5)) */
-
-      gdouble gain1 =
-          gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1, b, np + 1,
-          1.0, 0.0);
-      gdouble gain2 =
-          gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1, b, np + 1,
-          -1.0, 0.0);
-
-      gain1 = sqrt (gain1 * gain2);
-
-      for (i = 0; i <= np; i++) {
-        b[i] /= gain1;
-      }
-    } else {
-      /* gain is H(wc), wc = center frequency */
-
-      gdouble w1 = 2.0 * G_PI * (filter->lower_frequency / rate);
-      gdouble w2 = 2.0 * G_PI * (filter->upper_frequency / rate);
-      gdouble w0 = (w2 + w1) / 2.0;
-      gdouble zr = cos (w0), zi = sin (w0);
-      gdouble gain =
-          gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1, b, np + 1, zr,
-          zi);
-
-      for (i = 0; i <= np; i++) {
-        b[i] /= gain;
-      }
-    }
-
-    gst_audio_fx_base_iir_filter_set_coefficients (GST_AUDIO_FX_BASE_IIR_FILTER
-        (filter), a, np + 1, b, np + 1);
-
-    GST_LOG_OBJECT (filter,
-        "Generated IIR coefficients for the Chebyshev filter");
-    GST_LOG_OBJECT (filter,
-        "mode: %s, type: %d, poles: %d, lower-frequency: %.2f Hz, upper-frequency: %.2f Hz, ripple: %.2f dB",
-        (filter->mode == MODE_BAND_PASS) ? "band-pass" : "band-reject",
-        filter->type, filter->poles, filter->lower_frequency,
-        filter->upper_frequency, filter->ripple);
-
-    GST_LOG_OBJECT (filter, "%.2f dB gain @ 0Hz",
-        20.0 * log10 (gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1, b,
-                np + 1, 1.0, 0.0)));
-    {
-      gdouble w1 = 2.0 * G_PI * (filter->lower_frequency / rate);
-      gdouble w2 = 2.0 * G_PI * (filter->upper_frequency / rate);
-      gdouble w0 = (w2 + w1) / 2.0;
-      gdouble zr, zi;
-
-      zr = cos (w1);
-      zi = sin (w1);
-      GST_LOG_OBJECT (filter, "%.2f dB gain @ %dHz",
-          20.0 * log10 (gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1,
-                  b, np + 1, zr, zi)), (int) filter->lower_frequency);
-      zr = cos (w0);
-      zi = sin (w0);
-      GST_LOG_OBJECT (filter, "%.2f dB gain @ %dHz",
-          20.0 * log10 (gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1,
-                  b, np + 1, zr, zi)),
-          (int) ((filter->lower_frequency + filter->upper_frequency) / 2.0));
-      zr = cos (w2);
-      zi = sin (w2);
-      GST_LOG_OBJECT (filter, "%.2f dB gain @ %dHz",
-          20.0 * log10 (gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1,
-                  b, np + 1, zr, zi)), (int) filter->upper_frequency);
-    }
-    GST_LOG_OBJECT (filter, "%.2f dB gain @ %dHz",
-        20.0 * log10 (gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1, b,
-                np + 1, -1.0, 0.0)), rate / 2);
-  }
-}
-
-static void
-gst_audio_cheb_band_finalize (GObject * object)
-{
-  GstAudioChebBand *filter = GST_AUDIO_CHEB_BAND (object);
-
-  g_mutex_clear (&filter->lock);
-
-  G_OBJECT_CLASS (parent_class)->finalize (object);
-}
-
-static void
-gst_audio_cheb_band_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec)
-{
-  GstAudioChebBand *filter = GST_AUDIO_CHEB_BAND (object);
-
-  switch (prop_id) {
-    case PROP_MODE:
-      g_mutex_lock (&filter->lock);
-      filter->mode = g_value_get_enum (value);
-      generate_coefficients (filter, NULL);
-      g_mutex_unlock (&filter->lock);
-      break;
-    case PROP_TYPE:
-      g_mutex_lock (&filter->lock);
-      filter->type = g_value_get_int (value);
-      generate_coefficients (filter, NULL);
-      g_mutex_unlock (&filter->lock);
-      break;
-    case PROP_LOWER_FREQUENCY:
-      g_mutex_lock (&filter->lock);
-      filter->lower_frequency = g_value_get_float (value);
-      generate_coefficients (filter, NULL);
-      g_mutex_unlock (&filter->lock);
-      break;
-    case PROP_UPPER_FREQUENCY:
-      g_mutex_lock (&filter->lock);
-      filter->upper_frequency = g_value_get_float (value);
-      generate_coefficients (filter, NULL);
-      g_mutex_unlock (&filter->lock);
-      break;
-    case PROP_RIPPLE:
-      g_mutex_lock (&filter->lock);
-      filter->ripple = g_value_get_float (value);
-      generate_coefficients (filter, NULL);
-      g_mutex_unlock (&filter->lock);
-      break;
-    case PROP_POLES:
-      g_mutex_lock (&filter->lock);
-      filter->poles = GST_ROUND_UP_4 (g_value_get_int (value));
-      generate_coefficients (filter, NULL);
-      g_mutex_unlock (&filter->lock);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-static void
-gst_audio_cheb_band_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec)
-{
-  GstAudioChebBand *filter = GST_AUDIO_CHEB_BAND (object);
-
-  switch (prop_id) {
-    case PROP_MODE:
-      g_value_set_enum (value, filter->mode);
-      break;
-    case PROP_TYPE:
-      g_value_set_int (value, filter->type);
-      break;
-    case PROP_LOWER_FREQUENCY:
-      g_value_set_float (value, filter->lower_frequency);
-      break;
-    case PROP_UPPER_FREQUENCY:
-      g_value_set_float (value, filter->upper_frequency);
-      break;
-    case PROP_RIPPLE:
-      g_value_set_float (value, filter->ripple);
-      break;
-    case PROP_POLES:
-      g_value_set_int (value, filter->poles);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-/* GstAudioFilter vmethod implementations */
-
-static gboolean
-gst_audio_cheb_band_setup (GstAudioFilter * base, const GstAudioInfo * info)
-{
-  GstAudioChebBand *filter = GST_AUDIO_CHEB_BAND (base);
-
-  generate_coefficients (filter, info);
-
-  return GST_AUDIO_FILTER_CLASS (parent_class)->setup (base, info);
-}
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiochebband.h	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,64 +0,0 @@
-/*
- * GStreamer
- * Copyright (C) 2007-2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifndef __GST_AUDIO_CHEB_BAND_H__
-#define __GST_AUDIO_CHEB_BAND_H__
-
-#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include "audiofxbaseiirfilter.h"
-
-G_BEGIN_DECLS
-#define GST_TYPE_AUDIO_CHEB_BAND            (gst_audio_cheb_band_get_type())
-#define GST_AUDIO_CHEB_BAND(obj)            (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_AUDIO_CHEB_BAND,GstAudioChebBand))
-#define GST_IS_AUDIO_CHEB_BAND(obj)         (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_AUDIO_CHEB_BAND))
-#define GST_AUDIO_CHEB_BAND_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST((klass) ,GST_TYPE_AUDIO_CHEB_BAND,GstAudioChebBandClass))
-#define GST_IS_AUDIO_CHEB_BAND_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass) ,GST_TYPE_AUDIO_CHEB_BAND))
-#define GST_AUDIO_CHEB_BAND_GET_CLASS(obj)  (G_TYPE_INSTANCE_GET_CLASS((obj) ,GST_TYPE_AUDIO_CHEB_BAND,GstAudioChebBandClass))
-typedef struct _GstAudioChebBand GstAudioChebBand;
-typedef struct _GstAudioChebBandClass GstAudioChebBandClass;
-
-struct _GstAudioChebBand
-{
-  GstAudioFXBaseIIRFilter parent;
-
-  gint mode;
-  gint type;
-  gint poles;
-  gfloat lower_frequency;
-  gfloat upper_frequency;
-  gfloat ripple;
-
-  /* < private > */
-  GMutex lock;
-};
-
-struct _GstAudioChebBandClass
-{
-  GstAudioFXBaseIIRFilterClass parent;
-};
-
-GType gst_audio_cheb_band_get_type (void);
-
-G_END_DECLS
-#endif /* __GST_AUDIO_CHEB_BAND_H__ */
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiocheblimit.c	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,574 +0,0 @@
-/* 
- * GStreamer
- * Copyright (C) 2007-2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-/* 
- * Chebyshev type 1 filter design based on
- * "The Scientist and Engineer's Guide to DSP", Chapter 20.
- * http://www.dspguide.com/
- *
- * For type 2 and Chebyshev filters in general read
- * http://en.wikipedia.org/wiki/Chebyshev_filter
- *
- */
-
-/**
- * SECTION:element-audiocheblimit
- *
- * Attenuates all frequencies above the cutoff frequency (low-pass) or all frequencies below the
- * cutoff frequency (high-pass). The number of poles and the ripple parameter control the rolloff.
- *
- * This element has the advantage over the windowed sinc lowpass and highpass filter that it is
- * much faster and produces almost as good results. It's only disadvantages are the highly
- * non-linear phase and the slower rolloff compared to a windowed sinc filter with a large kernel.
- *
- * For type 1 the ripple parameter specifies how much ripple in dB is allowed in the passband, i.e.
- * some frequencies in the passband will be amplified by that value. A higher ripple value will allow
- * a faster rolloff.
- *
- * For type 2 the ripple parameter specifies the stopband attenuation. In the stopband the gain will
- * be at most this value. A lower ripple value will allow a faster rolloff.
- *
- * As a special case, a Chebyshev type 1 filter with no ripple is a Butterworth filter.
- *
- * <note><para>
- * Be warned that a too large number of poles can produce noise. The most poles are possible with
- * a cutoff frequency at a quarter of the sampling rate.
- * </para></note>
- *
- * <refsect2>
- * <title>Example launch line</title>
- * |[
- * gst-launch-1.0 audiotestsrc freq=1500 ! audioconvert ! audiocheblimit mode=low-pass cutoff=1000 poles=4 ! audioconvert ! alsasink
- * gst-launch-1.0 filesrc location="melo1.ogg" ! oggdemux ! vorbisdec ! audioconvert ! audiocheblimit mode=high-pass cutoff=400 ripple=0.2 ! audioconvert ! alsasink
- * gst-launch-1.0 audiotestsrc wave=white-noise ! audioconvert ! audiocheblimit mode=low-pass cutoff=800 type=2 ! audioconvert ! alsasink
- * ]|
- * </refsect2>
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <string.h>
-
-#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include <math.h>
-
-#include "math_compat.h"
-
-#include "audiocheblimit.h"
-
-#include "gst/glib-compat-private.h"
-
-#define GST_CAT_DEFAULT gst_audio_cheb_limit_debug
-GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
-
-enum
-{
-  PROP_0,
-  PROP_MODE,
-  PROP_TYPE,
-  PROP_CUTOFF,
-  PROP_RIPPLE,
-  PROP_POLES
-};
-
-#define gst_audio_cheb_limit_parent_class parent_class
-G_DEFINE_TYPE (GstAudioChebLimit,
-    gst_audio_cheb_limit, GST_TYPE_AUDIO_FX_BASE_IIR_FILTER);
-
-static void gst_audio_cheb_limit_set_property (GObject * object,
-    guint prop_id, const GValue * value, GParamSpec * pspec);
-static void gst_audio_cheb_limit_get_property (GObject * object,
-    guint prop_id, GValue * value, GParamSpec * pspec);
-static void gst_audio_cheb_limit_finalize (GObject * object);
-
-static gboolean gst_audio_cheb_limit_setup (GstAudioFilter * filter,
-    const GstAudioInfo * info);
-
-enum
-{
-  MODE_LOW_PASS = 0,
-  MODE_HIGH_PASS
-};
-
-#define GST_TYPE_AUDIO_CHEBYSHEV_FREQ_LIMIT_MODE (gst_audio_cheb_limit_mode_get_type ())
-static GType
-gst_audio_cheb_limit_mode_get_type (void)
-{
-  static GType gtype = 0;
-
-  if (gtype == 0) {
-    static const GEnumValue values[] = {
-      {MODE_LOW_PASS, "Low pass (default)",
-          "low-pass"},
-      {MODE_HIGH_PASS, "High pass",
-          "high-pass"},
-      {0, NULL, NULL}
-    };
-
-    gtype = g_enum_register_static ("GstAudioChebLimitMode", values);
-  }
-  return gtype;
-}
-
-/* GObject vmethod implementations */
-
-static void
-gst_audio_cheb_limit_class_init (GstAudioChebLimitClass * klass)
-{
-  GObjectClass *gobject_class = (GObjectClass *) klass;
-  GstElementClass *gstelement_class = (GstElementClass *) klass;
-  GstAudioFilterClass *filter_class = (GstAudioFilterClass *) klass;
-
-  GST_DEBUG_CATEGORY_INIT (gst_audio_cheb_limit_debug, "audiocheblimit", 0,
-      "audiocheblimit element");
-
-  gobject_class->set_property = gst_audio_cheb_limit_set_property;
-  gobject_class->get_property = gst_audio_cheb_limit_get_property;
-  gobject_class->finalize = gst_audio_cheb_limit_finalize;
-
-  g_object_class_install_property (gobject_class, PROP_MODE,
-      g_param_spec_enum ("mode", "Mode",
-          "Low pass or high pass mode",
-          GST_TYPE_AUDIO_CHEBYSHEV_FREQ_LIMIT_MODE, MODE_LOW_PASS,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-  g_object_class_install_property (gobject_class, PROP_TYPE,
-      g_param_spec_int ("type", "Type", "Type of the chebychev filter", 1, 2, 1,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-
-  /* FIXME: Don't use the complete possible range but restrict the upper boundary
-   * so automatically generated UIs can use a slider without */
-  g_object_class_install_property (gobject_class, PROP_CUTOFF,
-      g_param_spec_float ("cutoff", "Cutoff", "Cut off frequency (Hz)", 0.0,
-          100000.0, 0.0,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-  g_object_class_install_property (gobject_class, PROP_RIPPLE,
-      g_param_spec_float ("ripple", "Ripple", "Amount of ripple (dB)", 0.0,
-          200.0, 0.25,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-
-  /* FIXME: What to do about this upper boundary? With a cutoff frequency of
-   * rate/4 32 poles are completely possible, with a cutoff frequency very low
-   * or very high 16 poles already produces only noise */
-  g_object_class_install_property (gobject_class, PROP_POLES,
-      g_param_spec_int ("poles", "Poles",
-          "Number of poles to use, will be rounded up to the next even number",
-          2, 32, 4,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-
-  gst_element_class_set_static_metadata (gstelement_class,
-      "Low pass & high pass filter",
-      "Filter/Effect/Audio",
-      "Chebyshev low pass and high pass filter",
-      "Sebastian Dröge <sebastian.droege@collabora.co.uk>");
-
-  filter_class->setup = GST_DEBUG_FUNCPTR (gst_audio_cheb_limit_setup);
-}
-
-static void
-gst_audio_cheb_limit_init (GstAudioChebLimit * filter)
-{
-  filter->cutoff = 0.0;
-  filter->mode = MODE_LOW_PASS;
-  filter->type = 1;
-  filter->poles = 4;
-  filter->ripple = 0.25;
-
-  g_mutex_init (&filter->lock);
-}
-
-static void
-generate_biquad_coefficients (GstAudioChebLimit * filter,
-    gint p, gint rate, gdouble * b0, gdouble * b1, gdouble * b2,
-    gdouble * a1, gdouble * a2)
-{
-  gint np = filter->poles;
-  gdouble ripple = filter->ripple;
-
-  /* pole location in s-plane */
-  gdouble rp, ip;
-
-  /* zero location in s-plane */
-  gdouble iz = 0.0;
-
-  /* transfer function coefficients for the z-plane */
-  gdouble x0, x1, x2, y1, y2;
-  gint type = filter->type;
-
-  /* Calculate pole location for lowpass at frequency 1 */
-  {
-    gdouble angle = (G_PI / 2.0) * (2.0 * p - 1) / np;
-
-    rp = -sin (angle);
-    ip = cos (angle);
-  }
-
-  /* If we allow ripple, move the pole from the unit
-   * circle to an ellipse and keep cutoff at frequency 1 */
-  if (ripple > 0 && type == 1) {
-    gdouble es, vx;
-
-    es = sqrt (pow (10.0, ripple / 10.0) - 1.0);
-
-    vx = (1.0 / np) * asinh (1.0 / es);
-    rp = rp * sinh (vx);
-    ip = ip * cosh (vx);
-  } else if (type == 2) {
-    gdouble es, vx;
-
-    es = sqrt (pow (10.0, ripple / 10.0) - 1.0);
-    vx = (1.0 / np) * asinh (es);
-    rp = rp * sinh (vx);
-    ip = ip * cosh (vx);
-  }
-
-  /* Calculate inverse of the pole location to convert from
-   * type I to type II */
-  if (type == 2) {
-    gdouble mag2 = rp * rp + ip * ip;
-
-    rp /= mag2;
-    ip /= mag2;
-  }
-
-  /* Calculate zero location for frequency 1 on the
-   * unit circle for type 2 */
-  if (type == 2) {
-    gdouble angle = G_PI / (np * 2.0) + ((p - 1) * G_PI) / (np);
-    gdouble mag2;
-
-    iz = cos (angle);
-    mag2 = iz * iz;
-    iz /= mag2;
-  }
-
-  /* Convert from s-domain to z-domain by
-   * using the bilinear Z-transform, i.e.
-   * substitute s by (2/t)*((z-1)/(z+1))
-   * with t = 2 * tan(0.5).
-   */
-  if (type == 1) {
-    gdouble t, m, d;
-
-    t = 2.0 * tan (0.5);
-    m = rp * rp + ip * ip;
-    d = 4.0 - 4.0 * rp * t + m * t * t;
-
-    x0 = (t * t) / d;
-    x1 = 2.0 * x0;
-    x2 = x0;
-    y1 = (8.0 - 2.0 * m * t * t) / d;
-    y2 = (-4.0 - 4.0 * rp * t - m * t * t) / d;
-  } else {
-    gdouble t, m, d;
-
-    t = 2.0 * tan (0.5);
-    m = rp * rp + ip * ip;
-    d = 4.0 - 4.0 * rp * t + m * t * t;
-
-    x0 = (t * t * iz * iz + 4.0) / d;
-    x1 = (-8.0 + 2.0 * iz * iz * t * t) / d;
-    x2 = x0;
-    y1 = (8.0 - 2.0 * m * t * t) / d;
-    y2 = (-4.0 - 4.0 * rp * t - m * t * t) / d;
-  }
-
-  /* Convert from lowpass at frequency 1 to either lowpass
-   * or highpass.
-   *
-   * For lowpass substitute z^(-1) with:
-   *  -1
-   * z   - k
-   * ------------
-   *          -1
-   * 1 - k * z
-   *
-   * k = sin((1-w)/2) / sin((1+w)/2)
-   *
-   * For highpass substitute z^(-1) with:
-   *
-   *   -1
-   * -z   - k
-   * ------------
-   *          -1
-   * 1 + k * z
-   *
-   * k = -cos((1+w)/2) / cos((1-w)/2)
-   *
-   */
-  {
-    gdouble k, d;
-    gdouble omega = 2.0 * G_PI * (filter->cutoff / rate);
-
-    if (filter->mode == MODE_LOW_PASS)
-      k = sin ((1.0 - omega) / 2.0) / sin ((1.0 + omega) / 2.0);
-    else
-      k = -cos ((omega + 1.0) / 2.0) / cos ((omega - 1.0) / 2.0);
-
-    d = 1.0 + y1 * k - y2 * k * k;
-    *b0 = (x0 + k * (-x1 + k * x2)) / d;
-    *b1 = (x1 + k * k * x1 - 2.0 * k * (x0 + x2)) / d;
-    *b2 = (x0 * k * k - x1 * k + x2) / d;
-    *a1 = (2.0 * k + y1 + y1 * k * k - 2.0 * y2 * k) / d;
-    *a2 = (-k * k - y1 * k + y2) / d;
-
-    if (filter->mode == MODE_HIGH_PASS) {
-      *a1 = -*a1;
-      *b1 = -*b1;
-    }
-  }
-}
-
-static void
-generate_coefficients (GstAudioChebLimit * filter, const GstAudioInfo * info)
-{
-  gint rate;
-
-  if (info) {
-    rate = GST_AUDIO_INFO_RATE (info);
-  } else {
-    rate = GST_AUDIO_FILTER_RATE (filter);
-  }
-
-  GST_LOG_OBJECT (filter, "cutoff %f", filter->cutoff);
-
-  if (rate == 0) {
-    gdouble *a = g_new0 (gdouble, 1);
-    gdouble *b = g_new0 (gdouble, 1);
-
-    a[0] = 1.0;
-    b[0] = 1.0;
-    gst_audio_fx_base_iir_filter_set_coefficients (GST_AUDIO_FX_BASE_IIR_FILTER
-        (filter), a, 1, b, 1);
-
-    GST_LOG_OBJECT (filter, "rate was not set yet");
-    return;
-  }
-
-  if (filter->cutoff >= rate / 2.0) {
-    gdouble *a = g_new0 (gdouble, 1);
-    gdouble *b = g_new0 (gdouble, 1);
-
-    a[0] = 1.0;
-    b[0] = (filter->mode == MODE_LOW_PASS) ? 1.0 : 0.0;
-    gst_audio_fx_base_iir_filter_set_coefficients (GST_AUDIO_FX_BASE_IIR_FILTER
-        (filter), a, 1, b, 1);
-    GST_LOG_OBJECT (filter, "cutoff was higher than nyquist frequency");
-    return;
-  } else if (filter->cutoff <= 0.0) {
-    gdouble *a = g_new0 (gdouble, 1);
-    gdouble *b = g_new0 (gdouble, 1);
-
-    a[0] = 1.0;
-    b[0] = (filter->mode == MODE_LOW_PASS) ? 0.0 : 1.0;
-    gst_audio_fx_base_iir_filter_set_coefficients (GST_AUDIO_FX_BASE_IIR_FILTER
-        (filter), a, 1, b, 1);
-    GST_LOG_OBJECT (filter, "cutoff is lower than zero");
-    return;
-  }
-
-  /* Calculate coefficients for the chebyshev filter */
-  {
-    gint np = filter->poles;
-    gdouble *a, *b;
-    gint i, p;
-
-    a = g_new0 (gdouble, np + 3);
-    b = g_new0 (gdouble, np + 3);
-
-    /* Calculate transfer function coefficients */
-    a[2] = 1.0;
-    b[2] = 1.0;
-
-    for (p = 1; p <= np / 2; p++) {
-      gdouble b0, b1, b2, a1, a2;
-      gdouble *ta = g_new0 (gdouble, np + 3);
-      gdouble *tb = g_new0 (gdouble, np + 3);
-
-      generate_biquad_coefficients (filter, p, rate, &b0, &b1, &b2, &a1, &a2);
-
-      memcpy (ta, a, sizeof (gdouble) * (np + 3));
-      memcpy (tb, b, sizeof (gdouble) * (np + 3));
-
-      /* add the new coefficients for the new two poles
-       * to the cascade by multiplication of the transfer
-       * functions */
-      for (i = 2; i < np + 3; i++) {
-        b[i] = b0 * tb[i] + b1 * tb[i - 1] + b2 * tb[i - 2];
-        a[i] = ta[i] - a1 * ta[i - 1] - a2 * ta[i - 2];
-      }
-      g_free (ta);
-      g_free (tb);
-    }
-
-    /* Move coefficients to the beginning of the array to move from
-     * the transfer function's coefficients to the difference
-     * equation's coefficients */
-    for (i = 0; i <= np; i++) {
-      a[i] = a[i + 2];
-      b[i] = b[i + 2];
-    }
-
-    /* Normalize to unity gain at frequency 0 for lowpass
-     * and frequency 0.5 for highpass */
-    {
-      gdouble gain;
-
-      if (filter->mode == MODE_LOW_PASS)
-        gain =
-            gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1, b, np + 1,
-            1.0, 0.0);
-      else
-        gain =
-            gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1, b, np + 1,
-            -1.0, 0.0);
-
-      for (i = 0; i <= np; i++) {
-        b[i] /= gain;
-      }
-    }
-
-    gst_audio_fx_base_iir_filter_set_coefficients (GST_AUDIO_FX_BASE_IIR_FILTER
-        (filter), a, np + 1, b, np + 1);
-
-    GST_LOG_OBJECT (filter,
-        "Generated IIR coefficients for the Chebyshev filter");
-    GST_LOG_OBJECT (filter,
-        "mode: %s, type: %d, poles: %d, cutoff: %.2f Hz, ripple: %.2f dB",
-        (filter->mode == MODE_LOW_PASS) ? "low-pass" : "high-pass",
-        filter->type, filter->poles, filter->cutoff, filter->ripple);
-    GST_LOG_OBJECT (filter, "%.2f dB gain @ 0 Hz",
-        20.0 * log10 (gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1, b,
-                np + 1, 1.0, 0.0)));
-
-#ifndef GST_DISABLE_GST_DEBUG
-    {
-      gdouble wc = 2.0 * G_PI * (filter->cutoff / rate);
-      gdouble zr = cos (wc), zi = sin (wc);
-
-      GST_LOG_OBJECT (filter, "%.2f dB gain @ %d Hz",
-          20.0 * log10 (gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1,
-                  b, np + 1, zr, zi)), (int) filter->cutoff);
-    }
-#endif
-
-    GST_LOG_OBJECT (filter, "%.2f dB gain @ %d Hz",
-        20.0 * log10 (gst_audio_fx_base_iir_filter_calculate_gain (a, np + 1, b,
-                np + 1, -1.0, 0.0)), rate);
-  }
-}
-
-static void
-gst_audio_cheb_limit_finalize (GObject * object)
-{
-  GstAudioChebLimit *filter = GST_AUDIO_CHEB_LIMIT (object);
-
-  g_mutex_clear (&filter->lock);
-
-  G_OBJECT_CLASS (parent_class)->finalize (object);
-}
-
-static void
-gst_audio_cheb_limit_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec)
-{
-  GstAudioChebLimit *filter = GST_AUDIO_CHEB_LIMIT (object);
-
-  switch (prop_id) {
-    case PROP_MODE:
-      g_mutex_lock (&filter->lock);
-      filter->mode = g_value_get_enum (value);
-      generate_coefficients (filter, NULL);
-      g_mutex_unlock (&filter->lock);
-      break;
-    case PROP_TYPE:
-      g_mutex_lock (&filter->lock);
-      filter->type = g_value_get_int (value);
-      generate_coefficients (filter, NULL);
-      g_mutex_unlock (&filter->lock);
-      break;
-    case PROP_CUTOFF:
-      g_mutex_lock (&filter->lock);
-      filter->cutoff = g_value_get_float (value);
-      generate_coefficients (filter, NULL);
-      g_mutex_unlock (&filter->lock);
-      break;
-    case PROP_RIPPLE:
-      g_mutex_lock (&filter->lock);
-      filter->ripple = g_value_get_float (value);
-      generate_coefficients (filter, NULL);
-      g_mutex_unlock (&filter->lock);
-      break;
-    case PROP_POLES:
-      g_mutex_lock (&filter->lock);
-      filter->poles = GST_ROUND_UP_2 (g_value_get_int (value));
-      generate_coefficients (filter, NULL);
-      g_mutex_unlock (&filter->lock);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-static void
-gst_audio_cheb_limit_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec)
-{
-  GstAudioChebLimit *filter = GST_AUDIO_CHEB_LIMIT (object);
-
-  switch (prop_id) {
-    case PROP_MODE:
-      g_value_set_enum (value, filter->mode);
-      break;
-    case PROP_TYPE:
-      g_value_set_int (value, filter->type);
-      break;
-    case PROP_CUTOFF:
-      g_value_set_float (value, filter->cutoff);
-      break;
-    case PROP_RIPPLE:
-      g_value_set_float (value, filter->ripple);
-      break;
-    case PROP_POLES:
-      g_value_set_int (value, filter->poles);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-/* GstAudioFilter vmethod implementations */
-
-static gboolean
-gst_audio_cheb_limit_setup (GstAudioFilter * base, const GstAudioInfo * info)
-{
-  GstAudioChebLimit *filter = GST_AUDIO_CHEB_LIMIT (base);
-
-  generate_coefficients (filter, info);
-
-  return GST_AUDIO_FILTER_CLASS (parent_class)->setup (base, info);
-}
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiocheblimit.h	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,66 +0,0 @@
-/*
- * GStreamer
- * Copyright (C) 2007-2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifndef __GST_AUDIO_CHEB_LIMIT_H__
-#define __GST_AUDIO_CHEB_LIMIT_H__
-
-#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include "audiofxbaseiirfilter.h"
-
-G_BEGIN_DECLS
-
-#define GST_TYPE_AUDIO_CHEB_LIMIT            (gst_audio_cheb_limit_get_type())
-#define GST_AUDIO_CHEB_LIMIT(obj)            (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_AUDIO_CHEB_LIMIT,GstAudioChebLimit))
-#define GST_IS_AUDIO_CHEB_LIMIT(obj)         (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_AUDIO_CHEB_LIMIT))
-#define GST_AUDIO_CHEB_LIMIT_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST((klass) ,GST_TYPE_AUDIO_CHEB_LIMIT,GstAudioChebLimitClass))
-#define GST_IS_AUDIO_CHEB_LIMIT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass) ,GST_TYPE_AUDIO_CHEB_LIMIT))
-#define GST_AUDIO_CHEB_LIMIT_GET_CLASS(obj)  (G_TYPE_INSTANCE_GET_CLASS((obj) ,GST_TYPE_AUDIO_CHEB_LIMIT,GstAudioChebLimitClass))
-
-typedef struct _GstAudioChebLimit GstAudioChebLimit;
-typedef struct _GstAudioChebLimitClass GstAudioChebLimitClass;
-
-struct _GstAudioChebLimit
-{
-  GstAudioFXBaseIIRFilter parent;
-
-  gint mode;
-  gint type;
-  gint poles;
-  gfloat cutoff;
-  gfloat ripple;
-
-  /* < private > */
-  GMutex lock;
-};
-
-struct _GstAudioChebLimitClass
-{
-  GstAudioFXBaseIIRFilterClass parent;
-};
-
-GType gst_audio_cheb_limit_get_type (void);
-
-G_END_DECLS
-
-#endif /* __GST_AUDIO_CHEB_LIMIT_H__ */
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiodynamic.c	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,721 +0,0 @@
-/* 
- * GStreamer
- * Copyright (C) 2007 Sebastian Dröge <slomo@circular-chaos.org>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-/**
- * SECTION:element-audiodynamic
- *
- * This element can act as a compressor or expander. A compressor changes the
- * amplitude of all samples above a specific threshold with a specific ratio,
- * a expander does the same for all samples below a specific threshold. If
- * soft-knee mode is selected the ratio is applied smoothly.
- *
- * <refsect2>
- * <title>Example launch line</title>
- * |[
- * gst-launch-1.0 audiotestsrc wave=saw ! audiodynamic characteristics=soft-knee mode=compressor threshold=0.5 rate=0.5 ! alsasink
- * gst-launch-1.0 filesrc location="melo1.ogg" ! oggdemux ! vorbisdec ! audioconvert ! audiodynamic characteristics=hard-knee mode=expander threshold=0.2 rate=4.0 ! alsasink
- * gst-launch-1.0 audiotestsrc wave=saw ! audioconvert ! audiodynamic ! audioconvert ! alsasink
- * ]|
- * </refsect2>
- */
-
-/* TODO: Implement attack and release parameters */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include "audiodynamic.h"
-
-#define GST_CAT_DEFAULT gst_audio_dynamic_debug
-GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
-
-/* Filter signals and args */
-enum
-{
-  /* FILL ME */
-  LAST_SIGNAL
-};
-
-enum
-{
-  PROP_0,
-  PROP_CHARACTERISTICS,
-  PROP_MODE,
-  PROP_THRESHOLD,
-  PROP_RATIO
-};
-
-#define ALLOWED_CAPS \
-    "audio/x-raw,"                                                \
-    " format=(string) {"GST_AUDIO_NE(S16)","GST_AUDIO_NE(F32)"}," \
-    " rate=(int)[1,MAX],"                                         \
-    " channels=(int)[1,MAX],"                                     \
-    " layout=(string) {interleaved, non-interleaved}"
-
-G_DEFINE_TYPE (GstAudioDynamic, gst_audio_dynamic, GST_TYPE_AUDIO_FILTER);
-
-static void gst_audio_dynamic_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec);
-static void gst_audio_dynamic_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec);
-
-static gboolean gst_audio_dynamic_setup (GstAudioFilter * filter,
-    const GstAudioInfo * info);
-static GstFlowReturn gst_audio_dynamic_transform_ip (GstBaseTransform * base,
-    GstBuffer * buf);
-
-static void
-gst_audio_dynamic_transform_hard_knee_compressor_int (GstAudioDynamic * filter,
-    gint16 * data, guint num_samples);
-static void
-gst_audio_dynamic_transform_hard_knee_compressor_float (GstAudioDynamic *
-    filter, gfloat * data, guint num_samples);
-static void
-gst_audio_dynamic_transform_soft_knee_compressor_int (GstAudioDynamic * filter,
-    gint16 * data, guint num_samples);
-static void
-gst_audio_dynamic_transform_soft_knee_compressor_float (GstAudioDynamic *
-    filter, gfloat * data, guint num_samples);
-static void gst_audio_dynamic_transform_hard_knee_expander_int (GstAudioDynamic
-    * filter, gint16 * data, guint num_samples);
-static void
-gst_audio_dynamic_transform_hard_knee_expander_float (GstAudioDynamic * filter,
-    gfloat * data, guint num_samples);
-static void gst_audio_dynamic_transform_soft_knee_expander_int (GstAudioDynamic
-    * filter, gint16 * data, guint num_samples);
-static void
-gst_audio_dynamic_transform_soft_knee_expander_float (GstAudioDynamic * filter,
-    gfloat * data, guint num_samples);
-
-static GstAudioDynamicProcessFunc process_functions[] = {
-  (GstAudioDynamicProcessFunc)
-      gst_audio_dynamic_transform_hard_knee_compressor_int,
-  (GstAudioDynamicProcessFunc)
-      gst_audio_dynamic_transform_hard_knee_compressor_float,
-  (GstAudioDynamicProcessFunc)
-      gst_audio_dynamic_transform_soft_knee_compressor_int,
-  (GstAudioDynamicProcessFunc)
-      gst_audio_dynamic_transform_soft_knee_compressor_float,
-  (GstAudioDynamicProcessFunc)
-      gst_audio_dynamic_transform_hard_knee_expander_int,
-  (GstAudioDynamicProcessFunc)
-      gst_audio_dynamic_transform_hard_knee_expander_float,
-  (GstAudioDynamicProcessFunc)
-      gst_audio_dynamic_transform_soft_knee_expander_int,
-  (GstAudioDynamicProcessFunc)
-  gst_audio_dynamic_transform_soft_knee_expander_float
-};
-
-enum
-{
-  CHARACTERISTICS_HARD_KNEE = 0,
-  CHARACTERISTICS_SOFT_KNEE
-};
-
-#define GST_TYPE_AUDIO_DYNAMIC_CHARACTERISTICS (gst_audio_dynamic_characteristics_get_type ())
-static GType
-gst_audio_dynamic_characteristics_get_type (void)
-{
-  static GType gtype = 0;
-
-  if (gtype == 0) {
-    static const GEnumValue values[] = {
-      {CHARACTERISTICS_HARD_KNEE, "Hard Knee (default)",
-          "hard-knee"},
-      {CHARACTERISTICS_SOFT_KNEE, "Soft Knee (smooth)",
-          "soft-knee"},
-      {0, NULL, NULL}
-    };
-
-    gtype = g_enum_register_static ("GstAudioDynamicCharacteristics", values);
-  }
-  return gtype;
-}
-
-enum
-{
-  MODE_COMPRESSOR = 0,
-  MODE_EXPANDER
-};
-
-#define GST_TYPE_AUDIO_DYNAMIC_MODE (gst_audio_dynamic_mode_get_type ())
-static GType
-gst_audio_dynamic_mode_get_type (void)
-{
-  static GType gtype = 0;
-
-  if (gtype == 0) {
-    static const GEnumValue values[] = {
-      {MODE_COMPRESSOR, "Compressor (default)",
-          "compressor"},
-      {MODE_EXPANDER, "Expander", "expander"},
-      {0, NULL, NULL}
-    };
-
-    gtype = g_enum_register_static ("GstAudioDynamicMode", values);
-  }
-  return gtype;
-}
-
-static gboolean
-gst_audio_dynamic_set_process_function (GstAudioDynamic * filter,
-    const GstAudioInfo * info)
-{
-  gint func_index;
-
-  if (GST_AUDIO_INFO_FORMAT (info) == GST_AUDIO_FORMAT_UNKNOWN)
-    return FALSE;
-
-  func_index = (filter->mode == MODE_COMPRESSOR) ? 0 : 4;
-  func_index += (filter->characteristics == CHARACTERISTICS_HARD_KNEE) ? 0 : 2;
-  func_index += (GST_AUDIO_INFO_FORMAT (info) == GST_AUDIO_FORMAT_F32) ? 1 : 0;
-
-  if (func_index >= 0 && func_index < 8) {
-    filter->process = process_functions[func_index];
-    return TRUE;
-  }
-
-  return FALSE;
-}
-
-/* GObject vmethod implementations */
-
-static void
-gst_audio_dynamic_class_init (GstAudioDynamicClass * klass)
-{
-  GObjectClass *gobject_class;
-  GstElementClass *gstelement_class;
-  GstCaps *caps;
-
-  GST_DEBUG_CATEGORY_INIT (gst_audio_dynamic_debug, "audiodynamic", 0,
-      "audiodynamic element");
-
-  gobject_class = (GObjectClass *) klass;
-  gstelement_class = (GstElementClass *) klass;
-
-  gobject_class->set_property = gst_audio_dynamic_set_property;
-  gobject_class->get_property = gst_audio_dynamic_get_property;
-
-  g_object_class_install_property (gobject_class, PROP_CHARACTERISTICS,
-      g_param_spec_enum ("characteristics", "Characteristics",
-          "Selects whether the ratio should be applied smooth (soft-knee) "
-          "or hard (hard-knee).",
-          GST_TYPE_AUDIO_DYNAMIC_CHARACTERISTICS, CHARACTERISTICS_HARD_KNEE,
-          G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
-
-  g_object_class_install_property (gobject_class, PROP_MODE,
-      g_param_spec_enum ("mode", "Mode",
-          "Selects whether the filter should work on loud samples (compressor) or"
-          "quiet samples (expander).",
-          GST_TYPE_AUDIO_DYNAMIC_MODE, MODE_COMPRESSOR,
-          G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
-
-  g_object_class_install_property (gobject_class, PROP_THRESHOLD,
-      g_param_spec_float ("threshold", "Threshold",
-          "Threshold until the filter is activated", 0.0, 1.0,
-          0.0,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-
-  g_object_class_install_property (gobject_class, PROP_RATIO,
-      g_param_spec_float ("ratio", "Ratio",
-          "Ratio that should be applied", 0.0, G_MAXFLOAT,
-          1.0,
-          G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE | G_PARAM_STATIC_STRINGS));
-
-  gst_element_class_set_static_metadata (gstelement_class,
-      "Dynamic range controller", "Filter/Effect/Audio",
-      "Compressor and Expander", "Sebastian Dröge <slomo@circular-chaos.org>");
-
-  caps = gst_caps_from_string (ALLOWED_CAPS);
-  gst_audio_filter_class_add_pad_templates (GST_AUDIO_FILTER_CLASS (klass),
-      caps);
-  gst_caps_unref (caps);
-
-  GST_AUDIO_FILTER_CLASS (klass)->setup =
-      GST_DEBUG_FUNCPTR (gst_audio_dynamic_setup);
-
-  GST_BASE_TRANSFORM_CLASS (klass)->transform_ip =
-      GST_DEBUG_FUNCPTR (gst_audio_dynamic_transform_ip);
-  GST_BASE_TRANSFORM_CLASS (klass)->transform_ip_on_passthrough = FALSE;
-}
-
-static void
-gst_audio_dynamic_init (GstAudioDynamic * filter)
-{
-  filter->ratio = 1.0;
-  filter->threshold = 0.0;
-  filter->characteristics = CHARACTERISTICS_HARD_KNEE;
-  filter->mode = MODE_COMPRESSOR;
-  gst_base_transform_set_in_place (GST_BASE_TRANSFORM (filter), TRUE);
-  gst_base_transform_set_gap_aware (GST_BASE_TRANSFORM (filter), TRUE);
-}
-
-static void
-gst_audio_dynamic_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec)
-{
-  GstAudioDynamic *filter = GST_AUDIO_DYNAMIC (object);
-
-  switch (prop_id) {
-    case PROP_CHARACTERISTICS:
-      filter->characteristics = g_value_get_enum (value);
-      gst_audio_dynamic_set_process_function (filter,
-          GST_AUDIO_FILTER_INFO (filter));
-      break;
-    case PROP_MODE:
-      filter->mode = g_value_get_enum (value);
-      gst_audio_dynamic_set_process_function (filter,
-          GST_AUDIO_FILTER_INFO (filter));
-      break;
-    case PROP_THRESHOLD:
-      filter->threshold = g_value_get_float (value);
-      break;
-    case PROP_RATIO:
-      filter->ratio = g_value_get_float (value);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-static void
-gst_audio_dynamic_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec)
-{
-  GstAudioDynamic *filter = GST_AUDIO_DYNAMIC (object);
-
-  switch (prop_id) {
-    case PROP_CHARACTERISTICS:
-      g_value_set_enum (value, filter->characteristics);
-      break;
-    case PROP_MODE:
-      g_value_set_enum (value, filter->mode);
-      break;
-    case PROP_THRESHOLD:
-      g_value_set_float (value, filter->threshold);
-      break;
-    case PROP_RATIO:
-      g_value_set_float (value, filter->ratio);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-/* GstAudioFilter vmethod implementations */
-
-static gboolean
-gst_audio_dynamic_setup (GstAudioFilter * base, const GstAudioInfo * info)
-{
-  GstAudioDynamic *filter = GST_AUDIO_DYNAMIC (base);
-  gboolean ret = TRUE;
-
-  ret = gst_audio_dynamic_set_process_function (filter, info);
-
-  return ret;
-}
-
-static void
-gst_audio_dynamic_transform_hard_knee_compressor_int (GstAudioDynamic * filter,
-    gint16 * data, guint num_samples)
-{
-  glong val;
-  glong thr_p = filter->threshold * G_MAXINT16;
-  glong thr_n = filter->threshold * G_MININT16;
-
-  /* Nothing to do for us if ratio is 1.0 or if the threshold
-   * equals 1.0. */
-  if (filter->threshold == 1.0 || filter->ratio == 1.0)
-    return;
-
-  for (; num_samples; num_samples--) {
-    val = *data;
-
-    if (val > thr_p) {
-      val = thr_p + (val - thr_p) * filter->ratio;
-    } else if (val < thr_n) {
-      val = thr_n + (val - thr_n) * filter->ratio;
-    }
-    *data++ = (gint16) CLAMP (val, G_MININT16, G_MAXINT16);
-  }
-}
-
-static void
-gst_audio_dynamic_transform_hard_knee_compressor_float (GstAudioDynamic *
-    filter, gfloat * data, guint num_samples)
-{
-  gdouble val, threshold = filter->threshold;
-
-  /* Nothing to do for us if ratio == 1.0.
-   * As float values can be above 1.0 we have to do something
-   * if threshold is greater than 1.0. */
-  if (filter->ratio == 1.0)
-    return;
-
-  for (; num_samples; num_samples--) {
-    val = *data;
-
-    if (val > threshold) {
-      val = threshold + (val - threshold) * filter->ratio;
-    } else if (val < -threshold) {
-      val = -threshold + (val + threshold) * filter->ratio;
-    }
-    *data++ = (gfloat) val;
-  }
-}
-
-static void
-gst_audio_dynamic_transform_soft_knee_compressor_int (GstAudioDynamic * filter,
-    gint16 * data, guint num_samples)
-{
-  glong val;
-  glong thr_p = filter->threshold * G_MAXINT16;
-  glong thr_n = filter->threshold * G_MININT16;
-  gdouble a_p, b_p, c_p;
-  gdouble a_n, b_n, c_n;
-
-  /* Nothing to do for us if ratio is 1.0 or if the threshold
-   * equals 1.0. */
-  if (filter->threshold == 1.0 || filter->ratio == 1.0)
-    return;
-
-  /* We build a 2nd degree polynomial here for
-   * values greater than threshold or small than
-   * -threshold with:
-   * f(t) = t, f'(t) = 1, f'(m) = r
-   * =>
-   * a = (1-r)/(2*(t-m))
-   * b = (r*t - m)/(t-m)
-   * c = t * (1 - b - a*t)
-   * f(x) = ax^2 + bx + c
-   */
-
-  /* shouldn't happen because this would only be the case
-   * for threshold == 1.0 which we catch above */
-  g_assert (thr_p - G_MAXINT16 != 0);
-  g_assert (thr_n - G_MININT != 0);
-
-  a_p = (1 - filter->ratio) / (2 * (thr_p - G_MAXINT16));
-  b_p = (filter->ratio * thr_p - G_MAXINT16) / (thr_p - G_MAXINT16);
-  c_p = thr_p * (1 - b_p - a_p * thr_p);
-  a_n = (1 - filter->ratio) / (2 * (thr_n - G_MININT16));
-  b_n = (filter->ratio * thr_n - G_MININT16) / (thr_n - G_MININT16);
-  c_n = thr_n * (1 - b_n - a_n * thr_n);
-
-  for (; num_samples; num_samples--) {
-    val = *data;
-
-    if (val > thr_p) {
-      val = a_p * val * val + b_p * val + c_p;
-    } else if (val < thr_n) {
-      val = a_n * val * val + b_n * val + c_n;
-    }
-    *data++ = (gint16) CLAMP (val, G_MININT16, G_MAXINT16);
-  }
-}
-
-static void
-gst_audio_dynamic_transform_soft_knee_compressor_float (GstAudioDynamic *
-    filter, gfloat * data, guint num_samples)
-{
-  gdouble val;
-  gdouble threshold = filter->threshold;
-  gdouble a_p, b_p, c_p;
-  gdouble a_n, b_n, c_n;
-
-  /* Nothing to do for us if ratio == 1.0.
-   * As float values can be above 1.0 we have to do something
-   * if threshold is greater than 1.0. */
-  if (filter->ratio == 1.0)
-    return;
-
-  /* We build a 2nd degree polynomial here for
-   * values greater than threshold or small than
-   * -threshold with:
-   * f(t) = t, f'(t) = 1, f'(m) = r
-   * =>
-   * a = (1-r)/(2*(t-m))
-   * b = (r*t - m)/(t-m)
-   * c = t * (1 - b - a*t)
-   * f(x) = ax^2 + bx + c
-   */
-
-  /* FIXME: If treshold is the same as the maximum
-   * we need to raise it a bit to prevent
-   * division by zero. */
-  if (threshold == 1.0)
-    threshold = 1.0 + 0.00001;
-
-  a_p = (1.0 - filter->ratio) / (2.0 * (threshold - 1.0));
-  b_p = (filter->ratio * threshold - 1.0) / (threshold - 1.0);
-  c_p = threshold * (1.0 - b_p - a_p * threshold);
-  a_n = (1.0 - filter->ratio) / (2.0 * (-threshold + 1.0));
-  b_n = (-filter->ratio * threshold + 1.0) / (-threshold + 1.0);
-  c_n = -threshold * (1.0 - b_n + a_n * threshold);
-
-  for (; num_samples; num_samples--) {
-    val = *data;
-
-    if (val > 1.0) {
-      val = 1.0 + (val - 1.0) * filter->ratio;
-    } else if (val > threshold) {
-      val = a_p * val * val + b_p * val + c_p;
-    } else if (val < -1.0) {
-      val = -1.0 + (val + 1.0) * filter->ratio;
-    } else if (val < -threshold) {
-      val = a_n * val * val + b_n * val + c_n;
-    }
-    *data++ = (gfloat) val;
-  }
-}
-
-static void
-gst_audio_dynamic_transform_hard_knee_expander_int (GstAudioDynamic * filter,
-    gint16 * data, guint num_samples)
-{
-  glong val;
-  glong thr_p = filter->threshold * G_MAXINT16;
-  glong thr_n = filter->threshold * G_MININT16;
-  gdouble zero_p, zero_n;
-
-  /* Nothing to do for us here if threshold equals 0.0
-   * or ratio equals 1.0 */
-  if (filter->threshold == 0.0 || filter->ratio == 1.0)
-    return;
-
-  /* zero crossing of our function */
-  if (filter->ratio != 0.0) {
-    zero_p = thr_p - thr_p / filter->ratio;
-    zero_n = thr_n - thr_n / filter->ratio;
-  } else {
-    zero_p = zero_n = 0.0;
-  }
-
-  if (zero_p < 0.0)
-    zero_p = 0.0;
-  if (zero_n > 0.0)
-    zero_n = 0.0;
-
-  for (; num_samples; num_samples--) {
-    val = *data;
-
-    if (val < thr_p && val > zero_p) {
-      val = filter->ratio * val + thr_p * (1 - filter->ratio);
-    } else if ((val <= zero_p && val > 0) || (val >= zero_n && val < 0)) {
-      val = 0;
-    } else if (val > thr_n && val < zero_n) {
-      val = filter->ratio * val + thr_n * (1 - filter->ratio);
-    }
-    *data++ = (gint16) CLAMP (val, G_MININT16, G_MAXINT16);
-  }
-}
-
-static void
-gst_audio_dynamic_transform_hard_knee_expander_float (GstAudioDynamic * filter,
-    gfloat * data, guint num_samples)
-{
-  gdouble val, threshold = filter->threshold, zero;
-
-  /* Nothing to do for us here if threshold equals 0.0
-   * or ratio equals 1.0 */
-  if (filter->threshold == 0.0 || filter->ratio == 1.0)
-    return;
-
-  /* zero crossing of our function */
-  if (filter->ratio != 0.0)
-    zero = threshold - threshold / filter->ratio;
-  else
-    zero = 0.0;
-
-  if (zero < 0.0)
-    zero = 0.0;
-
-  for (; num_samples; num_samples--) {
-    val = *data;
-
-    if (val < threshold && val > zero) {
-      val = filter->ratio * val + threshold * (1.0 - filter->ratio);
-    } else if ((val <= zero && val > 0.0) || (val >= -zero && val < 0.0)) {
-      val = 0.0;
-    } else if (val > -threshold && val < -zero) {
-      val = filter->ratio * val - threshold * (1.0 - filter->ratio);
-    }
-    *data++ = (gfloat) val;
-  }
-}
-
-static void
-gst_audio_dynamic_transform_soft_knee_expander_int (GstAudioDynamic * filter,
-    gint16 * data, guint num_samples)
-{
-  glong val;
-  glong thr_p = filter->threshold * G_MAXINT16;
-  glong thr_n = filter->threshold * G_MININT16;
-  gdouble zero_p, zero_n;
-  gdouble a_p, b_p, c_p;
-  gdouble a_n, b_n, c_n;
-  gdouble r2;
-
-  /* Nothing to do for us here if threshold equals 0.0
-   * or ratio equals 1.0 */
-  if (filter->threshold == 0.0 || filter->ratio == 1.0)
-    return;
-
-  /* zero crossing of our function */
-  zero_p = (thr_p * (filter->ratio - 1.0)) / (1.0 + filter->ratio);
-  zero_n = (thr_n * (filter->ratio - 1.0)) / (1.0 + filter->ratio);
-
-  if (zero_p < 0.0)
-    zero_p = 0.0;
-  if (zero_n > 0.0)
-    zero_n = 0.0;
-
-  /* shouldn't happen as this would only happen
-   * with threshold == 0.0 */
-  g_assert (thr_p != 0);
-  g_assert (thr_n != 0);
-
-  /* We build a 2n degree polynomial here for values between
-   * 0 and threshold or 0 and -threshold with:
-   * f(t) = t, f'(t) = 1, f(z) = 0, f'(z) = r
-   * z between 0 and t
-   * =>
-   * a = (1 - r^2) / (4 * t)
-   * b = (1 + r^2) / 2
-   * c = t * (1.0 - b - a*t)
-   * f(x) = ax^2 + bx + c */
-  r2 = filter->ratio * filter->ratio;
-  a_p = (1.0 - r2) / (4.0 * thr_p);
-  b_p = (1.0 + r2) / 2.0;
-  c_p = thr_p * (1.0 - b_p - a_p * thr_p);
-  a_n = (1.0 - r2) / (4.0 * thr_n);
-  b_n = (1.0 + r2) / 2.0;
-  c_n = thr_n * (1.0 - b_n - a_n * thr_n);
-
-  for (; num_samples; num_samples--) {
-    val = *data;
-
-    if (val < thr_p && val > zero_p) {
-      val = a_p * val * val + b_p * val + c_p;
-    } else if ((val <= zero_p && val > 0) || (val >= zero_n && val < 0)) {
-      val = 0;
-    } else if (val > thr_n && val < zero_n) {
-      val = a_n * val * val + b_n * val + c_n;
-    }
-    *data++ = (gint16) CLAMP (val, G_MININT16, G_MAXINT16);
-  }
-}
-
-static void
-gst_audio_dynamic_transform_soft_knee_expander_float (GstAudioDynamic * filter,
-    gfloat * data, guint num_samples)
-{
-  gdouble val;
-  gdouble threshold = filter->threshold;
-  gdouble zero;
-  gdouble a_p, b_p, c_p;
-  gdouble a_n, b_n, c_n;
-  gdouble r2;
-
-  /* Nothing to do for us here if threshold equals 0.0
-   * or ratio equals 1.0 */
-  if (filter->threshold == 0.0 || filter->ratio == 1.0)
-    return;
-
-  /* zero crossing of our function */
-  zero = (threshold * (filter->ratio - 1.0)) / (1.0 + filter->ratio);
-
-  if (zero < 0.0)
-    zero = 0.0;
-
-  /* shouldn't happen as this only happens with
-   * threshold == 0.0 */
-  g_assert (threshold != 0.0);
-
-  /* We build a 2n degree polynomial here for values between
-   * 0 and threshold or 0 and -threshold with:
-   * f(t) = t, f'(t) = 1, f(z) = 0, f'(z) = r
-   * z between 0 and t
-   * =>
-   * a = (1 - r^2) / (4 * t)
-   * b = (1 + r^2) / 2
-   * c = t * (1.0 - b - a*t)
-   * f(x) = ax^2 + bx + c */
-  r2 = filter->ratio * filter->ratio;
-  a_p = (1.0 - r2) / (4.0 * threshold);
-  b_p = (1.0 + r2) / 2.0;
-  c_p = threshold * (1.0 - b_p - a_p * threshold);
-  a_n = (1.0 - r2) / (-4.0 * threshold);
-  b_n = (1.0 + r2) / 2.0;
-  c_n = -threshold * (1.0 - b_n + a_n * threshold);
-
-  for (; num_samples; num_samples--) {
-    val = *data;
-
-    if (val < threshold && val > zero) {
-      val = a_p * val * val + b_p * val + c_p;
-    } else if ((val <= zero && val > 0.0) || (val >= -zero && val < 0.0)) {
-      val = 0.0;
-    } else if (val > -threshold && val < -zero) {
-      val = a_n * val * val + b_n * val + c_n;
-    }
-    *data++ = (gfloat) val;
-  }
-}
-
-/* GstBaseTransform vmethod implementations */
-static GstFlowReturn
-gst_audio_dynamic_transform_ip (GstBaseTransform * base, GstBuffer * buf)
-{
-  GstAudioDynamic *filter = GST_AUDIO_DYNAMIC (base);
-  guint num_samples;
-  GstClockTime timestamp, stream_time;
-  GstMapInfo map;
-
-  timestamp = GST_BUFFER_TIMESTAMP (buf);
-  stream_time =
-      gst_segment_to_stream_time (&base->segment, GST_FORMAT_TIME, timestamp);
-
-  GST_DEBUG_OBJECT (filter, "sync to %" GST_TIME_FORMAT,
-      GST_TIME_ARGS (timestamp));
-
-  if (GST_CLOCK_TIME_IS_VALID (stream_time))
-    gst_object_sync_values (GST_OBJECT (filter), stream_time);
-
-  if (G_UNLIKELY (GST_BUFFER_FLAG_IS_SET (buf, GST_BUFFER_FLAG_GAP)))
-    return GST_FLOW_OK;
-
-  gst_buffer_map (buf, &map, GST_MAP_READWRITE);
-  num_samples = map.size / GST_AUDIO_FILTER_BPS (filter);
-
-  filter->process (filter, map.data, num_samples);
-
-  gst_buffer_unmap (buf, &map);
-
-  return GST_FLOW_OK;
-}
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiodynamic.h	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,65 +0,0 @@
-/*
- * GStreamer
- * Copyright (C) 2007 Sebastian Dröge <slomo@circular-chaos.org>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifndef __GST_AUDIO_DYNAMIC_H__
-#define __GST_AUDIO_DYNAMIC_H__
-
-#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
-#include <gst/audio/gstaudiofilter.h>
-
-G_BEGIN_DECLS
-
-#define GST_TYPE_AUDIO_DYNAMIC            (gst_audio_dynamic_get_type())
-#define GST_AUDIO_DYNAMIC(obj)            (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_AUDIO_DYNAMIC,GstAudioDynamic))
-#define GST_IS_AUDIO_DYNAMIC(obj)         (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_AUDIO_DYNAMIC))
-#define GST_AUDIO_DYNAMIC_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST((klass) ,GST_TYPE_AUDIO_DYNAMIC,GstAudioDynamicClass))
-#define GST_IS_AUDIO_DYNAMIC_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass) ,GST_TYPE_AUDIO_DYNAMIC))
-#define GST_AUDIO_DYNAMIC_GET_CLASS(obj)  (G_TYPE_INSTANCE_GET_CLASS((obj) ,GST_TYPE_AUDIO_DYNAMIC,GstAudioDynamicClass))
-typedef struct _GstAudioDynamic GstAudioDynamic;
-typedef struct _GstAudioDynamicClass GstAudioDynamicClass;
-
-typedef void (*GstAudioDynamicProcessFunc) (GstAudioDynamic *, guint8 *, guint);
-
-struct _GstAudioDynamic
-{
-  GstAudioFilter audiofilter;
-
-  gfloat degree;
-
-  /* < private > */
-  GstAudioDynamicProcessFunc process;
-  gint characteristics;
-  gint mode;
-  gfloat threshold;
-  gfloat ratio;
-};
-
-struct _GstAudioDynamicClass
-{
-  GstAudioFilterClass parent;
-};
-
-GType gst_audio_dynamic_get_type (void);
-
-G_END_DECLS
-
-#endif /* __GST_AUDIO_DYNAMIC_H__ */
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audioecho.c	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,415 +0,0 @@
-/* 
- * GStreamer
- * Copyright (C) 2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-/**
- * SECTION:element-audioecho
- *
- * audioecho adds an echo or (simple) reverb effect to an audio stream. The echo
- * delay, intensity and the percentage of feedback can be configured.
- *
- * For getting an echo effect you have to set the delay to a larger value,
- * for example 200ms and more. Everything below will result in a simple
- * reverb effect, which results in a slightly metallic sound.
- *
- * Use the max-delay property to set the maximum amount of delay that
- * will be used. This can only be set before going to the PAUSED or PLAYING
- * state and will be set to the current delay by default.
- *
- * <refsect2>
- * <title>Example launch line</title>
- * |[
- * gst-launch-1.0 filesrc location="melo1.ogg" ! audioconvert ! audioecho delay=500000000 intensity=0.6 feedback=0.4 ! audioconvert ! autoaudiosink
- * gst-launch-1.0 filesrc location="melo1.ogg" ! decodebin ! audioconvert ! audioecho delay=50000000 intensity=0.6 feedback=0.4 ! audioconvert ! autoaudiosink
- * ]|
- * </refsect2>
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include "audioecho.h"
-
-#define GST_CAT_DEFAULT gst_audio_echo_debug
-GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
-
-enum
-{
-  PROP_0,
-  PROP_DELAY,
-  PROP_MAX_DELAY,
-  PROP_INTENSITY,
-  PROP_FEEDBACK
-};
-
-#define ALLOWED_CAPS \
-    "audio/x-raw,"                                                 \
-    " format=(string) {"GST_AUDIO_NE(F32)","GST_AUDIO_NE(F64)"}, " \
-    " rate=(int)[1,MAX],"                                          \
-    " channels=(int)[1,MAX],"                                      \
-    " layout=(string) interleaved"
-
-#define gst_audio_echo_parent_class parent_class
-G_DEFINE_TYPE (GstAudioEcho, gst_audio_echo, GST_TYPE_AUDIO_FILTER);
-
-static void gst_audio_echo_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec);
-static void gst_audio_echo_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec);
-static void gst_audio_echo_finalize (GObject * object);
-
-static gboolean gst_audio_echo_setup (GstAudioFilter * self,
-    const GstAudioInfo * info);
-static gboolean gst_audio_echo_stop (GstBaseTransform * base);
-static GstFlowReturn gst_audio_echo_transform_ip (GstBaseTransform * base,
-    GstBuffer * buf);
-
-static void gst_audio_echo_transform_float (GstAudioEcho * self,
-    gfloat * data, guint num_samples);
-static void gst_audio_echo_transform_double (GstAudioEcho * self,
-    gdouble * data, guint num_samples);
-
-/* GObject vmethod implementations */
-
-static void
-gst_audio_echo_class_init (GstAudioEchoClass * klass)
-{
-  GObjectClass *gobject_class = (GObjectClass *) klass;
-  GstElementClass *gstelement_class = (GstElementClass *) klass;
-  GstBaseTransformClass *basetransform_class = (GstBaseTransformClass *) klass;
-  GstAudioFilterClass *audioself_class = (GstAudioFilterClass *) klass;
-  GstCaps *caps;
-
-  GST_DEBUG_CATEGORY_INIT (gst_audio_echo_debug, "audioecho", 0,
-      "audioecho element");
-
-  gobject_class->set_property = gst_audio_echo_set_property;
-  gobject_class->get_property = gst_audio_echo_get_property;
-  gobject_class->finalize = gst_audio_echo_finalize;
-
-  g_object_class_install_property (gobject_class, PROP_DELAY,
-      g_param_spec_uint64 ("delay", "Delay",
-          "Delay of the echo in nanoseconds", 1, G_MAXUINT64,
-          1, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS
-          | GST_PARAM_CONTROLLABLE));
-
-  g_object_class_install_property (gobject_class, PROP_MAX_DELAY,
-      g_param_spec_uint64 ("max-delay", "Maximum Delay",
-          "Maximum delay of the echo in nanoseconds"
-          " (can't be changed in PLAYING or PAUSED state)",
-          1, G_MAXUINT64, 1,
-          G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS |
-          GST_PARAM_MUTABLE_READY));
-
-  g_object_class_install_property (gobject_class, PROP_INTENSITY,
-      g_param_spec_float ("intensity", "Intensity",
-          "Intensity of the echo", 0.0, 1.0,
-          0.0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS
-          | GST_PARAM_CONTROLLABLE));
-
-  g_object_class_install_property (gobject_class, PROP_FEEDBACK,
-      g_param_spec_float ("feedback", "Feedback",
-          "Amount of feedback", 0.0, 1.0,
-          0.0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS
-          | GST_PARAM_CONTROLLABLE));
-
-  gst_element_class_set_static_metadata (gstelement_class, "Audio echo",
-      "Filter/Effect/Audio",
-      "Adds an echo or reverb effect to an audio stream",
-      "Sebastian Dröge <sebastian.droege@collabora.co.uk>");
-
-  caps = gst_caps_from_string (ALLOWED_CAPS);
-  gst_audio_filter_class_add_pad_templates (GST_AUDIO_FILTER_CLASS (klass),
-      caps);
-  gst_caps_unref (caps);
-
-  audioself_class->setup = GST_DEBUG_FUNCPTR (gst_audio_echo_setup);
-  basetransform_class->transform_ip =
-      GST_DEBUG_FUNCPTR (gst_audio_echo_transform_ip);
-  basetransform_class->stop = GST_DEBUG_FUNCPTR (gst_audio_echo_stop);
-}
-
-static void
-gst_audio_echo_init (GstAudioEcho * self)
-{
-  self->delay = 1;
-  self->max_delay = 1;
-  self->intensity = 0.0;
-  self->feedback = 0.0;
-
-  g_mutex_init (&self->lock);
-
-  gst_base_transform_set_in_place (GST_BASE_TRANSFORM (self), TRUE);
-}
-
-static void
-gst_audio_echo_finalize (GObject * object)
-{
-  GstAudioEcho *self = GST_AUDIO_ECHO (object);
-
-  g_free (self->buffer);
-  self->buffer = NULL;
-
-  g_mutex_clear (&self->lock);
-
-  G_OBJECT_CLASS (parent_class)->finalize (object);
-}
-
-static void
-gst_audio_echo_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec)
-{
-  GstAudioEcho *self = GST_AUDIO_ECHO (object);
-
-  switch (prop_id) {
-    case PROP_DELAY:{
-      guint64 max_delay, delay;
-      guint rate;
-
-      g_mutex_lock (&self->lock);
-      delay = g_value_get_uint64 (value);
-      max_delay = self->max_delay;
-
-      if (delay > max_delay && GST_STATE (self) > GST_STATE_READY) {
-        GST_WARNING_OBJECT (self, "New delay (%" GST_TIME_FORMAT ") "
-            "is larger than maximum delay (%" GST_TIME_FORMAT ")",
-            GST_TIME_ARGS (delay), GST_TIME_ARGS (max_delay));
-        self->delay = max_delay;
-      } else {
-        self->delay = delay;
-        self->max_delay = MAX (delay, max_delay);
-      }
-      rate = GST_AUDIO_FILTER_RATE (self);
-      if (rate > 0)
-        self->delay_frames =
-            MAX (gst_util_uint64_scale (self->delay, rate, GST_SECOND), 1);
-
-      g_mutex_unlock (&self->lock);
-      break;
-    }
-    case PROP_MAX_DELAY:{
-      guint64 max_delay, delay;
-
-      g_mutex_lock (&self->lock);
-      max_delay = g_value_get_uint64 (value);
-      delay = self->delay;
-
-      if (GST_STATE (self) > GST_STATE_READY) {
-        GST_ERROR_OBJECT (self, "Can't change maximum delay in"
-            " PLAYING or PAUSED state");
-      } else {
-        self->delay = delay;
-        self->max_delay = max_delay;
-      }
-      g_mutex_unlock (&self->lock);
-      break;
-    }
-    case PROP_INTENSITY:{
-      g_mutex_lock (&self->lock);
-      self->intensity = g_value_get_float (value);
-      g_mutex_unlock (&self->lock);
-      break;
-    }
-    case PROP_FEEDBACK:{
-      g_mutex_lock (&self->lock);
-      self->feedback = g_value_get_float (value);
-      g_mutex_unlock (&self->lock);
-      break;
-    }
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-static void
-gst_audio_echo_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec)
-{
-  GstAudioEcho *self = GST_AUDIO_ECHO (object);
-
-  switch (prop_id) {
-    case PROP_DELAY:
-      g_mutex_lock (&self->lock);
-      g_value_set_uint64 (value, self->delay);
-      g_mutex_unlock (&self->lock);
-      break;
-    case PROP_MAX_DELAY:
-      g_mutex_lock (&self->lock);
-      g_value_set_uint64 (value, self->max_delay);
-      g_mutex_unlock (&self->lock);
-      break;
-    case PROP_INTENSITY:
-      g_mutex_lock (&self->lock);
-      g_value_set_float (value, self->intensity);
-      g_mutex_unlock (&self->lock);
-      break;
-    case PROP_FEEDBACK:
-      g_mutex_lock (&self->lock);
-      g_value_set_float (value, self->feedback);
-      g_mutex_unlock (&self->lock);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-/* GstAudioFilter vmethod implementations */
-
-static gboolean
-gst_audio_echo_setup (GstAudioFilter * base, const GstAudioInfo * info)
-{
-  GstAudioEcho *self = GST_AUDIO_ECHO (base);
-  gboolean ret = TRUE;
-
-  switch (GST_AUDIO_INFO_FORMAT (info)) {
-    case GST_AUDIO_FORMAT_F32:
-      self->process = (GstAudioEchoProcessFunc)
-          gst_audio_echo_transform_float;
-      break;
-    case GST_AUDIO_FORMAT_F64:
-      self->process = (GstAudioEchoProcessFunc)
-          gst_audio_echo_transform_double;
-      break;
-    default:
-      ret = FALSE;
-      break;
-  }
-
-  g_free (self->buffer);
-  self->buffer = NULL;
-  self->buffer_pos = 0;
-  self->buffer_size = 0;
-  self->buffer_size_frames = 0;
-
-  return ret;
-}
-
-static gboolean
-gst_audio_echo_stop (GstBaseTransform * base)
-{
-  GstAudioEcho *self = GST_AUDIO_ECHO (base);
-
-  g_free (self->buffer);
-  self->buffer = NULL;
-  self->buffer_pos = 0;
-  self->buffer_size = 0;
-  self->buffer_size_frames = 0;
-
-  return TRUE;
-}
-
-#define TRANSFORM_FUNC(name, type) \
-static void \
-gst_audio_echo_transform_##name (GstAudioEcho * self, \
-    type * data, guint num_samples) \
-{ \
-  type *buffer = (type *) self->buffer; \
-  guint channels = GST_AUDIO_FILTER_CHANNELS (self); \
-  guint rate = GST_AUDIO_FILTER_RATE (self); \
-  guint i, j; \
-  guint echo_index = self->buffer_size_frames - self->delay_frames; \
-  gdouble echo_off = ((((gdouble) self->delay) * rate) / GST_SECOND) - self->delay_frames; \
-  \
-  if (echo_off < 0.0) \
-    echo_off = 0.0; \
-  \
-  num_samples /= channels; \
-  \
-  for (i = 0; i < num_samples; i++) { \
-    guint echo0_index = ((echo_index + self->buffer_pos) % self->buffer_size_frames) * channels; \
-    guint echo1_index = ((echo_index + self->buffer_pos +1) % self->buffer_size_frames) * channels; \
-    guint rbout_index = (self->buffer_pos % self->buffer_size_frames) * channels; \
-    for (j = 0; j < channels; j++) { \
-      gdouble in = data[i*channels + j]; \
-      gdouble echo0 = buffer[echo0_index + j]; \
-      gdouble echo1 = buffer[echo1_index + j]; \
-      gdouble echo = echo0 + (echo1-echo0)*echo_off; \
-      type out = in + self->intensity * echo; \
-      \
-      data[i*channels + j] = out; \
-      \
-      buffer[rbout_index + j] = in + self->feedback * echo; \
-    } \
-    self->buffer_pos = (self->buffer_pos + 1) % self->buffer_size_frames; \
-  } \
-}
-
-TRANSFORM_FUNC (float, gfloat);
-TRANSFORM_FUNC (double, gdouble);
-
-/* GstBaseTransform vmethod implementations */
-static GstFlowReturn
-gst_audio_echo_transform_ip (GstBaseTransform * base, GstBuffer * buf)
-{
-  GstAudioEcho *self = GST_AUDIO_ECHO (base);
-  guint num_samples;
-  GstClockTime timestamp, stream_time;
-  GstMapInfo map;
-
-  g_mutex_lock (&self->lock);
-  timestamp = GST_BUFFER_TIMESTAMP (buf);
-  stream_time =
-      gst_segment_to_stream_time (&base->segment, GST_FORMAT_TIME, timestamp);
-
-  GST_DEBUG_OBJECT (self, "sync to %" GST_TIME_FORMAT,
-      GST_TIME_ARGS (timestamp));
-
-  if (GST_CLOCK_TIME_IS_VALID (stream_time))
-    gst_object_sync_values (GST_OBJECT (self), stream_time);
-
-  if (self->buffer == NULL) {
-    guint bpf, rate;
-
-    bpf = GST_AUDIO_FILTER_BPF (self);
-    rate = GST_AUDIO_FILTER_RATE (self);
-
-    self->delay_frames =
-        MAX (gst_util_uint64_scale (self->delay, rate, GST_SECOND), 1);
-    self->buffer_size_frames =
-        MAX (gst_util_uint64_scale (self->max_delay, rate, GST_SECOND), 1);
-
-    self->buffer_size = self->buffer_size_frames * bpf;
-    self->buffer = g_try_malloc0 (self->buffer_size);
-    self->buffer_pos = 0;
-
-    if (self->buffer == NULL) {
-      g_mutex_unlock (&self->lock);
-      GST_ERROR_OBJECT (self, "Failed to allocate %u bytes", self->buffer_size);
-      return GST_FLOW_ERROR;
-    }
-  }
-
-  gst_buffer_map (buf, &map, GST_MAP_READWRITE);
-  num_samples = map.size / GST_AUDIO_FILTER_BPS (self);
-
-  self->process (self, map.data, num_samples);
-
-  gst_buffer_unmap (buf, &map);
-  g_mutex_unlock (&self->lock);
-
-  return GST_FLOW_OK;
-}
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audioecho.h	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,71 +0,0 @@
-/*
- * GStreamer
- * Copyright (C) 2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifndef __GST_AUDIO_ECHO_H__
-#define __GST_AUDIO_ECHO_H__
-
-#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
-#include <gst/audio/gstaudiofilter.h>
-
-G_BEGIN_DECLS
-
-#define GST_TYPE_AUDIO_ECHO            (gst_audio_echo_get_type())
-#define GST_AUDIO_ECHO(obj)            (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_AUDIO_ECHO,GstAudioEcho))
-#define GST_IS_AUDIO_ECHO(obj)         (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_AUDIO_ECHO))
-#define GST_AUDIO_ECHO_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST((klass) ,GST_TYPE_AUDIO_ECHO,GstAudioEchoClass))
-#define GST_IS_AUDIO_ECHO_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass) ,GST_TYPE_AUDIO_ECHO))
-#define GST_AUDIO_ECHO_GET_CLASS(obj)  (G_TYPE_INSTANCE_GET_CLASS((obj) ,GST_TYPE_AUDIO_ECHO,GstAudioEchoClass))
-typedef struct _GstAudioEcho GstAudioEcho;
-typedef struct _GstAudioEchoClass GstAudioEchoClass;
-
-typedef void (*GstAudioEchoProcessFunc) (GstAudioEcho *, guint8 *, guint);
-
-struct _GstAudioEcho
-{
-  GstAudioFilter audiofilter;
-
-  guint64 delay;
-  guint64 max_delay;
-  gfloat intensity;
-  gfloat feedback;
-
-  /* < private > */
-  GstAudioEchoProcessFunc process;
-  guint delay_frames;
-  guint8 *buffer;
-  guint buffer_pos;
-  guint buffer_size;
-  guint buffer_size_frames;
-
-  GMutex lock;
-};
-
-struct _GstAudioEchoClass
-{
-  GstAudioFilterClass parent;
-};
-
-GType gst_audio_echo_get_type (void);
-
-G_END_DECLS
-
-#endif /* __GST_AUDIO_ECHO_H__ */
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofirfilter.c	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,262 +0,0 @@
-/* 
- * GStreamer
- * Copyright (C) 2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- * 
- */
-
-/**
- * SECTION:element-audiofirfilter
- *
- * audiofirfilter implements a generic audio <ulink url="http://en.wikipedia.org/wiki/Finite_impulse_response">FIR filter</ulink>. Before usage the
- * "kernel" property has to be set to the filter kernel that should be
- * used and the "latency" property has to be set to the latency (in samples)
- * that is introduced by the filter kernel. Setting a latency of n samples
- * will lead to the first n samples being dropped from the output and
- * n samples added to the end.
- *
- * The filter kernel describes the impulse response of the filter. To
- * calculate the frequency response of the filter you have to calculate
- * the Fourier Transform of the impulse response.
- *
- * To change the filter kernel whenever the sampling rate changes the
- * "rate-changed" signal can be used. This should be done for most
- * FIR filters as they're depending on the sampling rate.
- *
- * <refsect2>
- * <title>Example application</title>
- * <informalexample><programlisting language="C">
- * <xi:include xmlns:xi="http://www.w3.org/2003/XInclude" parse="text" href="../../../../tests/examples/audiofx/firfilter-example.c" />
- * </programlisting></informalexample>
- * </refsect2>
- */
-
-/* FIXME 0.11: suppress warnings for deprecated API such as GValueArray
- * with newer GLib versions (>= 2.31.0) */
-#define GLIB_DISABLE_DEPRECATION_WARNINGS
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <string.h>
-#include <math.h>
-#include <gst/gst.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include "audiofirfilter.h"
-
-#include "gst/glib-compat-private.h"
-
-#define GST_CAT_DEFAULT gst_audio_fir_filter_debug
-GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
-
-enum
-{
-  SIGNAL_RATE_CHANGED,
-  LAST_SIGNAL
-};
-
-enum
-{
-  PROP_0,
-  PROP_KERNEL,
-  PROP_LATENCY
-};
-
-static guint gst_audio_fir_filter_signals[LAST_SIGNAL] = { 0, };
-
-#define gst_audio_fir_filter_parent_class parent_class
-G_DEFINE_TYPE (GstAudioFIRFilter, gst_audio_fir_filter,
-    GST_TYPE_AUDIO_FX_BASE_FIR_FILTER);
-
-static void gst_audio_fir_filter_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec);
-static void gst_audio_fir_filter_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec);
-static void gst_audio_fir_filter_finalize (GObject * object);
-
-static gboolean gst_audio_fir_filter_setup (GstAudioFilter * base,
-    const GstAudioInfo * info);
-
-
-static void
-gst_audio_fir_filter_class_init (GstAudioFIRFilterClass * klass)
-{
-  GObjectClass *gobject_class = (GObjectClass *) klass;
-  GstElementClass *gstelement_class = (GstElementClass *) klass;
-  GstAudioFilterClass *filter_class = (GstAudioFilterClass *) klass;
-
-  GST_DEBUG_CATEGORY_INIT (gst_audio_fir_filter_debug, "audiofirfilter", 0,
-      "Generic audio FIR filter plugin");
-
-  gobject_class->set_property = gst_audio_fir_filter_set_property;
-  gobject_class->get_property = gst_audio_fir_filter_get_property;
-  gobject_class->finalize = gst_audio_fir_filter_finalize;
-
-  g_object_class_install_property (gobject_class, PROP_KERNEL,
-      g_param_spec_value_array ("kernel", "Filter Kernel",
-          "Filter kernel for the FIR filter",
-          g_param_spec_double ("Element", "Filter Kernel Element",
-              "Element of the filter kernel", -G_MAXDOUBLE, G_MAXDOUBLE, 0.0,
-              G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS),
-          G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
-  g_object_class_install_property (gobject_class, PROP_LATENCY,
-      g_param_spec_uint64 ("latency", "Latecy",
-          "Filter latency in samples",
-          0, G_MAXUINT64, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
-
-  filter_class->setup = GST_DEBUG_FUNCPTR (gst_audio_fir_filter_setup);
-
-  /**
-   * GstAudioFIRFilter::rate-changed:
-   * @filter: the filter on which the signal is emitted
-   * @rate: the new sampling rate
-   *
-   * Will be emitted when the sampling rate changes. The callbacks
-   * will be called from the streaming thread and processing will
-   * stop until the event is handled.
-   */
-  gst_audio_fir_filter_signals[SIGNAL_RATE_CHANGED] =
-      g_signal_new ("rate-changed", G_TYPE_FROM_CLASS (klass),
-      G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GstAudioFIRFilterClass, rate_changed),
-      NULL, NULL, NULL, G_TYPE_NONE, 1, G_TYPE_INT);
-
-  gst_element_class_set_static_metadata (gstelement_class,
-      "Audio FIR filter", "Filter/Effect/Audio",
-      "Generic audio FIR filter with custom filter kernel",
-      "Sebastian Dröge <sebastian.droege@collabora.co.uk>");
-}
-
-static void
-gst_audio_fir_filter_update_kernel (GstAudioFIRFilter * self, GValueArray * va)
-{
-  gdouble *kernel;
-  guint i;
-
-  if (va) {
-    if (self->kernel)
-      g_value_array_free (self->kernel);
-
-    self->kernel = va;
-  }
-
-  kernel = g_new (gdouble, self->kernel->n_values);
-
-  for (i = 0; i < self->kernel->n_values; i++) {
-    GValue *v = g_value_array_get_nth (self->kernel, i);
-    kernel[i] = g_value_get_double (v);
-  }
-
-  gst_audio_fx_base_fir_filter_set_kernel (GST_AUDIO_FX_BASE_FIR_FILTER (self),
-      kernel, self->kernel->n_values, self->latency, NULL);
-}
-
-static void
-gst_audio_fir_filter_init (GstAudioFIRFilter * self)
-{
-  GValue v = { 0, };
-  GValueArray *va;
-
-  self->latency = 0;
-  va = g_value_array_new (1);
-
-  g_value_init (&v, G_TYPE_DOUBLE);
-  g_value_set_double (&v, 1.0);
-  g_value_array_append (va, &v);
-  g_value_unset (&v);
-  gst_audio_fir_filter_update_kernel (self, va);
-
-  g_mutex_init (&self->lock);
-}
-
-/* GstAudioFilter vmethod implementations */
-
-/* get notified of caps and plug in the correct process function */
-static gboolean
-gst_audio_fir_filter_setup (GstAudioFilter * base, const GstAudioInfo * info)
-{
-  GstAudioFIRFilter *self = GST_AUDIO_FIR_FILTER (base);
-  gint new_rate = GST_AUDIO_INFO_RATE (info);
-
-  if (GST_AUDIO_FILTER_RATE (self) != new_rate) {
-    g_signal_emit (G_OBJECT (self),
-        gst_audio_fir_filter_signals[SIGNAL_RATE_CHANGED], 0, new_rate);
-  }
-
-  return GST_AUDIO_FILTER_CLASS (parent_class)->setup (base, info);
-}
-
-static void
-gst_audio_fir_filter_finalize (GObject * object)
-{
-  GstAudioFIRFilter *self = GST_AUDIO_FIR_FILTER (object);
-
-  g_mutex_clear (&self->lock);
-
-  if (self->kernel)
-    g_value_array_free (self->kernel);
-  self->kernel = NULL;
-
-  G_OBJECT_CLASS (parent_class)->finalize (object);
-}
-
-static void
-gst_audio_fir_filter_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec)
-{
-  GstAudioFIRFilter *self = GST_AUDIO_FIR_FILTER (object);
-
-  g_return_if_fail (GST_IS_AUDIO_FIR_FILTER (self));
-
-  switch (prop_id) {
-    case PROP_KERNEL:
-      g_mutex_lock (&self->lock);
-      /* update kernel already pushes residues */
-      gst_audio_fir_filter_update_kernel (self, g_value_dup_boxed (value));
-      g_mutex_unlock (&self->lock);
-      break;
-    case PROP_LATENCY:
-      g_mutex_lock (&self->lock);
-      self->latency = g_value_get_uint64 (value);
-      gst_audio_fir_filter_update_kernel (self, NULL);
-      g_mutex_unlock (&self->lock);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-static void
-gst_audio_fir_filter_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec)
-{
-  GstAudioFIRFilter *self = GST_AUDIO_FIR_FILTER (object);
-
-  switch (prop_id) {
-    case PROP_KERNEL:
-      g_value_set_boxed (value, self->kernel);
-      break;
-    case PROP_LATENCY:
-      g_value_set_uint64 (value, self->latency);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofirfilter.h	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,71 +0,0 @@
-/*
- * GStreamer
- * Copyright (C) 2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- *
- */
-
-#ifndef __GST_AUDIO_FIR_FILTER_H__
-#define __GST_AUDIO_FIR_FILTER_H__
-
-#include <gst/gst.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include "audiofxbasefirfilter.h"
-
-G_BEGIN_DECLS
-
-#define GST_TYPE_AUDIO_FIR_FILTER \
-  (gst_audio_fir_filter_get_type())
-#define GST_AUDIO_FIR_FILTER(obj) \
-  (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_AUDIO_FIR_FILTER,GstAudioFIRFilter))
-#define GST_AUDIO_FIR_FILTER_CLASS(klass) \
-  (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_AUDIO_FIR_FILTER,GstAudioFIRFilterClass))
-#define GST_IS_AUDIO_FIR_FILTER(obj) \
-  (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_AUDIO_FIR_FILTER))
-#define GST_IS_AUDIO_FIR_FILTER_CLASS(klass) \
-  (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_AUDIO_FIR_FILTER))
-
-typedef struct _GstAudioFIRFilter GstAudioFIRFilter;
-typedef struct _GstAudioFIRFilterClass GstAudioFIRFilterClass;
-
-/**
- * GstAudioFIRFilter:
- *
- * Opaque data structure.
- */
-struct _GstAudioFIRFilter {
-  GstAudioFXBaseFIRFilter parent;
-
-  GValueArray *kernel;
-  guint64 latency;
-
-  /* < private > */
-  GMutex lock;
-};
-
-struct _GstAudioFIRFilterClass {
-  GstAudioFXBaseFIRFilterClass parent;
-
-  void (*rate_changed) (GstElement * element, gint rate);
-};
-
-GType gst_audio_fir_filter_get_type (void);
-
-G_END_DECLS
-
-#endif /* __GST_AUDIO_FIR_FILTER_H__ */
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofx.c	Fri Sep 18 16:15:42 2015 -0700
+++ b/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofx.c	Mon Sep 21 16:17:03 2015 -0700
@@ -25,6 +25,7 @@
 #include <gst/gst.h>
 
 #include "audiopanorama.h"
+#ifndef GSTREAMER_LITE
 #include "audioinvert.h"
 #include "audiokaraoke.h"
 #include "audioamplify.h"
@@ -37,6 +38,7 @@
 #include "audiofirfilter.h"
 #include "audioecho.h"
 #include "gstscaletempo.h"
+#endif // GSTREAMER_LITE
 
 /* entry point to initialize the plug-in
  * initialize the plug-in itself
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofxbasefirfilter.c	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1086 +0,0 @@
-/* -*- c-basic-offset: 2 -*-
- * 
- * GStreamer
- * Copyright (C) 1999-2001 Erik Walthinsen <omega@cse.ogi.edu>
- *               2006 Dreamlab Technologies Ltd. <mathis.hofer@dreamlab.net>
- *               2007-2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- * 
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <string.h>
-#include <math.h>
-#include <gst/gst.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include "audiofxbasefirfilter.h"
-
-#define GST_CAT_DEFAULT gst_audio_fx_base_fir_filter_debug
-GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
-
-#define ALLOWED_CAPS \
-    "audio/x-raw, "                                               \
-    " format=(string){"GST_AUDIO_NE(F32)","GST_AUDIO_NE(F64)"}, " \
-    " rate = (int) [ 1, MAX ], "                                  \
-    " channels = (int) [ 1, MAX ], "                              \
-    " layout=(string) interleaved"
-
-/* Switch from time-domain to FFT convolution for kernels >= this */
-#define FFT_THRESHOLD 32
-
-enum
-{
-  PROP_0 = 0,
-  PROP_LOW_LATENCY,
-  PROP_DRAIN_ON_CHANGES
-};
-
-#define DEFAULT_LOW_LATENCY FALSE
-#define DEFAULT_DRAIN_ON_CHANGES TRUE
-
-#define gst_audio_fx_base_fir_filter_parent_class parent_class
-G_DEFINE_TYPE (GstAudioFXBaseFIRFilter, gst_audio_fx_base_fir_filter,
-    GST_TYPE_AUDIO_FILTER);
-
-static GstFlowReturn gst_audio_fx_base_fir_filter_transform (GstBaseTransform *
-    base, GstBuffer * inbuf, GstBuffer * outbuf);
-static gboolean gst_audio_fx_base_fir_filter_start (GstBaseTransform * base);
-static gboolean gst_audio_fx_base_fir_filter_stop (GstBaseTransform * base);
-static gboolean gst_audio_fx_base_fir_filter_sink_event (GstBaseTransform *
-    base, GstEvent * event);
-static gboolean gst_audio_fx_base_fir_filter_transform_size (GstBaseTransform *
-    base, GstPadDirection direction, GstCaps * caps, gsize size,
-    GstCaps * othercaps, gsize * othersize);
-static gboolean gst_audio_fx_base_fir_filter_setup (GstAudioFilter * base,
-    const GstAudioInfo * info);
-
-static gboolean gst_audio_fx_base_fir_filter_query (GstBaseTransform * trans,
-    GstPadDirection direction, GstQuery * quer);
-
-/*
- * The code below calculates the linear convolution:
- *
- * y[t] = \sum_{u=0}^{M-1} x[t - u] * h[u]
- *
- * where y is the output, x is the input, M is the length
- * of the filter kernel and h is the filter kernel. For x
- * holds: x[t] == 0 \forall t < 0.
- *
- * The runtime complexity of this is O (M) per sample.
- *
- */
-#define DEFINE_PROCESS_FUNC(width,ctype) \
-static guint \
-process_##width (GstAudioFXBaseFIRFilter * self, const g##ctype * src, g##ctype * dst, guint input_samples) \
-{ \
-  gint channels = GST_AUDIO_FILTER_CHANNELS (self); \
-  TIME_DOMAIN_CONVOLUTION_BODY (channels); \
-}
-
-#define DEFINE_PROCESS_FUNC_FIXED_CHANNELS(width,channels,ctype) \
-static guint \
-process_##channels##_##width (GstAudioFXBaseFIRFilter * self, const g##ctype * src, g##ctype * dst, guint input_samples) \
-{ \
-  TIME_DOMAIN_CONVOLUTION_BODY (channels); \
-}
-
-#define TIME_DOMAIN_CONVOLUTION_BODY(channels) G_STMT_START { \
-  gint kernel_length = self->kernel_length; \
-  gint i, j, k, l; \
-  gint res_start; \
-  gint from_input; \
-  gint off; \
-  gdouble *buffer = self->buffer; \
-  gdouble *kernel = self->kernel; \
-  guint buffer_length = self->buffer_length; \
-  \
-  if (!buffer) { \
-    self->buffer_length = buffer_length = kernel_length * channels; \
-    self->buffer = buffer = g_new0 (gdouble, self->buffer_length); \
-  } \
-  \
-  /* convolution */ \
-  for (i = 0; i < input_samples; i++) { \
-    dst[i] = 0.0; \
-    k = i % channels; \
-    l = i / channels; \
-    from_input = MIN (l, kernel_length-1); \
-    off = l * channels + k; \
-    for (j = 0; j <= from_input; j++) { \
-      dst[i] += src[off] * kernel[j]; \
-      off -= channels; \
-    } \
-    /* j == from_input && off == (l - j) * channels + k */ \
-    off += kernel_length * channels; \
-    for (; j < kernel_length; j++) { \
-      dst[i] += buffer[off] * kernel[j]; \
-      off -= channels; \
-    } \
-  } \
-  \
-  /* copy the tail of the current input buffer to the residue, while \
-   * keeping parts of the residue if the input buffer is smaller than \
-   * the kernel length */ \
-  /* from now on take kernel length as length over all channels */ \
-  kernel_length *= channels; \
-  if (input_samples < kernel_length) \
-    res_start = kernel_length - input_samples; \
-  else \
-    res_start = 0; \
-  \
-  for (i = 0; i < res_start; i++) \
-    buffer[i] = buffer[i + input_samples]; \
-  /* i == res_start */ \
-  for (; i < kernel_length; i++) \
-    buffer[i] = src[input_samples - kernel_length + i]; \
-  \
-  self->buffer_fill += kernel_length - res_start; \
-  if (self->buffer_fill > kernel_length) \
-    self->buffer_fill = kernel_length; \
-  \
-  return input_samples; \
-} G_STMT_END
-
-DEFINE_PROCESS_FUNC (32, float);
-DEFINE_PROCESS_FUNC (64, double);
-
-DEFINE_PROCESS_FUNC_FIXED_CHANNELS (32, 1, float);
-DEFINE_PROCESS_FUNC_FIXED_CHANNELS (64, 1, double);
-
-DEFINE_PROCESS_FUNC_FIXED_CHANNELS (32, 2, float);
-DEFINE_PROCESS_FUNC_FIXED_CHANNELS (64, 2, double);
-
-#undef TIME_DOMAIN_CONVOLUTION_BODY
-#undef DEFINE_PROCESS_FUNC
-#undef DEFINE_PROCESS_FUNC_FIXED_CHANNELS
-
-/* This implements FFT convolution and uses the overlap-save algorithm.
- * See http://cnx.org/content/m12022/latest/ or your favorite
- * digital signal processing book for details.
- *
- * In every pass the following is calculated:
- *
- * y = IFFT (FFT(x) * FFT(h))
- *
- * where y is the output in the time domain, x the
- * input and h the filter kernel. * is the multiplication
- * of complex numbers.
- *
- * Due to the circular convolution theorem this
- * gives in the time domain:
- *
- * y[t] = \sum_{u=0}^{M-1} x[t - u] * h[u]
- *
- * where y is the output, M is the kernel length,
- * x the periodically extended[0] input and h the
- * filter kernel.
- *
- * ([0] Periodically extended means:    )
- * (    x[t] = x[t+kN] \forall k \in Z  )
- * (    where N is the length of x      )
- *
- * This means:
- * - Obviously x and h need to be of the same size for the FFT
- * - The first M-1 output values are useless because they're
- *   built from 1 up to M-1 values from the end of the input
- *   (circular convolusion!).
- * - The last M-1 input values are only used for 1 up to M-1
- *   output values, i.e. they need to be used again in the
- *   next pass for the first M-1 input values.
- *
- * => The first pass needs M-1 zeroes at the beginning of the
- * input and the last M-1 input values of every pass need to
- * be used as the first M-1 input values of the next pass.
- *
- * => x must be larger than h to give a useful number of output
- * samples and h needs to be padded by zeroes at the end to give
- * it virtually the same size as x (by M we denote the number of
- * non-padding samples of h). If len(x)==len(h)==M only 1 output
- * sample would be calculated per pass, len(x)==2*len(h) would
- * give M+1 output samples, etc. Usually a factor between 4 and 8
- * gives a low number of operations per output samples (see website
- * given above).
- *
- * Overall this gives a runtime complexity per sample of
- *
- *   (  N log N  )
- * O ( --------- ) compared to O (M) for the direct calculation.
- *   ( N - M + 1 )
- */
-#define DEFINE_FFT_PROCESS_FUNC(width,ctype) \
-static guint \
-process_fft_##width (GstAudioFXBaseFIRFilter * self, const g##ctype * src, \
-    g##ctype * dst, guint input_samples) \
-{ \
-  gint channels = GST_AUDIO_FILTER_CHANNELS (self); \
-  FFT_CONVOLUTION_BODY (channels); \
-}
-
-#define DEFINE_FFT_PROCESS_FUNC_FIXED_CHANNELS(width,channels,ctype) \
-static guint \
-process_fft_##channels##_##width (GstAudioFXBaseFIRFilter * self, const g##ctype * src, \
-    g##ctype * dst, guint input_samples) \
-{ \
-  FFT_CONVOLUTION_BODY (channels); \
-}
-
-#define FFT_CONVOLUTION_BODY(channels) G_STMT_START { \
-  gint i, j; \
-  guint pass; \
-  guint kernel_length = self->kernel_length; \
-  guint block_length = self->block_length; \
-  guint buffer_length = self->buffer_length; \
-  guint real_buffer_length = buffer_length + kernel_length - 1; \
-  guint buffer_fill = self->buffer_fill; \
-  GstFFTF64 *fft = self->fft; \
-  GstFFTF64 *ifft = self->ifft; \
-  GstFFTF64Complex *frequency_response = self->frequency_response; \
-  GstFFTF64Complex *fft_buffer = self->fft_buffer; \
-  guint frequency_response_length = self->frequency_response_length; \
-  gdouble *buffer = self->buffer; \
-  guint generated = 0; \
-  gdouble re, im; \
-  \
-  if (!fft_buffer) \
-    self->fft_buffer = fft_buffer = \
-        g_new (GstFFTF64Complex, frequency_response_length); \
-  \
-  /* Buffer contains the time domain samples of input data for one chunk \
-   * plus some more space for the inverse FFT below. \
-   * \
-   * The samples are put at offset kernel_length, the inverse FFT \
-   * overwrites everthing from offset 0 to length-kernel_length+1, keeping \
-   * the last kernel_length-1 samples for copying to the next processing \
-   * step. \
-   */ \
-  if (!buffer) { \
-    self->buffer_length = buffer_length = block_length; \
-    real_buffer_length = buffer_length + kernel_length - 1; \
-    \
-    self->buffer = buffer = g_new0 (gdouble, real_buffer_length * channels); \
-    \
-    /* Beginning has kernel_length-1 zeroes at the beginning */ \
-    self->buffer_fill = buffer_fill = kernel_length - 1; \
-  } \
-  \
-  g_assert (self->buffer_length == block_length); \
-  \
-  while (input_samples) { \
-    pass = MIN (buffer_length - buffer_fill, input_samples); \
-    \
-    /* Deinterleave channels */ \
-    for (i = 0; i < pass; i++) { \
-      for (j = 0; j < channels; j++) { \
-        buffer[real_buffer_length * j + buffer_fill + kernel_length - 1 + i] = \
-            src[i * channels + j]; \
-      } \
-    } \
-    buffer_fill += pass; \
-    src += channels * pass; \
-    input_samples -= pass; \
-    \
-    /* If we don't have a complete buffer go out */ \
-    if (buffer_fill < buffer_length) \
-      break; \
-    \
-    for (j = 0; j < channels; j++) { \
-      /* Calculate FFT of input block */ \
-      gst_fft_f64_fft (fft, \
-          buffer + real_buffer_length * j + kernel_length - 1, fft_buffer); \
-      \
-      /* Complex multiplication of input and filter spectrum */ \
-      for (i = 0; i < frequency_response_length; i++) { \
-	re = fft_buffer[i].r; \
-	im = fft_buffer[i].i; \
-        \
-        fft_buffer[i].r = \
-            re * frequency_response[i].r - \
-            im * frequency_response[i].i; \
-        fft_buffer[i].i = \
-            re * frequency_response[i].i + \
-            im * frequency_response[i].r; \
-      } \
-      \
-      /* Calculate inverse FFT of the result */ \
-      gst_fft_f64_inverse_fft (ifft, fft_buffer, \
-          buffer + real_buffer_length * j); \
-      \
-      /* Copy all except the first kernel_length-1 samples to the output */ \
-      for (i = 0; i < buffer_length - kernel_length + 1; i++) { \
-        dst[i * channels + j] = \
-            buffer[real_buffer_length * j + kernel_length - 1 + i]; \
-      } \
-      \
-      /* Copy the last kernel_length-1 samples to the beginning for the next block */ \
-      for (i = 0; i < kernel_length - 1; i++) { \
-        buffer[real_buffer_length * j + kernel_length - 1 + i] = \
-            buffer[real_buffer_length * j + buffer_length + i]; \
-      } \
-    } \
-    \
-    generated += buffer_length - kernel_length + 1; \
-    dst += channels * (buffer_length - kernel_length + 1); \
-    \
-    /* The the first kernel_length-1 samples are there already */ \
-    buffer_fill = kernel_length - 1; \
-  } \
-  \
-  /* Write back cached buffer_fill value */ \
-  self->buffer_fill = buffer_fill; \
-  \
-  return generated; \
-} G_STMT_END
-
-DEFINE_FFT_PROCESS_FUNC (32, float);
-DEFINE_FFT_PROCESS_FUNC (64, double);
-
-DEFINE_FFT_PROCESS_FUNC_FIXED_CHANNELS (32, 1, float);
-DEFINE_FFT_PROCESS_FUNC_FIXED_CHANNELS (64, 1, double);
-
-DEFINE_FFT_PROCESS_FUNC_FIXED_CHANNELS (32, 2, float);
-DEFINE_FFT_PROCESS_FUNC_FIXED_CHANNELS (64, 2, double);
-
-#undef FFT_CONVOLUTION_BODY
-#undef DEFINE_FFT_PROCESS_FUNC
-#undef DEFINE_FFT_PROCESS_FUNC_FIXED_CHANNELS
-
-/* Element class */
-static void
-    gst_audio_fx_base_fir_filter_calculate_frequency_response
-    (GstAudioFXBaseFIRFilter * self)
-{
-  gst_fft_f64_free (self->fft);
-  self->fft = NULL;
-  gst_fft_f64_free (self->ifft);
-  self->ifft = NULL;
-  g_free (self->frequency_response);
-  self->frequency_response_length = 0;
-  g_free (self->fft_buffer);
-  self->fft_buffer = NULL;
-
-  if (self->kernel && self->kernel_length >= FFT_THRESHOLD
-      && !self->low_latency) {
-    guint block_length, i;
-    gdouble *kernel_tmp, *kernel = self->kernel;
-
-    /* We process 4 * kernel_length samples per pass in FFT mode */
-    block_length = 4 * self->kernel_length;
-    block_length = gst_fft_next_fast_length (block_length);
-    self->block_length = block_length;
-
-    kernel_tmp = g_new0 (gdouble, block_length);
-    memcpy (kernel_tmp, kernel, self->kernel_length * sizeof (gdouble));
-
-    self->fft = gst_fft_f64_new (block_length, FALSE);
-    self->ifft = gst_fft_f64_new (block_length, TRUE);
-    self->frequency_response_length = block_length / 2 + 1;
-    self->frequency_response =
-        g_new (GstFFTF64Complex, self->frequency_response_length);
-    gst_fft_f64_fft (self->fft, kernel_tmp, self->frequency_response);
-    g_free (kernel_tmp);
-
-    /* Normalize to make sure IFFT(FFT(x)) == x */
-    for (i = 0; i < self->frequency_response_length; i++) {
-      self->frequency_response[i].r /= block_length;
-      self->frequency_response[i].i /= block_length;
-    }
-  }
-}
-
-/* Must be called with base transform lock! */
-static void
-gst_audio_fx_base_fir_filter_select_process_function (GstAudioFXBaseFIRFilter *
-    self, GstAudioFormat format, gint channels)
-{
-  switch (format) {
-    case GST_AUDIO_FORMAT_F32:
-      if (self->fft && !self->low_latency) {
-        if (channels == 1)
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_fft_1_32;
-        else if (channels == 2)
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_fft_2_32;
-        else
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_fft_32;
-      } else {
-        if (channels == 1)
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_1_32;
-        else if (channels == 2)
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_2_32;
-        else
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_32;
-      }
-      break;
-    case GST_AUDIO_FORMAT_F64:
-      if (self->fft && !self->low_latency) {
-        if (channels == 1)
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_fft_1_64;
-        else if (channels == 2)
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_fft_2_64;
-        else
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_fft_64;
-      } else {
-        if (channels == 1)
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_1_64;
-        else if (channels == 2)
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_2_64;
-        else
-          self->process = (GstAudioFXBaseFIRFilterProcessFunc) process_64;
-      }
-      break;
-    default:
-      self->process = NULL;
-      break;
-  }
-}
-
-static void
-gst_audio_fx_base_fir_filter_finalize (GObject * object)
-{
-  GstAudioFXBaseFIRFilter *self = GST_AUDIO_FX_BASE_FIR_FILTER (object);
-
-  g_free (self->buffer);
-  g_free (self->kernel);
-  gst_fft_f64_free (self->fft);
-  gst_fft_f64_free (self->ifft);
-  g_free (self->frequency_response);
-  g_free (self->fft_buffer);
-  g_mutex_clear (&self->lock);
-
-  G_OBJECT_CLASS (parent_class)->finalize (object);
-}
-
-static void
-gst_audio_fx_base_fir_filter_set_property (GObject * object, guint prop_id,
-    const GValue * value, GParamSpec * pspec)
-{
-  GstAudioFXBaseFIRFilter *self = GST_AUDIO_FX_BASE_FIR_FILTER (object);
-
-  switch (prop_id) {
-    case PROP_LOW_LATENCY:{
-      gboolean low_latency;
-
-      if (GST_STATE (self) >= GST_STATE_PAUSED) {
-        g_warning ("Changing the \"low-latency\" property "
-            "is only allowed in states < PAUSED");
-        return;
-      }
-
-
-      g_mutex_lock (&self->lock);
-      low_latency = g_value_get_boolean (value);
-
-      if (self->low_latency != low_latency) {
-        self->low_latency = low_latency;
-        gst_audio_fx_base_fir_filter_calculate_frequency_response (self);
-        gst_audio_fx_base_fir_filter_select_process_function (self,
-            GST_AUDIO_FILTER_FORMAT (self), GST_AUDIO_FILTER_CHANNELS (self));
-      }
-      g_mutex_unlock (&self->lock);
-      break;
-    }
-    case PROP_DRAIN_ON_CHANGES:{
-      g_mutex_lock (&self->lock);
-      self->drain_on_changes = g_value_get_boolean (value);
-      g_mutex_unlock (&self->lock);
-      break;
-    }
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-static void
-gst_audio_fx_base_fir_filter_get_property (GObject * object, guint prop_id,
-    GValue * value, GParamSpec * pspec)
-{
-  GstAudioFXBaseFIRFilter *self = GST_AUDIO_FX_BASE_FIR_FILTER (object);
-
-  switch (prop_id) {
-    case PROP_LOW_LATENCY:
-      g_value_set_boolean (value, self->low_latency);
-      break;
-    case PROP_DRAIN_ON_CHANGES:
-      g_value_set_boolean (value, self->drain_on_changes);
-      break;
-    default:
-      G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
-      break;
-  }
-}
-
-static void
-gst_audio_fx_base_fir_filter_class_init (GstAudioFXBaseFIRFilterClass * klass)
-{
-  GObjectClass *gobject_class = (GObjectClass *) klass;
-  GstBaseTransformClass *trans_class = (GstBaseTransformClass *) klass;
-  GstAudioFilterClass *filter_class = (GstAudioFilterClass *) klass;
-  GstCaps *caps;
-
-  GST_DEBUG_CATEGORY_INIT (gst_audio_fx_base_fir_filter_debug,
-      "audiofxbasefirfilter", 0, "FIR filter base class");
-
-  gobject_class->finalize = gst_audio_fx_base_fir_filter_finalize;
-  gobject_class->set_property = gst_audio_fx_base_fir_filter_set_property;
-  gobject_class->get_property = gst_audio_fx_base_fir_filter_get_property;
-
-  /**
-   * GstAudioFXBaseFIRFilter:low-latency:
-   *
-   * Work in low-latency mode. This mode is much slower for large filter sizes
-   * but the latency is always only the pre-latency of the filter.
-   */
-  g_object_class_install_property (gobject_class, PROP_LOW_LATENCY,
-      g_param_spec_boolean ("low-latency", "Low latency",
-          "Operate in low latency mode. This mode is slower but the "
-          "latency will only be the filter pre-latency. "
-          "Can only be changed in states < PAUSED!", DEFAULT_LOW_LATENCY,
-          G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
-
-  /**
-   * GstAudioFXBaseFIRFilter:drain-on-changes:
-   *
-   * Whether the filter should be drained when its coeficients change
-   *
-   * Note: Currently this only works if the kernel size is not changed!
-   * Support for drainless kernel size changes will be added in the future.
-   */
-  g_object_class_install_property (gobject_class, PROP_DRAIN_ON_CHANGES,
-      g_param_spec_boolean ("drain-on-changes", "Drain on changes",
-          "Drains the filter when its coeficients change",
-          DEFAULT_DRAIN_ON_CHANGES,
-          G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
-
-  caps = gst_caps_from_string (ALLOWED_CAPS);
-  gst_audio_filter_class_add_pad_templates (GST_AUDIO_FILTER_CLASS (klass),
-      caps);
-  gst_caps_unref (caps);
-
-  trans_class->transform =
-      GST_DEBUG_FUNCPTR (gst_audio_fx_base_fir_filter_transform);
-  trans_class->start = GST_DEBUG_FUNCPTR (gst_audio_fx_base_fir_filter_start);
-  trans_class->stop = GST_DEBUG_FUNCPTR (gst_audio_fx_base_fir_filter_stop);
-  trans_class->sink_event =
-      GST_DEBUG_FUNCPTR (gst_audio_fx_base_fir_filter_sink_event);
-  trans_class->query = GST_DEBUG_FUNCPTR (gst_audio_fx_base_fir_filter_query);
-  trans_class->transform_size =
-      GST_DEBUG_FUNCPTR (gst_audio_fx_base_fir_filter_transform_size);
-  filter_class->setup = GST_DEBUG_FUNCPTR (gst_audio_fx_base_fir_filter_setup);
-}
-
-static void
-gst_audio_fx_base_fir_filter_init (GstAudioFXBaseFIRFilter * self)
-{
-  self->kernel = NULL;
-  self->buffer = NULL;
-  self->buffer_length = 0;
-
-  self->start_ts = GST_CLOCK_TIME_NONE;
-  self->start_off = GST_BUFFER_OFFSET_NONE;
-  self->nsamples_out = 0;
-  self->nsamples_in = 0;
-
-  self->low_latency = DEFAULT_LOW_LATENCY;
-  self->drain_on_changes = DEFAULT_DRAIN_ON_CHANGES;
-
-  g_mutex_init (&self->lock);
-}
-
-void
-gst_audio_fx_base_fir_filter_push_residue (GstAudioFXBaseFIRFilter * self)
-{
-  GstBuffer *outbuf;
-  GstFlowReturn res;
-  gint rate = GST_AUDIO_FILTER_RATE (self);
-  gint channels = GST_AUDIO_FILTER_CHANNELS (self);
-  gint bps = GST_AUDIO_FILTER_BPS (self);
-  gint outsize, outsamples;
-  GstMapInfo map;
-  guint8 *in, *out;
-
-  if (channels == 0 || rate == 0 || self->nsamples_in == 0) {
-    self->buffer_fill = 0;
-    g_free (self->buffer);
-    self->buffer = NULL;
-    return;
-  }
-
-  /* Calculate the number of samples and their memory size that
-   * should be pushed from the residue */
-  outsamples = self->nsamples_in - (self->nsamples_out - self->latency);
-  if (outsamples <= 0) {
-    self->buffer_fill = 0;
-    g_free (self->buffer);
-    self->buffer = NULL;
-    return;
-  }
-  outsize = outsamples * channels * bps;
-
-  if (!self->fft || self->low_latency) {
-    gint64 diffsize, diffsamples;
-
-    /* Process the difference between latency and residue length samples
-     * to start at the actual data instead of starting at the zeros before
-     * when we only got one buffer smaller than latency */
-    diffsamples =
-        ((gint64) self->latency) - ((gint64) self->buffer_fill) / channels;
-    if (diffsamples > 0) {
-      diffsize = diffsamples * channels * bps;
-      in = g_new0 (guint8, diffsize);
-      out = g_new0 (guint8, diffsize);
-      self->nsamples_out += self->process (self, in, out, diffsamples);
-      g_free (in);
-      g_free (out);
-    }
-
-    outbuf = gst_buffer_new_and_alloc (outsize);
-
-    /* Convolve the residue with zeros to get the actual remaining data */
-    in = g_new0 (guint8, outsize);
-    gst_buffer_map (outbuf, &map, GST_MAP_READWRITE);
-    self->nsamples_out += self->process (self, in, map.data, outsamples);
-    gst_buffer_unmap (outbuf, &map);
-
-    g_free (in);
-  } else {
-    guint gensamples = 0;
-
-    outbuf = gst_buffer_new_and_alloc (outsize);
-    gst_buffer_map (outbuf, &map, GST_MAP_READWRITE);
-
-    while (gensamples < outsamples) {
-      guint step_insamples = self->block_length - self->buffer_fill;
-      guint8 *zeroes = g_new0 (guint8, step_insamples * channels * bps);
-      guint8 *out = g_new (guint8, self->block_length * channels * bps);
-      guint step_gensamples;
-
-      step_gensamples = self->process (self, zeroes, out, step_insamples);
-      g_free (zeroes);
-
-      memcpy (map.data + gensamples * bps, out, MIN (step_gensamples,
-              outsamples - gensamples) * bps);
-      gensamples += MIN (step_gensamples, outsamples - gensamples);
-
-      g_free (out);
-    }
-    self->nsamples_out += gensamples;
-
-    gst_buffer_unmap (outbuf, &map);
-  }
-
-  /* Set timestamp, offset, etc from the values we
-   * saved when processing the regular buffers */
-  if (GST_CLOCK_TIME_IS_VALID (self->start_ts))
-    GST_BUFFER_TIMESTAMP (outbuf) = self->start_ts;
-  else
-    GST_BUFFER_TIMESTAMP (outbuf) = 0;
-  GST_BUFFER_TIMESTAMP (outbuf) +=
-      gst_util_uint64_scale_int (self->nsamples_out - outsamples -
-      self->latency, GST_SECOND, rate);
-
-  GST_BUFFER_DURATION (outbuf) =
-      gst_util_uint64_scale_int (outsamples, GST_SECOND, rate);
-
-  if (self->start_off != GST_BUFFER_OFFSET_NONE) {
-    GST_BUFFER_OFFSET (outbuf) =
-        self->start_off + self->nsamples_out - outsamples - self->latency;
-    GST_BUFFER_OFFSET_END (outbuf) = GST_BUFFER_OFFSET (outbuf) + outsamples;
-  }
-
-  GST_DEBUG_OBJECT (self,
-      "Pushing residue buffer of size %" G_GSIZE_FORMAT " with timestamp: %"
-      GST_TIME_FORMAT ", duration: %" GST_TIME_FORMAT ", offset: %"
-      G_GUINT64_FORMAT ", offset_end: %" G_GUINT64_FORMAT ", nsamples_out: %d",
-      gst_buffer_get_size (outbuf),
-      GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (outbuf)),
-      GST_TIME_ARGS (GST_BUFFER_DURATION (outbuf)), GST_BUFFER_OFFSET (outbuf),
-      GST_BUFFER_OFFSET_END (outbuf), outsamples);
-
-  res = gst_pad_push (GST_BASE_TRANSFORM_CAST (self)->srcpad, outbuf);
-
-  if (G_UNLIKELY (res != GST_FLOW_OK)) {
-    GST_WARNING_OBJECT (self, "failed to push residue");
-  }
-
-  self->buffer_fill = 0;
-}
-
-/* GstAudioFilter vmethod implementations */
-
-/* get notified of caps and plug in the correct process function */
-static gboolean
-gst_audio_fx_base_fir_filter_setup (GstAudioFilter * base,
-    const GstAudioInfo * info)
-{
-  GstAudioFXBaseFIRFilter *self = GST_AUDIO_FX_BASE_FIR_FILTER (base);
-
-  g_mutex_lock (&self->lock);
-  if (self->buffer) {
-    gst_audio_fx_base_fir_filter_push_residue (self);
-    g_free (self->buffer);
-    self->buffer = NULL;
-    self->buffer_fill = 0;
-    self->buffer_length = 0;
-    self->start_ts = GST_CLOCK_TIME_NONE;
-    self->start_off = GST_BUFFER_OFFSET_NONE;
-    self->nsamples_out = 0;
-    self->nsamples_in = 0;
-  }
-
-  gst_audio_fx_base_fir_filter_select_process_function (self,
-      GST_AUDIO_INFO_FORMAT (info), GST_AUDIO_INFO_CHANNELS (info));
-  g_mutex_unlock (&self->lock);
-
-  return (self->process != NULL);
-}
-
-/* GstBaseTransform vmethod implementations */
-
-static gboolean
-gst_audio_fx_base_fir_filter_transform_size (GstBaseTransform * base,
-    GstPadDirection direction, GstCaps * caps, gsize size, GstCaps * othercaps,
-    gsize * othersize)
-{
-  GstAudioFXBaseFIRFilter *self = GST_AUDIO_FX_BASE_FIR_FILTER (base);
-  guint blocklen;
-  GstAudioInfo info;
-  gint bpf;
-
-  if (!self->fft || self->low_latency || direction == GST_PAD_SRC) {
-    *othersize = size;
-    return TRUE;
-  }
-
-  if (!gst_audio_info_from_caps (&info, caps))
-    return FALSE;
-
-  bpf = GST_AUDIO_INFO_BPF (&info);
-
-  size /= bpf;
-  blocklen = self->block_length - self->kernel_length + 1;
-  *othersize = ((size + blocklen - 1) / blocklen) * blocklen;
-  *othersize *= bpf;
-
-  return TRUE;
-}
-
-static GstFlowReturn
-gst_audio_fx_base_fir_filter_transform (GstBaseTransform * base,
-    GstBuffer * inbuf, GstBuffer * outbuf)
-{
-  GstAudioFXBaseFIRFilter *self = GST_AUDIO_FX_BASE_FIR_FILTER (base);
-  GstClockTime timestamp, expected_timestamp;
-  gint channels = GST_AUDIO_FILTER_CHANNELS (self);
-  gint rate = GST_AUDIO_FILTER_RATE (self);
-  gint bps = GST_AUDIO_FILTER_BPS (self);
-  GstMapInfo inmap, outmap;
-  guint input_samples;
-  guint output_samples;
-  guint generated_samples;
-  guint64 output_offset;
-  gint64 diff = 0;
-  GstClockTime stream_time;
-
-  timestamp = GST_BUFFER_TIMESTAMP (outbuf);
-
-  if (!GST_CLOCK_TIME_IS_VALID (timestamp)
-      && !GST_CLOCK_TIME_IS_VALID (self->start_ts)) {
-    GST_ERROR_OBJECT (self, "Invalid timestamp");
-    return GST_FLOW_ERROR;
-  }
-
-  g_mutex_lock (&self->lock);
-  stream_time =
-      gst_segment_to_stream_time (&base->segment, GST_FORMAT_TIME, timestamp);
-
-  GST_DEBUG_OBJECT (self, "sync to %" GST_TIME_FORMAT,
-      GST_TIME_ARGS (timestamp));
-
-  if (GST_CLOCK_TIME_IS_VALID (stream_time))
-    gst_object_sync_values (GST_OBJECT (self), stream_time);
-
-  g_return_val_if_fail (self->kernel != NULL, GST_FLOW_ERROR);
-  g_return_val_if_fail (channels != 0, GST_FLOW_ERROR);
-
-  if (GST_CLOCK_TIME_IS_VALID (self->start_ts))
-    expected_timestamp =
-        self->start_ts + gst_util_uint64_scale_int (self->nsamples_in,
-        GST_SECOND, rate);
-  else
-    expected_timestamp = GST_CLOCK_TIME_NONE;
-
-  /* Reset the residue if already existing on discont buffers */
-  if (GST_BUFFER_IS_DISCONT (inbuf)
-      || (GST_CLOCK_TIME_IS_VALID (expected_timestamp)
-          && (ABS (GST_CLOCK_DIFF (timestamp,
-                      expected_timestamp)) > 5 * GST_MSECOND))) {
-    GST_DEBUG_OBJECT (self, "Discontinuity detected - flushing");
-    if (GST_CLOCK_TIME_IS_VALID (expected_timestamp))
-      gst_audio_fx_base_fir_filter_push_residue (self);
-    self->buffer_fill = 0;
-    g_free (self->buffer);
-    self->buffer = NULL;
-    self->start_ts = timestamp;
-    self->start_off = GST_BUFFER_OFFSET (inbuf);
-    self->nsamples_out = 0;
-    self->nsamples_in = 0;
-  } else if (!GST_CLOCK_TIME_IS_VALID (self->start_ts)) {
-    self->start_ts = timestamp;
-    self->start_off = GST_BUFFER_OFFSET (inbuf);
-  }
-
-  gst_buffer_map (inbuf, &inmap, GST_MAP_READ);
-  gst_buffer_map (outbuf, &outmap, GST_MAP_WRITE);
-
-  input_samples = (inmap.size / bps) / channels;
-  output_samples = (outmap.size / bps) / channels;
-
-  self->nsamples_in += input_samples;
-
-  generated_samples =
-      self->process (self, inmap.data, outmap.data, input_samples);
-
-  gst_buffer_unmap (inbuf, &inmap);
-  gst_buffer_unmap (outbuf, &outmap);
-
-  g_assert (generated_samples <= output_samples);
-  self->nsamples_out += generated_samples;
-  if (generated_samples == 0)
-    goto no_samples;
-
-  /* Calculate the number of samples we can push out now without outputting
-   * latency zeros in the beginning */
-  diff = ((gint64) self->nsamples_out) - ((gint64) self->latency);
-  if (diff < 0)
-    goto no_samples;
-
-  if (diff < generated_samples) {
-    gint64 tmp = diff;
-    diff = generated_samples - diff;
-    generated_samples = tmp;
-  } else {
-    diff = 0;
-  }
-
-  gst_buffer_resize (outbuf, diff * bps * channels,
-      generated_samples * bps * channels);
-
-  output_offset = self->nsamples_out - self->latency - generated_samples;
-  GST_BUFFER_TIMESTAMP (outbuf) =
-      self->start_ts + gst_util_uint64_scale_int (output_offset, GST_SECOND,
-      rate);
-  GST_BUFFER_DURATION (outbuf) =
-      gst_util_uint64_scale_int (output_samples, GST_SECOND, rate);
-  if (self->start_off != GST_BUFFER_OFFSET_NONE) {
-    GST_BUFFER_OFFSET (outbuf) = self->start_off + output_offset;
-    GST_BUFFER_OFFSET_END (outbuf) =
-        GST_BUFFER_OFFSET (outbuf) + generated_samples;
-  } else {
-    GST_BUFFER_OFFSET (outbuf) = GST_BUFFER_OFFSET_NONE;
-    GST_BUFFER_OFFSET_END (outbuf) = GST_BUFFER_OFFSET_NONE;
-  }
-  g_mutex_unlock (&self->lock);
-
-  GST_DEBUG_OBJECT (self,
-      "Pushing buffer of size %" G_GSIZE_FORMAT " with timestamp: %"
-      GST_TIME_FORMAT ", duration: %" GST_TIME_FORMAT ", offset: %"
-      G_GUINT64_FORMAT ", offset_end: %" G_GUINT64_FORMAT ", nsamples_out: %d",
-      gst_buffer_get_size (outbuf),
-      GST_TIME_ARGS (GST_BUFFER_TIMESTAMP (outbuf)),
-      GST_TIME_ARGS (GST_BUFFER_DURATION (outbuf)), GST_BUFFER_OFFSET (outbuf),
-      GST_BUFFER_OFFSET_END (outbuf), generated_samples);
-
-  return GST_FLOW_OK;
-
-no_samples:
-  {
-    g_mutex_unlock (&self->lock);
-    return GST_BASE_TRANSFORM_FLOW_DROPPED;
-  }
-}
-
-static gboolean
-gst_audio_fx_base_fir_filter_start (GstBaseTransform * base)
-{
-  GstAudioFXBaseFIRFilter *self = GST_AUDIO_FX_BASE_FIR_FILTER (base);
-
-  self->buffer_fill = 0;
-  g_free (self->buffer);
-  self->buffer = NULL;
-  self->start_ts = GST_CLOCK_TIME_NONE;
-  self->start_off = GST_BUFFER_OFFSET_NONE;
-  self->nsamples_out = 0;
-  self->nsamples_in = 0;
-
-  return TRUE;
-}
-
-static gboolean
-gst_audio_fx_base_fir_filter_stop (GstBaseTransform * base)
-{
-  GstAudioFXBaseFIRFilter *self = GST_AUDIO_FX_BASE_FIR_FILTER (base);
-
-  g_free (self->buffer);
-  self->buffer = NULL;
-  self->buffer_length = 0;
-
-  return TRUE;
-}
-
-static gboolean
-gst_audio_fx_base_fir_filter_query (GstBaseTransform * trans,
-    GstPadDirection direction, GstQuery * query)
-{
-  GstAudioFXBaseFIRFilter *self = GST_AUDIO_FX_BASE_FIR_FILTER (trans);
-  gboolean res = TRUE;
-
-  switch (GST_QUERY_TYPE (query)) {
-    case GST_QUERY_LATENCY:
-    {
-      GstClockTime min, max;
-      gboolean live;
-      guint64 latency;
-      gint rate = GST_AUDIO_FILTER_RATE (self);
-
-      if (rate == 0) {
-        res = FALSE;
-      } else if ((res =
-              gst_pad_peer_query (GST_BASE_TRANSFORM (self)->sinkpad, query))) {
-        gst_query_parse_latency (query, &live, &min, &max);
-
-        GST_DEBUG_OBJECT (self, "Peer latency: min %"
-            GST_TIME_FORMAT " max %" GST_TIME_FORMAT,
-            GST_TIME_ARGS (min), GST_TIME_ARGS (max));
-
-        if (self->fft && !self->low_latency)
-          latency = self->block_length - self->kernel_length + 1;
-        else
-          latency = self->latency;
-
-        /* add our own latency */
-        latency = gst_util_uint64_scale_round (latency, GST_SECOND, rate);
-
-        GST_DEBUG_OBJECT (self, "Our latency: %"
-            GST_TIME_FORMAT, GST_TIME_ARGS (latency));
-
-        min += latency;
-        if (max != GST_CLOCK_TIME_NONE)
-          max += latency;
-
-        GST_DEBUG_OBJECT (self, "Calculated total latency : min %"
-            GST_TIME_FORMAT " max %" GST_TIME_FORMAT,
-            GST_TIME_ARGS (min), GST_TIME_ARGS (max));
-
-        gst_query_set_latency (query, live, min, max);
-      }
-      break;
-    }
-    default:
-      res =
-          GST_BASE_TRANSFORM_CLASS (parent_class)->query (trans, direction,
-          query);
-      break;
-  }
-  return res;
-}
-
-static gboolean
-gst_audio_fx_base_fir_filter_sink_event (GstBaseTransform * base,
-    GstEvent * event)
-{
-  GstAudioFXBaseFIRFilter *self = GST_AUDIO_FX_BASE_FIR_FILTER (base);
-
-  switch (GST_EVENT_TYPE (event)) {
-    case GST_EVENT_EOS:
-      gst_audio_fx_base_fir_filter_push_residue (self);
-      self->start_ts = GST_CLOCK_TIME_NONE;
-      self->start_off = GST_BUFFER_OFFSET_NONE;
-      self->nsamples_out = 0;
-      self->nsamples_in = 0;
-      break;
-    default:
-      break;
-  }
-
-  return GST_BASE_TRANSFORM_CLASS (parent_class)->sink_event (base, event);
-}
-
-void
-gst_audio_fx_base_fir_filter_set_kernel (GstAudioFXBaseFIRFilter * self,
-    gdouble * kernel, guint kernel_length, guint64 latency,
-    const GstAudioInfo * info)
-{
-  gboolean latency_changed;
-  GstAudioFormat format;
-  gint channels;
-
-  g_return_if_fail (kernel != NULL);
-  g_return_if_fail (self != NULL);
-
-  g_mutex_lock (&self->lock);
-
-  latency_changed = (self->latency != latency
-      || (!self->low_latency && self->kernel_length < FFT_THRESHOLD
-          && kernel_length >= FFT_THRESHOLD)
-      || (!self->low_latency && self->kernel_length >= FFT_THRESHOLD
-          && kernel_length < FFT_THRESHOLD));
-
-  /* FIXME: If the latency changes, the buffer size changes too and we
-   * have to drain in any case until this is fixed in the future */
-  if (self->buffer && (!self->drain_on_changes || latency_changed)) {
-    gst_audio_fx_base_fir_filter_push_residue (self);
-    self->start_ts = GST_CLOCK_TIME_NONE;
-    self->start_off = GST_BUFFER_OFFSET_NONE;
-    self->nsamples_out = 0;
-    self->nsamples_in = 0;
-    self->buffer_fill = 0;
-  }
-
-  g_free (self->kernel);
-  if (!self->drain_on_changes || latency_changed) {
-    g_free (self->buffer);
-    self->buffer = NULL;
-    self->buffer_fill = 0;
-    self->buffer_length = 0;
-  }
-
-  self->kernel = kernel;
-  self->kernel_length = kernel_length;
-
-  if (info) {
-    format = GST_AUDIO_INFO_FORMAT (info);
-    channels = GST_AUDIO_INFO_CHANNELS (info);
-  } else {
-    format = GST_AUDIO_FILTER_FORMAT (self);
-    channels = GST_AUDIO_FILTER_CHANNELS (self);
-  }
-
-  gst_audio_fx_base_fir_filter_calculate_frequency_response (self);
-  gst_audio_fx_base_fir_filter_select_process_function (self, format, channels);
-
-  if (latency_changed) {
-    self->latency = latency;
-    gst_element_post_message (GST_ELEMENT (self),
-        gst_message_new_latency (GST_OBJECT (self)));
-  }
-
-  g_mutex_unlock (&self->lock);
-}
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofxbasefirfilter.h	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,102 +0,0 @@
-/* -*- c-basic-offset: 2 -*-
- *
- * GStreamer
- * Copyright (C) 1999-2001 Erik Walthinsen <omega@cse.ogi.edu>
- *               2006 Dreamlab Technologies Ltd. <mathis.hofer@dreamlab.net>
- *               2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- *
- */
-
-#ifndef __GST_AUDIO_FX_BASE_FIR_FILTER_H__
-#define __GST_AUDIO_FX_BASE_FIR_FILTER_H__
-
-#include <gst/gst.h>
-#include <gst/audio/gstaudiofilter.h>
-#include <gst/fft/gstfftf64.h>
-
-G_BEGIN_DECLS
-
-#define GST_TYPE_AUDIO_FX_BASE_FIR_FILTER \
-  (gst_audio_fx_base_fir_filter_get_type())
-#define GST_AUDIO_FX_BASE_FIR_FILTER(obj) \
-  (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_AUDIO_FX_BASE_FIR_FILTER,GstAudioFXBaseFIRFilter))
-#define GST_AUDIO_FX_BASE_FIR_FILTER_CLASS(klass) \
-  (G_TYPE_CHECK_CLASS_CAST((klass),GST_TYPE_AUDIO_FX_BASE_FIR_FILTER,GstAudioFXBaseFIRFilterClass))
-#define GST_IS_AUDIO_FX_BASE_FIR_FILTER(obj) \
-  (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_AUDIO_FX_BASE_FIR_FILTER))
-#define GST_IS_AUDIO_FX_BASE_FIR_FILTER_CLASS(klass) \
-  (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_AUDIO_FX_BASE_FIR_FILTER))
-
-typedef struct _GstAudioFXBaseFIRFilter GstAudioFXBaseFIRFilter;
-typedef struct _GstAudioFXBaseFIRFilterClass GstAudioFXBaseFIRFilterClass;
-
-typedef guint (*GstAudioFXBaseFIRFilterProcessFunc) (GstAudioFXBaseFIRFilter *, const guint8 *, guint8 *, guint);
-
-/**
- * GstAudioFXBaseFIRFilter:
- *
- * Opaque data structure.
- */
-struct _GstAudioFXBaseFIRFilter {
-  GstAudioFilter element;
-
-  /* properties */
-  gdouble *kernel;              /* filter kernel -- time domain */
-  guint kernel_length;          /* length of the filter kernel -- time domain */
-
-  guint64 latency;              /* pre-latency of the filter kernel */
-  gboolean low_latency;         /* work in slower low latency mode */
-
-  gboolean drain_on_changes;    /* If the filter should be drained when
-                                 * coeficients change */
-
-  /* < private > */
-  GstAudioFXBaseFIRFilterProcessFunc process;
-
-  gdouble *buffer;              /* buffer for storing samples of previous buffers */
-  guint buffer_fill;            /* fill level of buffer */
-  guint buffer_length;          /* length of the buffer -- meaning depends on processing mode */
-
-  /* FFT convolution specific data */
-  GstFFTF64 *fft;
-  GstFFTF64 *ifft;
-  GstFFTF64Complex *frequency_response;  /* filter kernel -- frequency domain */
-  guint frequency_response_length;       /* length of filter kernel -- frequency domain */
-  GstFFTF64Complex *fft_buffer;          /* FFT buffer, has the length of the frequency response */
-  guint block_length;                    /* Length of the processing blocks -- time domain */
-
-  GstClockTime start_ts;        /* start timestamp after a discont */
-  guint64 start_off;            /* start offset after a discont */
-  guint64 nsamples_out;         /* number of output samples since last discont */
-  guint64 nsamples_in;          /* number of input samples since last discont */
-
-  GMutex lock;
-};
-
-struct _GstAudioFXBaseFIRFilterClass {
-  GstAudioFilterClass parent_class;
-};
-
-GType gst_audio_fx_base_fir_filter_get_type (void);
-void gst_audio_fx_base_fir_filter_set_kernel (GstAudioFXBaseFIRFilter *filter, gdouble *kernel,
-                                              guint kernel_length, guint64 latency, const GstAudioInfo * info);
-void gst_audio_fx_base_fir_filter_push_residue (GstAudioFXBaseFIRFilter *filter);
-
-G_END_DECLS
-
-#endif /* __GST_AUDIO_FX_BASE_FIR_FILTER_H__ */
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofxbaseiirfilter.c	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,416 +0,0 @@
-/* 
- * GStreamer
- * Copyright (C) 2007-2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <string.h>
-
-#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include <math.h>
-
-#include "audiofxbaseiirfilter.h"
-
-#define GST_CAT_DEFAULT gst_audio_fx_base_iir_filter_debug
-GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
-
-#define ALLOWED_CAPS \
-    "audio/x-raw,"                                                \
-    " format=(string){"GST_AUDIO_NE(F32)","GST_AUDIO_NE(F64)"},"  \
-    " rate = (int) [ 1, MAX ],"                                   \
-    " channels = (int) [ 1, MAX ],"                               \
-    " layout=(string) interleaved"
-
-#define gst_audio_fx_base_iir_filter_parent_class parent_class
-G_DEFINE_TYPE (GstAudioFXBaseIIRFilter,
-    gst_audio_fx_base_iir_filter, GST_TYPE_AUDIO_FILTER);
-
-static gboolean gst_audio_fx_base_iir_filter_setup (GstAudioFilter * filter,
-    const GstAudioInfo * info);
-static GstFlowReturn
-gst_audio_fx_base_iir_filter_transform_ip (GstBaseTransform * base,
-    GstBuffer * buf);
-static gboolean gst_audio_fx_base_iir_filter_stop (GstBaseTransform * base);
-
-static void process_64 (GstAudioFXBaseIIRFilter * filter,
-    gdouble * data, guint num_samples);
-static void process_32 (GstAudioFXBaseIIRFilter * filter,
-    gfloat * data, guint num_samples);
-
-/* GObject vmethod implementations */
-
-static void
-gst_audio_fx_base_iir_filter_finalize (GObject * object)
-{
-  GstAudioFXBaseIIRFilter *filter = GST_AUDIO_FX_BASE_IIR_FILTER (object);
-
-  if (filter->a) {
-    g_free (filter->a);
-    filter->a = NULL;
-  }
-
-  if (filter->b) {
-    g_free (filter->b);
-    filter->b = NULL;
-  }
-
-  if (filter->channels) {
-    GstAudioFXBaseIIRFilterChannelCtx *ctx;
-    guint i;
-
-    for (i = 0; i < filter->nchannels; i++) {
-      ctx = &filter->channels[i];
-      g_free (ctx->x);
-      g_free (ctx->y);
-    }
-
-    g_free (filter->channels);
-    filter->channels = NULL;
-  }
-  g_mutex_clear (&filter->lock);
-
-  G_OBJECT_CLASS (parent_class)->finalize (object);
-}
-
-static void
-gst_audio_fx_base_iir_filter_class_init (GstAudioFXBaseIIRFilterClass * klass)
-{
-  GObjectClass *gobject_class = (GObjectClass *) klass;
-  GstBaseTransformClass *trans_class = (GstBaseTransformClass *) klass;
-  GstAudioFilterClass *filter_class = (GstAudioFilterClass *) klass;
-  GstCaps *caps;
-
-  GST_DEBUG_CATEGORY_INIT (gst_audio_fx_base_iir_filter_debug,
-      "audiofxbaseiirfilter", 0, "Audio IIR Filter Base Class");
-
-  gobject_class->finalize = gst_audio_fx_base_iir_filter_finalize;
-
-  caps = gst_caps_from_string (ALLOWED_CAPS);
-  gst_audio_filter_class_add_pad_templates (GST_AUDIO_FILTER_CLASS (klass),
-      caps);
-  gst_caps_unref (caps);
-
-  filter_class->setup = GST_DEBUG_FUNCPTR (gst_audio_fx_base_iir_filter_setup);
-
-  trans_class->transform_ip =
-      GST_DEBUG_FUNCPTR (gst_audio_fx_base_iir_filter_transform_ip);
-  trans_class->transform_ip_on_passthrough = FALSE;
-  trans_class->stop = GST_DEBUG_FUNCPTR (gst_audio_fx_base_iir_filter_stop);
-}
-
-static void
-gst_audio_fx_base_iir_filter_init (GstAudioFXBaseIIRFilter * filter)
-{
-  gst_base_transform_set_in_place (GST_BASE_TRANSFORM (filter), TRUE);
-
-  filter->a = NULL;
-  filter->na = 0;
-  filter->b = NULL;
-  filter->nb = 0;
-  filter->channels = NULL;
-  filter->nchannels = 0;
-
-  g_mutex_init (&filter->lock);
-}
-
-/* Evaluate the transfer function that corresponds to the IIR
- * coefficients at (zr + zi*I)^-1 and return the magnitude */
-gdouble
-gst_audio_fx_base_iir_filter_calculate_gain (gdouble * a, guint na, gdouble * b,
-    guint nb, gdouble zr, gdouble zi)
-{
-  gdouble sum_ar, sum_ai;
-  gdouble sum_br, sum_bi;
-  gdouble gain_r, gain_i;
-
-  gdouble sum_r_old;
-  gdouble sum_i_old;
-
-  gint i;
-
-  sum_ar = a[na - 1];
-  sum_ai = 0.0;
-  for (i = na - 2; i >= 0; i--) {
-    sum_r_old = sum_ar;
-    sum_i_old = sum_ai;
-
-    sum_ar = (sum_r_old * zr - sum_i_old * zi) + a[i];
-    sum_ai = (sum_r_old * zi + sum_i_old * zr) + 0.0;
-  }
-
-  sum_br = b[nb - 1];
-  sum_bi = 0.0;
-  for (i = nb - 2; i >= 0; i--) {
-    sum_r_old = sum_br;
-    sum_i_old = sum_bi;
-
-    sum_br = (sum_r_old * zr - sum_i_old * zi) + b[i];
-    sum_bi = (sum_r_old * zi + sum_i_old * zr) + 0.0;
-  }
-
-  gain_r =
-      (sum_br * sum_ar + sum_bi * sum_ai) / (sum_ar * sum_ar + sum_ai * sum_ai);
-  gain_i =
-      (sum_bi * sum_ar - sum_br * sum_ai) / (sum_ar * sum_ar + sum_ai * sum_ai);
-
-  return (sqrt (gain_r * gain_r + gain_i * gain_i));
-}
-
-void
-gst_audio_fx_base_iir_filter_set_coefficients (GstAudioFXBaseIIRFilter * filter,
-    gdouble * a, guint na, gdouble * b, guint nb)
-{
-  guint i;
-
-  g_return_if_fail (GST_IS_AUDIO_FX_BASE_IIR_FILTER (filter));
-
-  g_mutex_lock (&filter->lock);
-
-  g_free (filter->a);
-  g_free (filter->b);
-
-  filter->a = filter->b = NULL;
-
-  if (filter->channels) {
-    GstAudioFXBaseIIRFilterChannelCtx *ctx;
-    gboolean free = (na != filter->na || nb != filter->nb);
-
-    for (i = 0; i < filter->nchannels; i++) {
-      ctx = &filter->channels[i];
-
-      if (free)
-        g_free (ctx->x);
-      else
-        memset (ctx->x, 0, filter->nb * sizeof (gdouble));
-
-      if (free)
-        g_free (ctx->y);
-      else
-        memset (ctx->y, 0, filter->na * sizeof (gdouble));
-    }
-
-    g_free (filter->channels);
-    filter->channels = NULL;
-  }
-
-  filter->na = na;
-  filter->nb = nb;
-
-  filter->a = a;
-  filter->b = b;
-
-  if (filter->nchannels && !filter->channels) {
-    GstAudioFXBaseIIRFilterChannelCtx *ctx;
-
-    filter->channels =
-        g_new0 (GstAudioFXBaseIIRFilterChannelCtx, filter->nchannels);
-    for (i = 0; i < filter->nchannels; i++) {
-      ctx = &filter->channels[i];
-
-      ctx->x = g_new0 (gdouble, filter->nb);
-      ctx->y = g_new0 (gdouble, filter->na);
-    }
-  }
-
-  g_mutex_unlock (&filter->lock);
-}
-
-/* GstAudioFilter vmethod implementations */
-
-static gboolean
-gst_audio_fx_base_iir_filter_setup (GstAudioFilter * base,
-    const GstAudioInfo * info)
-{
-  GstAudioFXBaseIIRFilter *filter = GST_AUDIO_FX_BASE_IIR_FILTER (base);
-  gboolean ret = TRUE;
-  gint channels;
-
-  g_mutex_lock (&filter->lock);
-  switch (GST_AUDIO_INFO_FORMAT (info)) {
-    case GST_AUDIO_FORMAT_F32:
-      filter->process = (GstAudioFXBaseIIRFilterProcessFunc)
-          process_32;
-      break;
-    case GST_AUDIO_FORMAT_F64:
-      filter->process = (GstAudioFXBaseIIRFilterProcessFunc)
-          process_64;
-      break;
-    default:
-      ret = FALSE;
-      break;
-  }
-
-  channels = GST_AUDIO_INFO_CHANNELS (info);
-
-  if (channels != filter->nchannels) {
-    guint i;
-    GstAudioFXBaseIIRFilterChannelCtx *ctx;
-
-    if (filter->channels) {
-      for (i = 0; i < filter->nchannels; i++) {
-        ctx = &filter->channels[i];
-
-        g_free (ctx->x);
-        g_free (ctx->y);
-      }
-      g_free (filter->channels);
-    }
-
-    filter->channels = g_new0 (GstAudioFXBaseIIRFilterChannelCtx, channels);
-    for (i = 0; i < channels; i++) {
-      ctx = &filter->channels[i];
-
-      ctx->x = g_new0 (gdouble, filter->nb);
-      ctx->y = g_new0 (gdouble, filter->na);
-    }
-    filter->nchannels = channels;
-  }
-  g_mutex_unlock (&filter->lock);
-
-  return ret;
-}
-
-static inline gdouble
-process (GstAudioFXBaseIIRFilter * filter,
-    GstAudioFXBaseIIRFilterChannelCtx * ctx, gdouble x0)
-{
-  gdouble val = filter->b[0] * x0;
-  gint i, j;
-
-  for (i = 1, j = ctx->x_pos; i < filter->nb; i++) {
-    val += filter->b[i] * ctx->x[j];
-    j--;
-    if (j < 0)
-      j = filter->nb - 1;
-  }
-
-  for (i = 1, j = ctx->y_pos; i < filter->na; i++) {
-    val -= filter->a[i] * ctx->y[j];
-    j--;
-    if (j < 0)
-      j = filter->na - 1;
-  }
-  val /= filter->a[0];
-
-  if (ctx->x) {
-    ctx->x_pos++;
-    if (ctx->x_pos >= filter->nb)
-      ctx->x_pos = 0;
-    ctx->x[ctx->x_pos] = x0;
-  }
-  if (ctx->y) {
-    ctx->y_pos++;
-    if (ctx->y_pos >= filter->na)
-      ctx->y_pos = 0;
-
-    ctx->y[ctx->y_pos] = val;
-  }
-
-  return val;
-}
-
-#define DEFINE_PROCESS_FUNC(width,ctype) \
-static void \
-process_##width (GstAudioFXBaseIIRFilter * filter, \
-    g##ctype * data, guint num_samples) \
-{ \
-  gint i, j, channels = filter->nchannels; \
-  gdouble val; \
-  \
-  for (i = 0; i < num_samples / channels; i++) { \
-    for (j = 0; j < channels; j++) { \
-      val = process (filter, &filter->channels[j], *data); \
-      *data++ = val; \
-    } \
-  } \
-}
-
-DEFINE_PROCESS_FUNC (32, float);
-DEFINE_PROCESS_FUNC (64, double);
-
-#undef DEFINE_PROCESS_FUNC
-
-/* GstBaseTransform vmethod implementations */
-static GstFlowReturn
-gst_audio_fx_base_iir_filter_transform_ip (GstBaseTransform * base,
-    GstBuffer * buf)
-{
-  GstAudioFXBaseIIRFilter *filter = GST_AUDIO_FX_BASE_IIR_FILTER (base);
-  guint num_samples;
-  GstClockTime timestamp, stream_time;
-  GstMapInfo map;
-
-  timestamp = GST_BUFFER_TIMESTAMP (buf);
-  stream_time =
-      gst_segment_to_stream_time (&base->segment, GST_FORMAT_TIME, timestamp);
-
-  GST_DEBUG_OBJECT (filter, "sync to %" GST_TIME_FORMAT,
-      GST_TIME_ARGS (timestamp));
-
-  if (GST_CLOCK_TIME_IS_VALID (stream_time))
-    gst_object_sync_values (GST_OBJECT (filter), stream_time);
-
-  gst_buffer_map (buf, &map, GST_MAP_READWRITE);
-  num_samples = map.size / GST_AUDIO_FILTER_BPS (filter);
-
-  g_mutex_lock (&filter->lock);
-  if (filter->a == NULL || filter->b == NULL) {
-    g_warn_if_fail (filter->a != NULL && filter->b != NULL);
-    gst_buffer_unmap (buf, &map);
-    g_mutex_unlock (&filter->lock);
-    return GST_FLOW_ERROR;
-  }
-  filter->process (filter, map.data, num_samples);
-  g_mutex_unlock (&filter->lock);
-
-  gst_buffer_unmap (buf, &map);
-
-  return GST_FLOW_OK;
-}
-
-
-static gboolean
-gst_audio_fx_base_iir_filter_stop (GstBaseTransform * base)
-{
-  GstAudioFXBaseIIRFilter *filter = GST_AUDIO_FX_BASE_IIR_FILTER (base);
-  guint channels = filter->nchannels;
-  GstAudioFXBaseIIRFilterChannelCtx *ctx;
-  guint i;
-
-  /* Reset the history of input and output values if
-   * already existing */
-  if (channels && filter->channels) {
-    for (i = 0; i < channels; i++) {
-      ctx = &filter->channels[i];
-      g_free (ctx->x);
-      g_free (ctx->y);
-    }
-    g_free (filter->channels);
-  }
-  filter->channels = NULL;
-  filter->nchannels = 0;
-
-  return TRUE;
-}
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audiofxbaseiirfilter.h	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,79 +0,0 @@
-/*
- * GStreamer
- * Copyright (C) 2007-2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifndef __GST_AUDIO_FX_BASE_IIR_FILTER_H__
-#define __GST_AUDIO_FX_BASE_IIR_FILTER_H__
-
-#include <gst/gst.h>
-#include <gst/base/gstbasetransform.h>
-#include <gst/audio/audio.h>
-#include <gst/audio/gstaudiofilter.h>
-
-G_BEGIN_DECLS
-
-#define GST_TYPE_AUDIO_FX_BASE_IIR_FILTER            (gst_audio_fx_base_iir_filter_get_type())
-#define GST_AUDIO_FX_BASE_IIR_FILTER(obj)            (G_TYPE_CHECK_INSTANCE_CAST((obj),GST_TYPE_AUDIO_FX_BASE_IIR_FILTER,GstAudioFXBaseIIRFilter))
-#define GST_IS_AUDIO_FX_BASE_IIR_FILTER(obj)         (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_AUDIO_FX_BASE_IIR_FILTER))
-#define GST_AUDIO_FX_BASE_IIR_FILTER_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST((klass) ,GST_TYPE_AUDIO_FX_BASE_IIR_FILTER,GstAudioFXBaseIIRFilterClass))
-#define GST_IS_AUDIO_FX_BASE_IIR_FILTER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass) ,GST_TYPE_AUDIO_FX_BASE_IIR_FILTER))
-#define GST_AUDIO_FX_BASE_IIR_FILTER_GET_CLASS(obj)  (G_TYPE_INSTANCE_GET_CLASS((obj) ,GST_TYPE_AUDIO_FX_BASE_IIR_FILTER,GstAudioFXBaseIIRFilterClass))
-typedef struct _GstAudioFXBaseIIRFilter GstAudioFXBaseIIRFilter;
-typedef struct _GstAudioFXBaseIIRFilterClass GstAudioFXBaseIIRFilterClass;
-
-typedef void (*GstAudioFXBaseIIRFilterProcessFunc) (GstAudioFXBaseIIRFilter *, guint8 *, guint);
-
-typedef struct
-{
-  gdouble *x;
-  gint x_pos;
-  gdouble *y;
-  gint y_pos;
-} GstAudioFXBaseIIRFilterChannelCtx;
-
-struct _GstAudioFXBaseIIRFilter
-{
-  GstAudioFilter audiofilter;
-
-  /* < private > */
-  GstAudioFXBaseIIRFilterProcessFunc process;
-
-  gboolean have_coeffs;
-  gdouble *a;
-  guint na;
-  gdouble *b;
-  guint nb;
-  GstAudioFXBaseIIRFilterChannelCtx *channels;
-  guint nchannels;
-
-  GMutex lock;
-};
-
-struct _GstAudioFXBaseIIRFilterClass
-{
-  GstAudioFilterClass parent;
-};
-
-GType gst_audio_fx_base_iir_filter_get_type (void);
-void gst_audio_fx_base_iir_filter_set_coefficients (GstAudioFXBaseIIRFilter *filter, gdouble *a, guint na, gdouble *b, guint nb);
-gdouble gst_audio_fx_base_iir_filter_calculate_gain (gdouble *a, guint na, gdouble *b, guint nb, gdouble zr, gdouble zi);
-
-G_END_DECLS
-
-#endif /* __GST_AUDIO_FX_BASE_IIR_FILTER_H__ */
--- a/modules/media/src/main/native/gstreamer/gstreamer-lite/gst-plugins-good/gst/audiofx/audioiirfilter.c	Fri Sep 18 16:15:42 2015 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,281 +0,0 @@
-/* 
- * GStreamer
- * Copyright (C) 2009 Sebastian Dröge <sebastian.droege@collabora.co.uk>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- * 
- */
-
-/**
- * SECTION:element-audioiirfilter
- *
- * audioiirfilter implements a generic audio <ulink url="http://en.wikipedia.org/wiki/Infinite_impulse_response">IIR filter</ulink>. Before usage the
- * "a" and "b" properties have to be set to the filter coefficients that
- * should be used.
- *
- * The filter coefficients describe the numerator and denominator of the
- * transfer function.
- *
- * To change the filter coefficients whenever the sampling rate changes the
- * "rate-changed" signal can be used. This should be done for most
- * IIR filters as they're depending on the sampling rate.
- *
- * <refsect2>
- * <title>Example application</title>
- * <informalexample><programlisting language="C">
- * <xi:include xmlns:xi="http://www.w3.org/2003/XInclude" parse="text" href="../../../../tests/examples/audiofx/iirfilter-example.c" />
- * </programlisting></informalexample>
- * </refsect2>
- */
-
-/* FIXME 0.11: suppress warnings for deprecated API such as GValueArray
- * with newer GLib versions (>= 2.31.0) */
-#define GLIB_DISABLE_DEPRECATION_WARNINGS
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <string.h>
-#include <math.h>
-#include <gst/gst.h>
-#include <gst/audio/gstaudiofilter.h>
-
-#include "audioiirfilter.h"
-
-#include "gst/glib-compat-private.h"
-
-#define GST_CAT_DEFAULT gst_audio_iir_filter_debug
-GST_DEBUG_CATEGORY_STATIC (GST_CAT_DEFAULT);
-
-enum
-{
-  SIGNAL_RATE_CHANGED,