Alright, thanks, I understand that it's a complex issue.<br><br><br><div class="gmail_quote">On Sun, Sep 9, 2012 at 2:31 PM, José Alburquerque <span dir="ltr"><<a href="mailto:jaalburquerque@cox.net" target="_blank">jaalburquerque@cox.net</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">On Sun, 2012-09-09 at 07:01 -0400, José Alburquerque wrote:<br>
> On Sep 9, 2012, at 4:19 AM, José Alburquerque <<a href="mailto:jaalburquerque@cox.net">jaalburquerque@cox.net</a>> wrote:<br>
><br>
> > On Sun, 2012-09-09 at 09:46 +0300, Jiergir Ogoerg wrote:<br>
> >> Thanks,<br>
> >> To my desktop app startup time is critical, so, if I switch to the Gst<br>
> >> C interface do you think the gst_init() would never take longer than<br>
> >> say 200 milliseconds? Or is it nonetheless possible for it to take<br>
> >> much longer like over 1-2 seconds in some cases?<br>
> ><br>
> > Actually, I think I spoke too soon in my last post.<br>
> ><br>
> > I was just thinking things through more thoroughly and since plug-in<br>
> > types are not accessible in C.  It may be possible to register the<br>
> > wrapping functions for these plug-in types later (when they are<br>
> > constructed) and not at startup (in Gst::init()) since it is not<br>
> > possible to have these plug-in types from some C code and then try to<br>
> > wrap them in a C++ wrapper which is why we go through the process of<br>
> > loading the plug-ins and registering the wrapping functions in the first<br>
> > place.  It may not even be necessary to register wrapping functions for<br>
> > these plug-in types.<br>
><br>
> Sorry, I'm just wrong here.  Though the C types are not available, having one from C code is possible because the plug-ins are created using the GType system.  Registering the wrapping functions for plug-ins is thus still vital upon initialization.<br>

><br>
> You're better off using C.  I hope I didn't give you false hopes.<br>
<br>
</div>Okay.  I'm going back and forth because the issue is more complicated<br>
than what I thought.  Could you please ignore this last post.  I'll look<br>
at this during the week and not rush.  If it's possible it will be in<br>
the release.  If not it wont.  Sorry.<br>
<div class="HOEnZb"><div class="h5"><br>
><br>
> -Jose<br>
><br>
> ><br>
> > If the above is so, startup time (Gst::init()) will probably never be<br>
> > more than the 100ms you mentioned.<br>
> ><br>
> > I'll be looking into this this week at the end of which a new release<br>
> > should be out.  If it this is doable, I'll include it in that release.<br>
> ><br>
> > In the meanwhile, however, I'm sure that using C will never have such a<br>
> > slow start-up time.  gst_init() does not load all the possible plug-ins<br>
> > as gstreamermm does right now.<br>
> >><br>
> >><br>
> >> On Sun, Sep 9, 2012 at 7:37 AM, José Alburquerque<br>
> >> <<a href="mailto:jaalburquerque@cox.net">jaalburquerque@cox.net</a>> wrote:<br>
> >>       On Sat, 2012-09-08 at 13:19 +0300, Jiergir Ogoerg wrote:<br>
> >>> Hi,<br>
> >>> Gst::init() takes like 100+ ms, on rare occasions it takes<br>
> >>       even<br>
> >>> longer, like over 2-4 seconds. Is it normal?<br>
> >><br>
> >><br>
> >>       Probably.  The reason is that Gst::init() not only initializes<br>
> >>       GStreamer, it also initializes glibmm (which it relies on) and<br>
> >>       registers<br>
> >>       methods that wrap C types to correct C++ types for all the<br>
> >>       GStreamer<br>
> >>       GObject and GstMiniObject derived types and all the GStreamer<br>
> >>       plug-in<br>
> >>       types that gstreamermm makes available to be used in a C++<br>
> >>       way.  In the<br>
> >>       process, it must load all the plug-ins that gstreamermm makes<br>
> >>       available<br>
> >>       (this is probably the most time consuming part though only for<br>
> >>       the<br>
> >>       execution for which the plug-ins have not been loaded; the<br>
> >>       rest of the<br>
> >>       executions wont experience so much a delay).  We know of no<br>
> >>       other way to<br>
> >>       ensure that the C objects handled are correctly differentiated<br>
> >>       and<br>
> >>       treated as appropriate C++ classes.<br>
> >><br>
> >>><br>
> >>> To combat this I do Gst::init() in another pthread for my<br>
> >>       gui app to<br>
> >>> show up instantly as usually.<br>
> >>><br>
> >>> Using Ubuntu 12.04 amd64.<br>
> >>> Intel Core i5.<br>
> >><br>
> >>> _______________________________________________<br>
> >>> gstreamer-devel mailing list<br>
> >>> <a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
> >>><br>
> >>       <a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
> >><br>
> >><br>
> >>       --<br>
> >>       José<br>
> >><br>
> >>       _______________________________________________<br>
> >>       gstreamer-devel mailing list<br>
> >>       <a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
> >>       <a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
> >><br>
> >><br>
> >> _______________________________________________<br>
> >> gstreamer-devel mailing list<br>
> >> <a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
> >> <a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
> ><br>
> > --<br>
> > José<br>
> ><br>
> > _______________________________________________<br>
> > gstreamer-devel mailing list<br>
> > <a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
> > <a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
><br>
> _______________________________________________<br>
> gstreamer-devel mailing list<br>
> <a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
> <a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br>
--<br>
José<br>
<br>
_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
</div></div></blockquote></div><br>