tracer: make gst_tracing_register_hook_id static
authorStefan Sauer <ensonic@users.sf.net>
Wed, 6 Jan 2016 19:41:26 +0000 (20:41 +0100)
committerStefan Sauer <ensonic@users.sf.net>
Wed, 6 Jan 2016 19:46:58 +0000 (20:46 +0100)
We don't need to expose this as public API. Change the only plugin that was
using it.

docs/gst/gstreamer-sections.txt
gst/gsttracer.h
gst/gsttracerutils.c
plugins/tracers/gstrusage.c

index 81b1033..0ecc51d 100644 (file)
@@ -3044,7 +3044,6 @@ gst_toc_scope_get_type
 GstTracer
 gst_tracer_register
 gst_tracing_register_hook
-gst_tracing_register_hook_id
 gst_tracer_log_trace
 <SUBSECTION Standard>
 GST_TRACER
index a5953f2..059433b 100644 (file)
@@ -55,16 +55,14 @@ struct _GstTracer {
 
 struct _GstTracerClass {
   GstObjectClass parent_class;
-    
+
   /*< private >*/
   gpointer _gst_reserved[GST_PADDING];
 };
 
 GType gst_tracer_get_type          (void);
 
-void gst_tracing_register_hook (GstTracer *tracer, const gchar *detail, 
-  GCallback func);
-void gst_tracing_register_hook_id (GstTracer *tracer, GQuark detail, 
+void gst_tracing_register_hook (GstTracer *tracer, const gchar *detail,
   GCallback func);
 
 /* tracing modules */
index 64c24af..974930a 100644 (file)
@@ -151,15 +151,7 @@ _priv_gst_tracing_deinit (void)
   _priv_tracers = NULL;
 }
 
-/**
- * gst_tracing_register_hook_id:
- * @tracer: the tracer
- * @detail: the detailed hook
- * @func: (scope async): the callback
- *
- * Register @func to be called when the trace hook @detail is getting invoked.
- */
-void
+static void
 gst_tracing_register_hook_id (GstTracer * tracer, GQuark detail, GCallback func)
 {
   gpointer key = GINT_TO_POINTER (detail);
@@ -182,6 +174,7 @@ gst_tracing_register_hook_id (GstTracer * tracer, GQuark detail, GCallback func)
  * @func: (scope async): the callback
  *
  * Register @func to be called when the trace hook @detail is getting invoked.
+ * Use %NULL for @detail to register to all hooks.
  */
 void
 gst_tracing_register_hook (GstTracer * tracer, const gchar * detail,
index 6ea2685..3db1011 100644 (file)
@@ -351,7 +351,7 @@ gst_rusage_tracer_init (GstRUsageTracer * self)
 {
   GstTracer *tracer = GST_TRACER (self);
 
-  gst_tracing_register_hook_id (tracer, 0, G_CALLBACK (do_stats));
+  gst_tracing_register_hook (tracer, NULL, G_CALLBACK (do_stats));
 
   self->threads = g_hash_table_new_full (NULL, NULL, NULL, free_thread_stats);
   self->tvs_proc = make_trace_values (GST_SECOND);