Cst816s: scale down SDL mouse coordinates according to MONITOR_ZOOM
The lv_drivers provided monitor driver supports a `MONITOR_ZOOM`-factor which scales the window by the set factor. This is 'useful when simulating small screens'. The zoom can be set as cmake configuration setting `-DMONITOR_ZOOM=1`. Probably even more usefull for high-dpi screens where 240 pixels is really tiny.
This commit is contained in:
@@ -99,7 +99,10 @@
|
||||
# define MONITOR_VER_RES 240
|
||||
|
||||
/* Scale window by this factor (useful when simulating small screens) */
|
||||
#ifndef MONITOR_ZOOM
|
||||
# define MONITOR_ZOOM 1
|
||||
#endif
|
||||
static_assert(MONITOR_ZOOM > 0);
|
||||
|
||||
/* Used to test true double buffering with only address changing.
|
||||
* Set LV_draw_buf_SIZE = (LV_HOR_RES * LV_VER_RES) and LV_draw_buf_DOUBLE = 1 and LV_COLOR_DEPTH = 32" */
|
||||
|
Reference in New Issue
Block a user