summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWim Taymans <wim.taymans@gmail.com>2001-03-06 22:32:27 +0000
committerWim Taymans <wim.taymans@gmail.com>2001-03-06 22:32:27 +0000
commit031e0a3acbcdf6535102d219bc2361d86891e624 (patch)
treebeb12231ed3f3f64902a5446392160503551355f
parent30685cb8c908b1d3c39aa747d579fcf90b595e5a (diff)
Small fixes to pipeline and gstbin.HEAD-20010306-PRE_AUTOPLUG2
Original commit message from CVS: Small fixes to pipeline and gstbin. Fixed the xmmstest makefile entry Removed the plugin_load statements in videotest Applied the patch from Steve Baker for float args parsing
-rw-r--r--gst/gstbin.c2
-rw-r--r--gst/gstpipeline.c1
-rw-r--r--gst/gstutils.c6
-rw-r--r--test/.gitignore1
-rw-r--r--test/Makefile.am3
-rw-r--r--test/videotest.c2
-rw-r--r--test/xmmstest.c12
7 files changed, 16 insertions, 11 deletions
diff --git a/gst/gstbin.c b/gst/gstbin.c
index 452aa05d6..d33078b02 100644
--- a/gst/gstbin.c
+++ b/gst/gstbin.c
@@ -260,6 +260,8 @@ gst_bin_change_state (GstElement *element)
if (!parent || !GST_IS_BIN (parent))
gst_bin_create_plan (bin);
+ else
+ GST_DEBUG (0,"not creating plan for '%s'\n",GST_ELEMENT_NAME (bin));
break;
}
diff --git a/gst/gstpipeline.c b/gst/gstpipeline.c
index 139db8a3e..065de192b 100644
--- a/gst/gstpipeline.c
+++ b/gst/gstpipeline.c
@@ -158,7 +158,6 @@ gst_pipeline_typefind (GstPipeline *pipeline, GstElement *element)
gst_bin_add (GST_BIN (pipeline), typefind);
//gst_bin_create_plan (GST_BIN (pipeline));
- gst_element_set_state (GST_ELEMENT (pipeline), GST_STATE_READY);
gst_element_set_state (GST_ELEMENT (pipeline), GST_STATE_PLAYING);
// keep pushing buffers... the have_type signal handler will set the found flag
diff --git a/gst/gstutils.c b/gst/gstutils.c
index 167a80a86..a7dcf0158 100644
--- a/gst/gstutils.c
+++ b/gst/gstutils.c
@@ -247,9 +247,9 @@ void gst_util_set_object_arg (GtkObject *object, guchar *name, gchar *value)
break;
}
case GTK_TYPE_DOUBLE: {
- gdouble i;
- sscanf (value, "%g", (float *)&i);
- gtk_object_set (GTK_OBJECT (object), name, i, NULL);
+ gfloat i;
+ sscanf (value, "%g", &i);
+ gtk_object_set (GTK_OBJECT (object), name, (gdouble)i, NULL);
break;
}
default:
diff --git a/test/.gitignore b/test/.gitignore
index 537f35552..86f0ab3ce 100644
--- a/test/.gitignore
+++ b/test/.gitignore
@@ -45,3 +45,4 @@ mp2toavi
mp1tomp1
pipetest
mp3tovorbis
+xmmstest
diff --git a/test/Makefile.am b/test/Makefile.am
index a0d2d7586..9fa04486c 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -1,10 +1,9 @@
# FIXME FIXME
-bin_PROGRAMS = xmmstest
noinst_PROGRAMS = qtest spectrum record wave mp3 teardown buffer mp3parse \
mpeg2parse mp1parse mp3play ac3parse ac3play dvdcat fake cobin videotest \
aviparse vidcapture avi2mpg mp2tomp1 mp1tomp1 pipetest \
- vidcapture2 mp2toavi mp3tovorbis mpeg2parse2
+ vidcapture2 mp2toavi mp3tovorbis mpeg2parse2 xmmstest
SUBDIRS = xml bindings
diff --git a/test/videotest.c b/test/videotest.c
index 6171491a7..9c0856646 100644
--- a/test/videotest.c
+++ b/test/videotest.c
@@ -25,8 +25,6 @@ int main(int argc,char *argv[]) {
//_gst_plugin_spew = TRUE;
gst_init(&argc,&argv);
- gst_plugin_load("v4lsrc");
- gst_plugin_load("videosink");
gnome_init("Videotest","0.0.1",argc,argv);
diff --git a/test/xmmstest.c b/test/xmmstest.c
index 382b1f695..3402d2832 100644
--- a/test/xmmstest.c
+++ b/test/xmmstest.c
@@ -5,11 +5,12 @@ extern gboolean _gst_plugin_spew;
gboolean idle_func(gpointer data);
+GstElement *src;
+
int
main (int argc,char *argv[])
{
GstElement *bin;
- GstElement *src;
GstElement *effect;
GstElement *audiosink;
@@ -17,9 +18,9 @@ main (int argc,char *argv[])
bin = gst_bin_new("bin");
- src = gst_elementfactory_make("XMMS_INPUT_mpeg_layer_1/2/3_player_1.2.4", "xmms_plugin");
+ //src = gst_elementfactory_make("XMMS_INPUT_mpeg_layer_1/2/3_player_1.2.4", "xmms_plugin");
//src = gst_elementfactory_make("XMMS_INPUT_oggvorbis_player_0.1", "xmms_plugin");
- //src = gst_elementfactory_make("XMMS_INPUT_mikmod_player_1.2.4", "xmms_plugin");
+ src = gst_elementfactory_make("XMMS_INPUT_mikmod_player_1.2.4", "xmms_plugin");
//src = gst_elementfactory_make("XMMS_INPUT_tone_generator_1.2.4", "xmms_plugin");
g_return_val_if_fail(src != NULL, -1);
@@ -31,6 +32,11 @@ main (int argc,char *argv[])
gtk_object_set (GTK_OBJECT (src), "location", argv[1], NULL);
//gtk_object_set (GTK_OBJECT (src), "filename", "tone://1000", NULL);
+ g_print ("Song Info (text:length): %s\n",gst_util_get_string_arg (GTK_OBJECT (src), "song_info"));
+ //gtk_object_set (GTK_OBJECT (src), "show_about", TRUE, NULL);
+ //gtk_object_set (GTK_OBJECT (src), "configure", TRUE, NULL);
+ //gtk_object_set (GTK_OBJECT (src), "show_file_info", TRUE, NULL);
+
audiosink = gst_elementfactory_make("audiosink", "audiosink");
g_return_val_if_fail(audiosink != NULL, -1);