static void gst_core_media_meta_free (GstCoreMediaMeta * meta, GstBuffer * buf) { if (meta->image_buf != NULL) { GstCVApi *cv = meta->ctx->cv; cv->CVPixelBufferUnlockBaseAddress (meta->image_buf, kCVPixelBufferLock_ReadOnly); } meta->ctx->cm->FigSampleBufferRelease (meta->sample_buf); g_object_unref (meta->ctx); }
static void gst_core_video_meta_free (GstCoreVideoMeta * meta, GstBuffer * buf) { GstCVApi *cv = meta->ctx->cv; if (meta->pixbuf != NULL) { cv->CVPixelBufferUnlockBaseAddress (meta->pixbuf, kCVPixelBufferLock_ReadOnly); } cv->CVBufferRelease (meta->cvbuf); g_object_unref (meta->ctx); }
static void gst_core_video_buffer_finalize (GstMiniObject * mini_object) { GstCoreVideoBuffer *self = GST_CORE_VIDEO_BUFFER_CAST (mini_object); GstCVApi *cv = self->ctx->cv; if (self->pixbuf != NULL) { cv->CVPixelBufferUnlockBaseAddress (self->pixbuf, kCVPixelBufferLock_ReadOnly); } cv->CVBufferRelease (self->cvbuf); g_object_unref (self->ctx); GST_MINI_OBJECT_CLASS (gst_core_video_buffer_parent_class)->finalize (mini_object); }