patches/gnome-media-05-solaris.diff
changeset 3154 1251b5084aa3
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/gnome-media-05-solaris.diff	Tue Jun 15 21:08:09 2004 +0000
@@ -0,0 +1,48 @@
+--- gnome-media-2.6.1/grecord/src/gsr-window.c-orig	Fri May 28 15:55:33 2004
++++ gnome-media-2.6.1/grecord/src/gsr-window.c	Fri May 28 16:12:13 2004
+@@ -1316,6 +1316,10 @@
+ 	GSRWindowPipeline *obj;
+ 	GstElement *pipeline;
+ 	guint32 id;
++#ifdef __sun
++	GstElement *audioconvert;
++	GstElement *audioscale;
++#endif
+ 	GstElement *spider;
+ 
+ 	pipeline = gst_pipeline_new ("play-pipeline");
+@@ -1343,6 +1347,20 @@
+ 		return NULL;
+ 	}
+ 	
++#ifdef __sun
++ 	audioconvert = gst_element_factory_make ("audioconvert", "audioconvert");
++	if (!audioconvert) {
++		g_error ("Could not find element audioconvert");
++		return NULL;
++	}
++	
++ 	audioscale = gst_element_factory_make ("audioscale", "audioscale");
++	if (!audioscale) {
++		g_error ("Could not find element audioscale");
++		return NULL;
++	}
++#endif
++	
+ 	obj->sink = gst_gconf_get_default_audio_sink ();
+ 	if (!obj->sink)
+ 	{
+@@ -1350,8 +1368,13 @@
+ 		return NULL;
+ 	}
+ 
++#ifdef __sun
++	gst_bin_add_many (GST_BIN (pipeline), obj->src, spider, audioconvert, audioscale, obj->sink, NULL);
++	gst_element_link_many (obj->src, spider, audioconvert, audioscale, obj->sink, NULL);
++#else
+ 	gst_bin_add_many (GST_BIN (pipeline), obj->src, spider, obj->sink, NULL);
+ 	gst_element_link_many (obj->src, spider, obj->sink, NULL);
++#endif
+ 
+ 	return obj;
+ }