Creating elements for the first time takes ages

Edward Hervey bilboed at gmail.com
Thu Jun 21 08:20:20 PDT 2012


Hi,

On Thu, 2012-06-21 at 07:36 -0700, Ralph wrote:
> I wrote a WPF application using OSSBuild and C# bindings.
> I notice that creating GStreamer elements for the first time using
> ElementFactory take ages.
> Creating the following set of elements for the first time takes 9 seconds on
> a very fast machine:
> - pipeline
> - gnlcomposition
> - gnlsource
> - gnlfilesource
> - audiotestsrc
> - videotestsrc
> Creating the same set for the second time takes just 120ms - that's
> absolutely fine.
> 
> All elements are created the same way:
> Gst.Element element = Gst.ElementFactory.Make("elementtype");
> 
> I understand that creating an element for the first time requires finding
> the appropriate assembly, discovering some stuff and instantiating a few
> objects, but it should not be that slow!  The users of my application are
> complaining about the initialization time.
> 
> Is there any way of speeding up element creation?

  You should profile what takes up those 9s. How much does creating each
element take ? What is going on in the background ?

  A simple look at GStreamer debug logs might show the culprit.

  This should not happen, in case you're wondering.

> 
> 
> --
> View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Creating-elements-for-the-first-time-takes-ages-tp4655367.html
> Sent from the GStreamer-devel mailing list archive at Nabble.com.
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel




More information about the gstreamer-devel mailing list