diff options
author | Matthias Vogelgesang <matthias.vogelgesang@ipe.fzk.de> | 2011-03-09 10:10:13 +0100 |
---|---|---|
committer | Matthias Vogelgesang <matthias.vogelgesang@ipe.fzk.de> | 2011-03-09 10:10:13 +0100 |
commit | 876c0214e6f341d071929026a08e1b127e8a0b7f (patch) | |
tree | dfdd2b510ed02409a989917d9aeeaebae6dcc376 /src/cameras/pco.c | |
parent | 12ebb0471719b2993c6dd49c58a5965018737320 (diff) | |
download | uca-876c0214e6f341d071929026a08e1b127e8a0b7f.tar.gz uca-876c0214e6f341d071929026a08e1b127e8a0b7f.tar.bz2 uca-876c0214e6f341d071929026a08e1b127e8a0b7f.tar.xz uca-876c0214e6f341d071929026a08e1b127e8a0b7f.zip |
Almost real video playback
Diffstat (limited to 'src/cameras/pco.c')
-rw-r--r-- | src/cameras/pco.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/cameras/pco.c b/src/cameras/pco.c index b84ee01..ccf7d90 100644 --- a/src/cameras/pco.c +++ b/src/cameras/pco.c @@ -48,6 +48,7 @@ static uint32_t uca_pco_acquire_image(struct uca_camera_t *cam, void *buffer) static uint32_t uca_pco_destroy(struct uca_camera_t *cam) { + pco_set_rec_state(GET_PCO(cam), 0); pco_destroy(GET_PCO(cam)); return UCA_NO_ERROR; } @@ -231,7 +232,8 @@ uint32_t uca_pco_grab(struct uca_camera_t *cam, char *buffer) if (err != UCA_NO_ERROR) return err; /* FIXME: choose according to data format */ - pco_reorder_image_5x16((uint16_t *) buffer, frame, cam->frame_width, cam->frame_height); + //pco_reorder_image_5x16((uint16_t *) buffer, frame, cam->frame_width, cam->frame_height); + memcpy(buffer, frame, cam->frame_width*cam->frame_height*2); return UCA_NO_ERROR; } @@ -251,7 +253,7 @@ uint32_t uca_pco_init(struct uca_camera_t **cam, struct uca_grabber_t *grabber) struct uca_camera_t *uca = (struct uca_camera_t *) malloc(sizeof(struct uca_camera_t)); uca->user = pco; uca->grabber = grabber; - uca->grabber->asynchronous = false; + uca->grabber->asynchronous = true; /* Camera found, set function pointers... */ uca->destroy = &uca_pco_destroy; |