-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make it easy to set MADCTL for rotation #26
Comments
Why are you using MADCTL for rotation? CircuitPython handles the rotation itself and then draws in the normal orientation. I believe this is to help with screen tearing according to @tannewt. |
Using MADCTL for rotation usually performs better, especially for OnDiskBitmaps where displayio rotation gives pathologically poor behavior. |
I never did the full tearing work I intended to do. So I wouldn't block this on that goal. Tearing happens with CP now and there isn't much we can do. |
Fair enough. Should be easy enough to refactor this driver to allow easier modification of MADCTL. |
The upper 3 bits of the MADCTL register can set a rotation that occurs within the LCD controller. Particularly when working with OnDiskBitmaps, displayio can be much more efficient when the displayio rotation is 0. By exposing the ability to modify the initialization string's MADCTL value, the more efficient in-controller rotation can be used instead.
Locally, I am using this code, but it's a bit gross:
Section 9.3 and the figure on page 209 of https://cdn-shop.adafruit.com/datasheets/ILI9341.pdf show how these 3 bits of MADCTL are interpreted.
The text was updated successfully, but these errors were encountered: