summaryrefslogtreecommitdiffstats
path: root/gst-libs/gst/interfaces/photography.c
diff options
context:
space:
mode:
authorDave Robillard <dave@drobilla.net>2009-06-19 21:03:10 -0400
committerDave Robillard <dave@drobilla.net>2009-06-19 21:03:10 -0400
commit23953f27c870c42ce369d717bc15b7f8001691a1 (patch)
tree19b3999c7b0c36fcefcbbcaaaa9102f612670ca7 /gst-libs/gst/interfaces/photography.c
parentd365eafd8f2cdb1ded93fe4bd95e568026abf0da (diff)
parent925e83ee60c5406b2e5f0f39b0da0f90370efc27 (diff)
downloadgst-plugins-bad-23953f27c870c42ce369d717bc15b7f8001691a1.tar.gz
gst-plugins-bad-23953f27c870c42ce369d717bc15b7f8001691a1.tar.bz2
gst-plugins-bad-23953f27c870c42ce369d717bc15b7f8001691a1.zip
Merge branch 'fdo' into lv2
Diffstat (limited to 'gst-libs/gst/interfaces/photography.c')
-rw-r--r--gst-libs/gst/interfaces/photography.c52
1 files changed, 52 insertions, 0 deletions
diff --git a/gst-libs/gst/interfaces/photography.c b/gst-libs/gst/interfaces/photography.c
index 4d62cf46..63f389ab 100644
--- a/gst-libs/gst/interfaces/photography.c
+++ b/gst-libs/gst/interfaces/photography.c
@@ -90,6 +90,8 @@ gst_photography_iface_init (GstPhotographyInterface * iface)
iface->get_capabilities = NULL;
iface->prepare_for_capture = NULL;
iface->set_autofocus = NULL;
+ iface->set_config = NULL;
+ iface->get_config = NULL;
}
#define GST_PHOTOGRAPHY_FUNC_TEMPLATE(function_name, param_type) \
@@ -369,3 +371,53 @@ gst_photography_set_autofocus (GstPhotography * photo, gboolean on)
iface->set_autofocus (photo, on);
}
}
+
+/**
+ * gst_photography_set_config:
+ * @photo: #GstPhotography interface of a #GstElement
+ * @config: #GstPhotoSettings containg the configuration
+ *
+ * Set all configuration settings at once.
+ *
+ * Returns: TRUE if configuration was set successfully, otherwise FALSE.
+ */
+gboolean
+gst_photography_set_config (GstPhotography * photo, GstPhotoSettings *config)
+{
+ GstPhotographyInterface *iface;
+ gboolean ret = FALSE;
+
+ g_return_val_if_fail (photo != NULL, FALSE);
+
+ iface = GST_PHOTOGRAPHY_GET_IFACE (photo);
+ if (iface->set_config) {
+ ret = iface->set_config (photo, config);
+ }
+
+ return ret;
+}
+
+/**
+ * gst_photography_get_config:
+ * @photo: #GstPhotography interface of a #GstElement
+ * @config: #GstPhotoSettings containg the configuration
+ *
+ * Get all configuration settings at once.
+ *
+ * Returns: TRUE if configuration was got successfully, otherwise FALSE.
+ */
+gboolean
+gst_photography_get_config (GstPhotography * photo, GstPhotoSettings * config)
+{
+ GstPhotographyInterface *iface;
+ gboolean ret = FALSE;
+
+ g_return_val_if_fail (photo != NULL, FALSE);
+
+ iface = GST_PHOTOGRAPHY_GET_IFACE (photo);
+ if (iface->get_config) {
+ ret = iface->get_config (photo, config);
+ }
+
+ return ret;
+}