diff options
author | Matthias Vogelgesang <matthias.vogelgesang@ipe.fzk.de> | 2011-03-10 10:25:12 +0100 |
---|---|---|
committer | Matthias Vogelgesang <matthias.vogelgesang@ipe.fzk.de> | 2011-03-10 10:25:12 +0100 |
commit | f0cb3317a0cf8333c03b0a45e3bb25c7490f85ef (patch) | |
tree | 58ebebc3f22375fe5d1e40e851f0907476f701c9 /src/cameras/ipe.c | |
parent | c3b3cfd97b51bf6e6970156c92506cb6fa037b65 (diff) | |
download | uca-f0cb3317a0cf8333c03b0a45e3bb25c7490f85ef.tar.gz uca-f0cb3317a0cf8333c03b0a45e3bb25c7490f85ef.tar.bz2 uca-f0cb3317a0cf8333c03b0a45e3bb25c7490f85ef.tar.xz uca-f0cb3317a0cf8333c03b0a45e3bb25c7490f85ef.zip |
Add IPE infrastructure and make sure that cameras check grabber existence
Diffstat (limited to 'src/cameras/ipe.c')
-rw-r--r-- | src/cameras/ipe.c | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/src/cameras/ipe.c b/src/cameras/ipe.c new file mode 100644 index 0000000..30c7b16 --- /dev/null +++ b/src/cameras/ipe.c @@ -0,0 +1,60 @@ + +#include <stdlib.h> +#include <string.h> +#include <pcilib.h> +#include "uca.h" +#include "uca-cam.h" +#include "uca-grabber.h" + +#define set_void(p, type, value) { *((type *) p) = value; } + +static uint32_t uca_ipe_acquire_image(struct uca_camera_t *cam, void *buffer) +{ + return UCA_NO_ERROR; +} + +static uint32_t uca_ipe_set_property(struct uca_camera_t *cam, enum uca_property_ids property, void *data) +{ + return UCA_NO_ERROR; +} + +static uint32_t uca_ipe_get_property(struct uca_camera_t *cam, enum uca_property_ids property, void *data) +{ + return UCA_NO_ERROR; +} + +uint32_t uca_ipe_start_recording(struct uca_camera_t *cam) +{ + return UCA_NO_ERROR; +} + +uint32_t uca_ipe_stop_recording(struct uca_camera_t *cam) +{ + return UCA_NO_ERROR; +} + +uint32_t uca_ipe_grab(struct uca_camera_t *cam, char *buffer) +{ + return UCA_NO_ERROR; +} + +static uint32_t uca_ipe_destroy(struct uca_camera_t *cam) +{ + return UCA_NO_ERROR; +} + +uint32_t uca_ipe_init(struct uca_camera_t **cam, struct uca_grabber_t *grabber) +{ + /* Camera found, set function pointers... */ + uca->destroy = &uca_ipe_destroy; + uca->set_property = &uca_ipe_set_property; + uca->get_property = &uca_ipe_get_property; + uca->start_recording = &uca_ipe_start_recording; + uca->stop_recording = &uca_ipe_stop_recording; + uca->grab = &uca_ipe_grab; + + uca->state = UCA_CAM_CONFIGURABLE; + *cam = uca; + + return UCA_NO_ERROR; +} |