camerabin2: Do not forget to unref some stuff
Cleanup properly by unrefing the encoding profile and preview caps
This commit is contained in:
parent
b66dde5746
commit
68bff61732
@ -278,6 +278,12 @@ gst_camera_bin_dispose (GObject * object)
|
|||||||
if (camerabin->imagebin_capsfilter)
|
if (camerabin->imagebin_capsfilter)
|
||||||
gst_object_unref (camerabin->imagebin_capsfilter);
|
gst_object_unref (camerabin->imagebin_capsfilter);
|
||||||
|
|
||||||
|
if (camerabin->video_profile)
|
||||||
|
gst_encoding_profile_unref (camerabin->video_profile);
|
||||||
|
|
||||||
|
if (camerabin->preview_caps)
|
||||||
|
gst_caps_replace (&camerabin->preview_caps, NULL);
|
||||||
|
|
||||||
G_OBJECT_CLASS (parent_class)->dispose (object);
|
G_OBJECT_CLASS (parent_class)->dispose (object);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -71,6 +71,9 @@ gst_wrapper_camera_bin_src_dispose (GObject * object)
|
|||||||
self->preview_pipeline = NULL;
|
self->preview_pipeline = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (self->preview_caps)
|
||||||
|
gst_caps_replace (&self->preview_caps, NULL);
|
||||||
|
|
||||||
G_OBJECT_CLASS (parent_class)->dispose (object);
|
G_OBJECT_CLASS (parent_class)->dispose (object);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user