summaryrefslogtreecommitdiffstats
path: root/src/uca.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/uca.h')
-rw-r--r--src/uca.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/src/uca.h b/src/uca.h
new file mode 100644
index 0000000..2f93093
--- /dev/null
+++ b/src/uca.h
@@ -0,0 +1,32 @@
+#ifndef __UNIFIED_CAMERA_ACCESS_H
+#define __UNIFIED_CAMERA_ACCESS_H
+
+struct uca_t;
+
+/*
+ * \brief Camera probing and initialization
+ * \return 0 if camera is not found or could not be initialized
+ */
+typedef int (*uca_cam_init) (struct uca_t *uca);
+
+typedef void (*uca_cam_destroy) (struct uca_t *uca);
+
+#define UCA_BIG_ENDIAN 1
+#define UCA_LITTLE_ENDIAN 2
+
+struct uca_t {
+ /* These must be written by uca_cam_init() */
+ unsigned int image_width;
+ unsigned int image_height;
+ unsigned int image_bitdepth;
+ unsigned int image_flags;
+
+ /* Function pointers to camera-specific methods */
+ uca_cam_destroy cam_destroy;
+};
+
+struct uca_t *uca_init();
+void uca_destroy(struct uca_t *uca);
+
+
+#endif