mirror of
https://github.com/openmv/openmv.git
synced 2025-09-26 23:09:13 +08:00
drivers: Update framebuffer API.
Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
This commit is contained in:
parent
b1f81f7cdd
commit
cd2a4d4f95
@ -440,7 +440,7 @@ static int snapshot(omv_csi_t *csi, image_t *image, uint32_t flags) {
|
||||
fb->pixfmt = csi->pixformat;
|
||||
|
||||
image_t fb_image;
|
||||
framebuffer_init_image(fb, &fb_image);
|
||||
framebuffer_to_image(fb, &fb_image);
|
||||
|
||||
LEP_SYS_FPA_TEMPERATURE_KELVIN_T kelvin;
|
||||
if (lepton.measurement_mode && (!lepton.radiometry)) {
|
||||
@ -481,7 +481,7 @@ static int snapshot(omv_csi_t *csi, image_t *image, uint32_t flags) {
|
||||
NULL, NULL, NULL, NULL);
|
||||
|
||||
fb_alloc_free_till_mark();
|
||||
framebuffer_init_image(fb, image);
|
||||
framebuffer_to_image(fb, image);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -84,8 +84,8 @@ static int snapshot(omv_csi_t *csi, image_t *image, uint32_t flags) {
|
||||
fb->h = csi->transpose ? fb->u : fb->v;
|
||||
|
||||
// The new buffer hasn't been released yet, so the data pointer
|
||||
// has to be set manually after calling framebuffer_init_image.
|
||||
framebuffer_init_image(fb, image);
|
||||
// has to be set manually after calling framebuffer_to_image.
|
||||
framebuffer_to_image(fb, image);
|
||||
image->pixels = buffer->data;
|
||||
|
||||
static uint32_t step = 0;
|
||||
@ -129,7 +129,7 @@ static int snapshot(omv_csi_t *csi, image_t *image, uint32_t flags) {
|
||||
|
||||
// Move the buffer from free queue -> used queue.
|
||||
framebuffer_release(fb, FB_FLAG_FREE);
|
||||
framebuffer_init_image(fb, image);
|
||||
framebuffer_to_image(fb, image);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user