arduino-libraries / Arduino_GigaDisplay

Library for controlling the RGB on the GIGA Display Shield. It contains, also, a set of examples to use the display.
8 stars 3 forks source link

Tearing Effect #15

Closed Jens1985 closed 9 months ago

Jens1985 commented 9 months ago

Hey, I've had the Giga Display for a few days now.

I'm trying to get it to work with the LVGL example. I have created a screen with two buttons. The screen is scrollable. When I scroll the screen, there is a tearing effect.

Alt Text

I would like to eliminate the tearing effect.

I have already enlarged the buffer and added a double buffer. lv_conf.h #define LV_MEM_SIZE (256U * 1024U)

Arduino_H7_Video.cpp

static lv_color_t * buf2;  
buf1 = (lv_color_t*)malloc((width() * height() / 4) * sizeof(lv_color_t));
buf2 = (lv_color_t*)malloc((width() * height() / 4) * sizeof(lv_color_t)); 
lv_disp_draw_buf_init(&draw_buf, buf1, buf2, width() * height() / 4);

I have also activated the DMA2D (aka Chrom Art) GPU. lv_conf.h

#define LV_USE_GPU_STM32_DMA2D 1
#if LV_USE_GPU_STM32_DMA2D
    /*Must be defined to include path of CMSIS header of target processor
    e.g. "stm32f769xx.h" or "stm32f429xx.h"*/
    #define LV_GPU_DMA2D_CMSIS_INCLUDE <stm32h747xx.h>
#endif

What else can i do to eliminate the tearing effect?

karlsoderby commented 9 months ago

Hi there @Jens1985, this library only serves some basic functions (e.g. RGB LED, backlight LED for display), and a number of examples for the Giga Display Shield. But it does not host the drivers for the display itself.

The Arduino_H7_Video.cpp file actually lives inside the ArduinoCore-mbed repository as it is a library included with the board's core.

However, maybe @leonardocavagnis could help answer your questions?

Jens1985 commented 9 months ago

Hey, thanks for the answer. So the issue would actually be better placed in ArduinoCore-mbed? Should I open the issue there again?

leonardocavagnis commented 9 months ago

@Jens1985 Yes, open this issue in ArduinoCore-mbed. Thanks