mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-24 02:31:03 +00:00
gl/colorconvert: use GstObject's lock instead of our own
This commit is contained in:
parent
768c6de84e
commit
4b5c5a7d37
2 changed files with 4 additions and 9 deletions
|
@ -409,7 +409,6 @@ gst_gl_color_convert_class_init (GstGLColorConvertClass * klass)
|
||||||
static void
|
static void
|
||||||
gst_gl_color_convert_init (GstGLColorConvert * convert)
|
gst_gl_color_convert_init (GstGLColorConvert * convert)
|
||||||
{
|
{
|
||||||
g_mutex_init (&convert->lock);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -448,8 +447,6 @@ gst_gl_color_convert_finalize (GObject * object)
|
||||||
convert->context = NULL;
|
convert->context = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
g_mutex_clear (&convert->lock);
|
|
||||||
|
|
||||||
G_OBJECT_CLASS (gst_gl_color_convert_parent_class)->finalize (object);
|
G_OBJECT_CLASS (gst_gl_color_convert_parent_class)->finalize (object);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -515,9 +512,9 @@ void
|
||||||
gst_gl_color_convert_set_format (GstGLColorConvert * convert,
|
gst_gl_color_convert_set_format (GstGLColorConvert * convert,
|
||||||
GstVideoInfo * in_info, GstVideoInfo * out_info)
|
GstVideoInfo * in_info, GstVideoInfo * out_info)
|
||||||
{
|
{
|
||||||
g_mutex_lock (&convert->lock);
|
GST_OBJECT_LOCK (convert);
|
||||||
_gst_gl_color_convert_set_format_unlocked (convert, in_info, out_info);
|
_gst_gl_color_convert_set_format_unlocked (convert, in_info, out_info);
|
||||||
g_mutex_unlock (&convert->lock);
|
GST_OBJECT_UNLOCK (convert);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -537,9 +534,9 @@ gst_gl_color_convert_perform (GstGLColorConvert * convert, GstBuffer * inbuf)
|
||||||
|
|
||||||
g_return_val_if_fail (convert != NULL, FALSE);
|
g_return_val_if_fail (convert != NULL, FALSE);
|
||||||
|
|
||||||
g_mutex_lock (&convert->lock);
|
GST_OBJECT_LOCK (convert);
|
||||||
ret = _gst_gl_color_convert_perform_unlocked (convert, inbuf);
|
ret = _gst_gl_color_convert_perform_unlocked (convert, inbuf);
|
||||||
g_mutex_unlock (&convert->lock);
|
GST_OBJECT_UNLOCK (convert);
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
|
@ -46,8 +46,6 @@ struct _GstGLColorConvert
|
||||||
/* <private> */
|
/* <private> */
|
||||||
GstObject parent;
|
GstObject parent;
|
||||||
|
|
||||||
GMutex lock;
|
|
||||||
|
|
||||||
GstGLContext *context;
|
GstGLContext *context;
|
||||||
|
|
||||||
/* input data */
|
/* input data */
|
||||||
|
|
Loading…
Reference in a new issue