1. 24 Sep, 2018 1 commit
    • Tim-Philipp Müller's avatar
      libs: figure out right export define in configure · 57c8e014
      Tim-Philipp Müller authored
      Add new GST_API_EXPORT in config.h and use that for GST_*_API
      decorators instead of GST_EXPORT.
      
      The right export define depends on the toolchain and whether
      we're using -fvisibility=hidden or not, so it's better to set it
      to the right thing directly than hard-coding a compiler whitelist
      in the public header.
      
      We put the export define into config.h instead of passing it via the
      command line to the compiler because it might contain spaces and brackets
      and in the autotools scenario we'd have to pass that through multiple
      layers of plumbing and Makefile/shell escaping and we're just not going
      to be *that* lucky.
      
      The export define is only used if we're compiling our lib, not by external
      users of the lib headers, so it's not a problem to put it into config.h
      
      Also, this means all .c files of libs need to include config.h
      to get the export marker defined, so fix up a few that didn't
      include config.h.
      
      This commit depends on a common submodule commit that makes gst-glib-gen.mak
      add an #include "config.h" to generated enum/marshal .c files for the
      autotools build.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=797185
      57c8e014
  2. 24 Jun, 2018 1 commit
  3. 03 Jun, 2018 1 commit
  4. 08 Apr, 2017 1 commit
    • Tim-Philipp Müller's avatar
      Don't use deprecated g_object_newv() · 519d6488
      Tim-Philipp Müller authored
      Use g_object_new() instead which nowadays has a shortcut for the
      no-properties check. It still does an extra GType check in the
      function guard, but there's a pending patch to remove that
      and it's hardly going to be a performance issue in practice,
      even less so on a system that's compiled without run-time checks.
      
      Alternative would be to move to the new g_object_new_properties()
      with a fallback define for older glib versions, but it makes the
      code look more unwieldy and doesn't seem worth it.
      
      Fixes deprecation warnings when building against newer GLib versions.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=780903
      519d6488
  5. 27 Jan, 2017 1 commit
  6. 06 Nov, 2014 1 commit
  7. 26 Jun, 2014 1 commit
  8. 07 Jun, 2014 1 commit
  9. 06 Jun, 2014 2 commits
  10. 07 Dec, 2013 1 commit
  11. 16 Nov, 2013 1 commit
  12. 13 Aug, 2013 1 commit
    • Thiago Santos's avatar
      dataqueue: add gst_data_queue_push_force · 581c4297
      Thiago Santos authored
      Adds a variant of the _push function that doesn't check the queue limits
      before adding the new item. It is useful when pushing an element to the
      queue shouldn't lock the thread.
      
      One particular scenario is when the queue is used to serialize buffers
      and events that are going to be pushed from another thread. The
      dataqueue should have a limit on the amount of buffers to be stored to
      avoid large memory consumption, but events can be considered to have
      negligible impact on memory compared to buffers. So it is useful to be
      used to push items into the queue that contain events, even though the
      queue is already full, it shouldn't matter inserting an item that has
      no significative size.
      
      This scenario happens on adaptive elements (dashdemux / mssdemux) as
      there is a single download thread fetching buffers and putting into the
      dataqueues for the streams. This same download thread can als generate
      events in some situations as caps changes, eos or a internal control
      events. There can be a deadlock at preroll if the first buffer fetched
      is large enough to fill the dataqueue and the download thread and the
      next iteration of the download thread decides to push an event to this
      same dataqueue before fetching buffers to other streams, if this push
      locks, the pipeline will be stuck in preroll as no more buffers will be
      downloaded.
      There is a somewhat common practice in dash streams to have a single
      very large buffer for audio and one for video, so this will always
      happen as the download thread will have to push an EOS right after
      fetching the first buffer for any stream.
      
      API: gst_data_queue_push_force
      
      https://bugzilla.gnome.org/show_bug.cgi?id=705694
      581c4297
  13. 18 Apr, 2013 1 commit
    • Thiago Santos's avatar
      dataqueue: add gst_data_queue_peek · 1681a1b1
      Thiago Santos authored
      This function works just like gst_data_queue_pop, but it doesn't
      remove the object from the queue.
      
      Useful when inspecting multiple GstDataQueues to decide from which
      to pop the element from.
      
      Add: gst_data_queue_peek
      1681a1b1
  14. 30 Jan, 2013 1 commit
  15. 25 Nov, 2012 1 commit
  16. 03 Nov, 2012 1 commit
  17. 25 Oct, 2012 1 commit
  18. 14 Jul, 2012 1 commit
  19. 10 Jul, 2012 1 commit
  20. 04 Jul, 2012 1 commit
  21. 19 Jan, 2012 1 commit
  22. 07 Oct, 2011 1 commit
  23. 22 Feb, 2011 1 commit
  24. 02 Dec, 2010 2 commits
  25. 16 Oct, 2010 2 commits
  26. 13 Oct, 2010 2 commits
  27. 17 Mar, 2010 1 commit
  28. 27 Nov, 2009 1 commit
  29. 28 Oct, 2009 2 commits
    • Edward Hervey's avatar
      optimisation : Use g_object_newv where possible. · 27284628
      Edward Hervey authored
      This avoids:
      * triple-checking for the GType when type-checking is enabled (see #597260)
      * Avoids going through an expensive no-argument checking which landed in
        glib-2.22
      * Avoids going through 2 extrac functions (g_object_new -> g_object_new_valist)
      27284628
    • Tim-Philipp Müller's avatar
      Remove GST_DEBUG_FUNCPTR where they're pointless · daecaf0e
      Tim-Philipp Müller authored
      There's not much point in using GST_DEBUG_FUNCPTR with GObject
      virtual functions such as get_property, set_propery, finalize and
      dispose, since they'll never be used by anyone anyway. Saves a
      few bytes and possibly a tenth of a polar bear.
      daecaf0e
  30. 07 Oct, 2009 2 commits
  31. 06 Oct, 2009 1 commit
  32. 04 Apr, 2009 1 commit
  33. 22 Mar, 2008 1 commit
    • Sebastian Dröge's avatar
      Define G_PARAM_STATIC_STRINGS if it's undefined (GLib < 2.13.0) and use it... · b0346dff
      Sebastian Dröge authored
      Define G_PARAM_STATIC_STRINGS if it's undefined (GLib < 2.13.0) and use it everywhere for GParamSpecs that use static...
      
      Original commit message from CVS:
      * docs/pwg/advanced-dparams.xml:
      * docs/pwg/building-props.xml:
      * docs/pwg/other-source.xml:
      * gst/glib-compat.h:
      * gst/gstbin.c: (gst_bin_class_init):
      * gst/gstclock.c: (gst_clock_class_init):
      * gst/gstindex.c: (gst_index_class_init):
      * gst/gstobject.c: (gst_object_class_init):
      * gst/gstpad.c: (gst_pad_class_init):
      * gst/gstpipeline.c: (gst_pipeline_class_init):
      * libs/gst/base/gstbasesink.c: (gst_base_sink_class_init):
      * libs/gst/base/gstbasesrc.c: (gst_base_src_class_init):
      * libs/gst/base/gstbasetransform.c:
      (gst_base_transform_class_init):
      * libs/gst/base/gstdataqueue.c: (gst_data_queue_class_init):
      * libs/gst/check/gstcheck.c: (_gst_check_fault_handler_restore),
      (_gst_check_fault_handler_sighandler),
      (_gst_check_fault_handler_setup), (gst_check_init):
      * libs/gst/controller/gstcontroller.c:
      (_gst_controller_class_init):
      * libs/gst/controller/gstlfocontrolsource.c:
      (gst_lfo_control_source_class_init):
      * libs/gst/net/gstnetclientclock.c:
      (gst_net_client_clock_class_init):
      * libs/gst/net/gstnettimeprovider.c:
      (gst_net_time_provider_class_init):
      * plugins/elements/gstcapsfilter.c: (gst_capsfilter_class_init):
      * plugins/elements/gstfakesink.c: (gst_fake_sink_class_init):
      * plugins/elements/gstfakesrc.c: (gst_fake_src_class_init):
      * plugins/elements/gstfdsink.c: (gst_fd_sink_class_init):
      * plugins/elements/gstfdsrc.c: (gst_fd_src_class_init):
      * plugins/elements/gstfilesink.c: (gst_file_sink_class_init):
      * plugins/elements/gstfilesrc.c: (gst_file_src_class_init):
      * plugins/elements/gstidentity.c: (gst_identity_class_init):
      * plugins/elements/gstmultiqueue.c: (gst_multi_queue_class_init):
      * plugins/elements/gstqueue.c: (gst_queue_class_init):
      * plugins/elements/gsttee.c: (gst_tee_class_init):
      * plugins/elements/gsttypefindelement.c:
      (gst_type_find_element_class_init):
      * plugins/indexers/gstfileindex.c: (gst_file_index_class_init):
      Define G_PARAM_STATIC_STRINGS if it's undefined (GLib < 2.13.0) and
      use it everywhere for GParamSpecs that use static strings (i.e. all).
      This gives us less memory usage, fewer allocations and thus less
      memory defragmentation. Fixes bug #523806.
      b0346dff
  34. 03 Feb, 2008 1 commit
    • Sebastian Dröge's avatar
      Don't use base_init where not absolutely necessary. For example it's not... · 9db28f85
      Sebastian Dröge authored
      Don't use base_init where not absolutely necessary. For example it's not necessary anymore for adding pad templates o...
      
      Original commit message from CVS:
      * gst/gstbin.c: (gst_bin_get_type), (gst_bin_class_init):
      * gst/gstpipeline.c: (gst_pipeline_get_type),
      (gst_pipeline_class_init):
      * libs/gst/base/gstbasesink.c: (gst_base_sink_get_type),
      (gst_base_sink_class_init):
      * libs/gst/base/gstbasesrc.c: (gst_base_src_get_type),
      (gst_base_src_class_init):
      * libs/gst/base/gstbasetransform.c: (gst_base_transform_get_type),
      (gst_base_transform_class_init):
      * libs/gst/base/gstcollectpads.c: (gst_collect_pads_base_init),
      (gst_collect_pads_class_init):
      * libs/gst/base/gstdataqueue.c: (gst_data_queue_get_type):
      * libs/gst/net/gstnettimeprovider.c:
      (gst_net_time_provider_base_init),
      (gst_net_time_provider_class_init):
      * plugins/elements/gstcapsfilter.c: (gst_capsfilter_base_init),
      (gst_capsfilter_class_init):
      * plugins/elements/gstfakesink.c: (gst_fake_sink_base_init),
      (gst_fake_sink_class_init):
      * plugins/elements/gstfakesrc.c: (gst_fake_src_base_init),
      (gst_fake_src_class_init):
      * plugins/elements/gstfdsink.c: (gst_fd_sink_base_init),
      (gst_fd_sink_class_init):
      * plugins/elements/gstfdsrc.c: (gst_fd_src_base_init),
      (gst_fd_src_class_init):
      * plugins/elements/gstfilesink.c: (gst_file_sink_base_init),
      (gst_file_sink_class_init):
      * plugins/elements/gstfilesrc.c: (gst_file_src_base_init),
      (gst_file_src_class_init):
      * plugins/elements/gstidentity.c: (gst_identity_base_init),
      (gst_identity_class_init):
      * plugins/elements/gstmultiqueue.c: (gst_multi_queue_base_init),
      (gst_multi_queue_class_init):
      * plugins/elements/gstqueue.c: (gst_queue_base_init),
      (gst_queue_class_init):
      * plugins/elements/gsttee.c: (gst_tee_base_init),
      (gst_tee_class_init):
      * plugins/elements/gsttypefindelement.c:
      (gst_type_find_element_base_init),
      (gst_type_find_element_class_init):
      Don't use base_init where not absolutely necessary. For example it's
      not necessary anymore for adding pad templates or setting element
      details.
      Leave empty base_init functions in several places as GST_BOILERPLATE
      still defines and uses them.
      9db28f85