pleorasink: use async queues and improve debug messages

This commit is contained in:
Joshua M. Doe
2021-08-02 14:44:51 -04:00
parent 63295f7290
commit 02dd4126ac
4 changed files with 58 additions and 68 deletions

View File

@@ -255,9 +255,6 @@ gst_pleorasink_init (GstPleoraSink * sink)
sink->source = new GstStreamingChannelSource ();
sink->source->SetSink (sink);
sink->device = new PvSoftDeviceGEV ();
g_mutex_init (&sink->mutex);
g_cond_init (&sink->cond);
}
void
@@ -396,9 +393,6 @@ gst_pleorasink_dispose (GObject * object)
sink->source = NULL;
}
g_mutex_clear (&sink->mutex);
g_cond_clear (&sink->cond);
g_free (sink->address);
G_OBJECT_CLASS (gst_pleorasink_parent_class)->dispose (object);
@@ -695,7 +689,6 @@ GstFlowReturn
gst_pleorasink_render (GstBaseSink * basesink, GstBuffer * buffer)
{
GstPleoraSink *sink = GST_PLEORASINK (basesink);
GST_LOG_OBJECT (sink, "Rendering buffer");
if (sink->stop_requested) {
GST_DEBUG_OBJECT (sink, "stop requested, flushing");
@@ -713,10 +706,7 @@ gst_pleorasink_unlock (GstBaseSink * basesink)
{
GstPleoraSink *sink = GST_PLEORASINK (basesink);
g_mutex_lock (&sink->mutex);
sink->stop_requested = TRUE;
g_cond_signal (&sink->cond);
g_mutex_unlock (&sink->mutex);
return TRUE;
}