mirror of
https://github.com/openmv/openmv.git
synced 2025-11-04 14:49:50 +08:00
Fix the frame size check when copying images to FB.
* The size of the image to be copied was compared to the size of the current frame instead of the size of the whole buffer.
This commit is contained in:
parent
1d93c54983
commit
b1b7c74b15
@ -383,7 +383,7 @@ void py_helper_update_framebuffer(image_t *img)
|
||||
|
||||
void py_helper_set_to_framebuffer(image_t *img)
|
||||
{
|
||||
PY_ASSERT_TRUE_MSG((image_size(img) <= framebuffer_get_frame_size()),
|
||||
PY_ASSERT_TRUE_MSG((image_size(img) <= framebuffer_get_buffer_size()),
|
||||
"The image doesn't fit in the frame buffer!");
|
||||
framebuffer_set(img->w, img->h, img->bpp);
|
||||
img->data = framebuffer_get_buffer();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user