PXP screen rotation issue based on i.MXRT1052 I'm using rt1052PXP to rotate a landscape view to a portrait view, but the overall display shifts downwards when I refresh the page. Why is this happening? static void DEMO_FlushDisplay(lv_disp_drv_t *disp_drv, const lv_area_t *area, lv_color_t *color_p) { lv_area_t dest_area = { .x1 = 0, .x2 = 480 - 1, .y1 = 0, .y2 = 800 - 1, }; lv_gpu_nxp_pxp_blit(((lv_color_t *)s_inactiveFrameBuffer), area, 800, color_p, area,480, LV_OPA_COVER, LV_DISP_ROT_270); DCACHE_CleanInvalidateByRange((uint32_t)color_p, DEMO_FB_SIZE); ELCDIF_SetNextBufferAddr(LCDIF, (uint32_t)s_inactiveFrameBuffer); s_framePending = true;if (xSemaphoreTake(s_frameSema, portMAX_DELAY) == pdTRUE) { /* IMPORTANT!!! * Inform the graphics library that you are ready with the flushing*/ lv_disp_flush_ready(disp_drv); } else { PRINTF("Display flush failed\r\n"); assert(0); } } i.MXRT 105x 回复: 基于i.MXRT1052的pxp屏幕旋转问题 I've noticed an offset issue when drawing with PXP. Is it because the default initialization `#define LV_USE_GPU_NXP_PXP_AUTO_INIT 1` generated by guiguider can't be used directly? void lv_disp_drv_init(lv_disp_drv_t * driver) { lv_memset_00(driver, sizeof(lv_disp_drv_t)); driver->hor_res = 320; driver->ver_res = 240; driver->physical_hor_res = -1; driver->physical_ver_res = -1; driver->offset_x = 0; driver->offset_y = 0; driver->antialiasing = LV_COLOR_DEPTH > 8 ? 1 : 0; driver->screen_transp = 0; driver->dpi = LV_DPI_DEF; driver->color_chroma_key = LV_COLOR_CHROMA_KEY; #if LV_USE_GPU_NXP_PXP // driver->draw_ctx_init = lv_draw_pxp_ctx_init; // driver->draw_ctx_deinit = lv_draw_pxp_ctx_deinit; // driver->draw_ctx_size = sizeof(lv_draw_pxp_ctx_t); driver->draw_ctx_init = lv_draw_sw_init_ctx; driver->draw_ctx_deinit = lv_draw_sw_init_ctx; driver->draw_ctx_size = sizeof(lv_draw_sw_ctx_t); #else driver->draw_ctx_init = lv_draw_sw_init_ctx; driver->draw_ctx_deinit = lv_draw_sw_init_ctx; driver->draw_ctx_size = sizeof(lv_draw_sw_ctx_t); #endif } 回复: 基于i.MXRT1052的pxp屏幕旋转问题 Hi @dsd,
The LV_USE_GPU_NXP_PXP_AUTO_INIT allows LVGL to leverage the user of PXP for internal widget rendering, which could definitely cause issues when the application also uses this PXP in parallel for whole screen rotation. However, it is likely not the source of the issue.
From the initial code, it seems like you are not using dest_area, or rather you are using area as both source and destination for the PXP blit, which means that only the partial dirty region might be getting placed on different absolute positions rather than the intended.
記事全体を表示