directsoundsrc plugin. no change_state function pipleline hangs when changing state

tanmay.ambre ambre.tanmay at
Fri Mar 30 05:15:54 PDT 2012

I am using directsoundsrc plugin to capture audio on windows.

The plugin works fine except when I want to close it gracefully. 

I send an EOS event to the pipeline


capture the EOS message and close the main loop

/g_main_loop_quit (mainLoop);/

and the quit gracefully
/		g_main_loop_run (mainLoop);
		/* Out of the main loop, clean up nicely */
		gst_element_set_state (pipeline_sound_capture, GST_STATE_NULL); ///Stuck
		gst_object_unref (GST_OBJECT (pipeline_sound_capture));

The execution is stuck when I am changing the state to NULL.

I noticed that there is no change_state function assigned in the

Could this be causing a problem?

I am guessing that the purpose of the function is to facilitate the change
of state of the plugin.

Another thing I tried was changing the state of the soundcapture element to
NULL. and the execution hangs there as well.


The same pattern works well for video. using ksvideosrc plugin

Any help appreciated. I will try to add the code for change_state  in
gstdirectsoundsrc.c and see if it works.

I am using OSSBuild 


Tanmay Ambre

View this message in context:
Sent from the GStreamer-devel mailing list archive at

More information about the gstreamer-devel mailing list