summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMatthias Vogelgesang <matthias.vogelgesang@gmail.com>2012-07-05 16:54:21 +0200
committerMatthias Vogelgesang <matthias.vogelgesang@gmail.com>2012-07-05 17:08:07 +0200
commitb932591750fbaddb7c6f180804f626911b2f0419 (patch)
tree322700799758603a586a9d42c7be391486767045 /src
parent137c5d8b0211582e747b5321aeafe2916ce83319 (diff)
downloadlibuca-b932591750fbaddb7c6f180804f626911b2f0419.tar.gz
libuca-b932591750fbaddb7c6f180804f626911b2f0419.tar.bz2
libuca-b932591750fbaddb7c6f180804f626911b2f0419.tar.xz
libuca-b932591750fbaddb7c6f180804f626911b2f0419.zip
Fix LU-24: add "sensor-max-adcs"
Diffstat (limited to 'src')
-rw-r--r--src/cameras/uca-pco-camera.c17
1 files changed, 16 insertions, 1 deletions
diff --git a/src/cameras/uca-pco-camera.c b/src/cameras/uca-pco-camera.c
index 26894e1..5a52834 100644
--- a/src/cameras/uca-pco-camera.c
+++ b/src/cameras/uca-pco-camera.c
@@ -101,6 +101,7 @@ enum {
PROP_SENSOR_PIXELRATES,
PROP_SENSOR_PIXELRATE,
PROP_SENSOR_ADCS,
+ PROP_SENSOR_MAX_ADCS,
PROP_DELAY_TIME,
PROP_HAS_DOUBLE_IMAGE_MODE,
PROP_DOUBLE_IMAGE_MODE,
@@ -267,7 +268,7 @@ static guint override_temperature_range(UcaPcoCameraPrivate *priv)
return err;
}
-void property_override_default_guint_value (GObjectClass *oclass, const gchar *property_name, guint new_default)
+static void property_override_default_guint_value (GObjectClass *oclass, const gchar *property_name, guint new_default)
{
GParamSpecUInt *pspec = G_PARAM_SPEC_UINT (g_object_class_find_property (oclass, property_name));
@@ -944,6 +945,13 @@ static void uca_pco_camera_get_property(GObject *object, guint property_id, GVal
}
break;
+ case PROP_SENSOR_MAX_ADCS:
+ {
+ GParamSpecUInt *spec = (GParamSpecUInt *) pco_properties[PROP_SENSOR_ADCS];
+ g_value_set_uint(value, spec->maximum);
+ }
+ break;
+
case PROP_SENSOR_PIXELRATES:
g_value_set_boxed(value, priv->pixelrates);
break;
@@ -1350,6 +1358,13 @@ static void uca_pco_camera_class_init(UcaPcoCameraClass *klass)
1, 2, 1,
G_PARAM_READWRITE);
+ pco_properties[PROP_SENSOR_MAX_ADCS] =
+ g_param_spec_uint("sensor-max-adcs",
+ "Maximum number of ADCs",
+ "Maximum number of ADCs that can be set with \"sensor-adcs\"",
+ 1, G_MAXUINT, 1,
+ G_PARAM_READABLE);
+
pco_properties[PROP_TIMESTAMP_MODE] =
g_param_spec_flags("timestamp-mode",
"Timestamp mode",