[gst-devel] Multiple GStreamer inits

Jan Schmidt thaytan at noraisin.net
Thu Oct 9 14:54:36 CEST 2008


On Thu, 2008-10-09 at 14:27 +0200, Arne Caspari wrote:
> Hello, 
> 
> I want to use GStreamer in a plugin for another application but I have
> the following issue there: 
> 
> I need to call gst_init ( or gst_init_check ) when the plugin gets
> loaded. But I seem to be able to call gst_init only once, subsequent
> calls will crash. This will lead to an application crash any time the
> plugin unloads and reloads. Calling gst_deinit also does not help. 
> 
> Am I missing something obvious? Is there any way to determine whether
> GStreamer is already initialized? 
> 

gst_init can be called as many times as you like. After the first call,
it's a no-op. Calling gst_deinit will break things though - they're not
symmetrical calls. Once you've called gst_deinit, you can't use
GStreamer at all any more in that process - you can't reinitialise it by
calling gst_init again.

J.
-- 
Jan Schmidt <thaytan at noraisin.net>





More information about the gstreamer-devel mailing list