diff --git a/subprojects/gst-plugins-base/gst-libs/gst/gl/cocoa/gstglcontext_cocoa.m b/subprojects/gst-plugins-base/gst-libs/gst/gl/cocoa/gstglcontext_cocoa.m index 3adb0cd6be..6b618d2fd9 100644 --- a/subprojects/gst-plugins-base/gst-libs/gst/gl/cocoa/gstglcontext_cocoa.m +++ b/subprojects/gst-plugins-base/gst-libs/gst/gl/cocoa/gstglcontext_cocoa.m @@ -352,7 +352,12 @@ gst_gl_context_cocoa_swap_buffers (GstGLContext * context) static void gst_gl_context_cocoa_destroy_context (GstGLContext *context) { - /* FIXME: Need to release context and other things? */ + GstGLContextCocoa *context_cocoa = GST_GL_CONTEXT_COCOA (context); + + if (context_cocoa->priv->gl_context != NULL) { + CGLDestroyContext(context_cocoa->priv->gl_context); + context_cocoa->priv->gl_context = NULL; + } } static guintptr