Rotation on non-square screen

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • Rotation on non-square screen

    I'm looking for suggestions / best practices for handing my scenario, where I have a portrait screen (LS013B7DH05 144x168, STM32 chip, GUIDRV_SH_MEM) but I have it physically oriented in landscape (i.e. I want it to behave as 168x144).

    The driver doesn't support this rotation directly as a driver configuration, so I've been looking at GUI_SetOrientation. If I use GUI_SetOrientation, part of my content is cut off as I attempt to write to the full width of the screen (i.e. it only writes 144 px across). Is this intentional? Is it meant only for square physical displays or have I perhaps configured it incorrectly?

    Also, as noted in the manual, I do notice a significant slowdown in drawing performance if I do use GUI_SetOrientation. Are there some "best practices" for dealing with this sort of configuration? I really don't wish to write the software assuming the physical orientation of the display (code becomes unintuitive to read/understand, drawing text becomes a pain, etc).