gst/audioconvert/plugin.c: Register the GstAudioChannelPosition enum type with the...
authorTim-Philipp Müller <tim@centricular.net>
Tue, 14 Feb 2006 18:52:52 +0000 (18:52 +0000)
committerTim-Philipp Müller <tim@centricular.net>
Tue, 14 Feb 2006 18:52:52 +0000 (18:52 +0000)
Original commit message from CVS:
* gst/audioconvert/plugin.c: (plugin_init):
Register the GstAudioChannelPosition enum type with the type
system in the plugin_init function, so that it is known before
any element actually makes use of multi-channel stuff. This is
required for example if one wants to be able to deserialise/use
a caps string with channel positions before any pipeline has
been setup and started, like with gst-launch.

ChangeLog
gst/audioconvert/plugin.c

index ce28248..e3417f5 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2006-02-14  Tim-Philipp Müller  <tim at centricular dot net>
+
+       * gst/audioconvert/plugin.c: (plugin_init):
+         Register the GstAudioChannelPosition enum type with the type
+         system in the plugin_init function, so that it is known before
+         any element actually makes use of multi-channel stuff. This is
+         required for example if one wants to be able to deserialise/use
+         a caps string with channel positions before any pipeline has
+         been setup and started, like with gst-launch.
+
 2006-02-14  Wim Taymans  <wim@fluendo.com>
 
        * gst-libs/gst/audio/gstringbuffer.c:
index 0452ac3..643737a 100644 (file)
 
 #include "plugin.h"
 
+#include <gst/audio/multichannel.h>
+
 static gboolean
 plugin_init (GstPlugin * plugin)
 {
+  /* ensure GstAudioChannelPosition type is registered */
+  if (!gst_audio_channel_position_get_type ())
+    return FALSE;
+
   if (!gst_element_register (plugin, "audioconvert",
           GST_RANK_PRIMARY, gst_audio_convert_get_type ()))
     return FALSE;