[cheese] cheese-camera: Unsetting preview-caps after photo
- From: Luciana Fujii Pontello <lufujii src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [cheese] cheese-camera: Unsetting preview-caps after photo
- Date: Wed, 9 Mar 2011 20:46:27 +0000 (UTC)
commit 353077775b8d5560c1458a1e9850e7d470cc26ab
Author: Luciana Fujii Pontello <luciana fujii eti br>
Date: Mon Feb 28 21:40:13 2011 -0300
cheese-camera: Unsetting preview-caps after photo
After taking a photo to pixbuf, we set preview-caps to NULL so regular
photo doesn't send the preview message.
libcheese/cheese-camera.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/libcheese/cheese-camera.c b/libcheese/cheese-camera.c
index eb96db3..e610e70 100644
--- a/libcheese/cheese-camera.c
+++ b/libcheese/cheese-camera.c
@@ -141,6 +141,7 @@ cheese_camera_photo_data (CheeseCamera *camera, GstBuffer *buffer)
GdkPixbuf *pixbuf;
const int bits_per_pixel = 8;
guchar *data = NULL;
+ CheeseCameraPrivate *priv = CHEESE_CAMERA_GET_PRIVATE (camera);
caps = gst_buffer_get_caps (buffer);
structure = gst_caps_get_structure (caps, 0);
@@ -155,6 +156,7 @@ cheese_camera_photo_data (CheeseCamera *camera, GstBuffer *buffer)
FALSE, bits_per_pixel, width, height, stride,
data ? (GdkPixbufDestroyNotify) g_free : NULL, NULL);
+ g_object_set (G_OBJECT (priv->camerabin), "preview-caps", NULL, NULL);
g_signal_emit (camera, camera_signals[PHOTO_TAKEN], 0, pixbuf);
g_object_unref (pixbuf);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]