diff options
author | Matthias Vogelgesang <matthias.vogelgesang@kit.edu> | 2012-03-01 12:32:10 +0100 |
---|---|---|
committer | Matthias Vogelgesang <matthias.vogelgesang@kit.edu> | 2012-03-01 12:32:10 +0100 |
commit | b29c78f818ac92f42621c69c29736fe5c8e32c6f (patch) | |
tree | fcafd885b20775ee329ad1f02cce8cce9c557cf6 /test/test-gobject.c | |
parent | 13b9b1492cb8aadef6c2905e48cbde93a7135cc0 (diff) | |
download | libuca-b29c78f818ac92f42621c69c29736fe5c8e32c6f.tar.gz libuca-b29c78f818ac92f42621c69c29736fe5c8e32c6f.tar.bz2 libuca-b29c78f818ac92f42621c69c29736fe5c8e32c6f.tar.xz libuca-b29c78f818ac92f42621c69c29736fe5c8e32c6f.zip |
Initial prototype of GObject-based libuca
Diffstat (limited to 'test/test-gobject.c')
-rw-r--r-- | test/test-gobject.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/test/test-gobject.c b/test/test-gobject.c new file mode 100644 index 0000000..392a4f3 --- /dev/null +++ b/test/test-gobject.c @@ -0,0 +1,20 @@ +#include <glib-object.h> +#include "uca-camera.h" +#include "uca-mock-camera.h" + +int main(int argc, char **argv) +{ + g_type_init(); + + UcaMockCamera *cam = (UcaMockCamera *) g_object_new(UCA_TYPE_MOCK_CAMERA, NULL); + + guint width; + g_object_get(cam, + "sensor-width", &width, + NULL); + g_print("width = %i\n", width); + + uca_camera_start_recording(UCA_CAMERA(cam)); + + g_object_unref(cam); +} |