contour
contour copied to clipboard
Software Rendering
Add an alternative to the OpenGLRenderer for Software based rendering
Should be usable by #161.
checklist
- [x] RenderTarget interface
- [x] OpenGLRenderTarget to inherit from interface
- [x] Extract all but OpenGL code away from QOpenGLWidget specialized class (TerminalWidget named currently)
- [x] config option for choosing initial render target
- [ ] SoftwareRenderTarget
- [ ] add config action switching render target by input mapping (shortcuts) at runtime
Should ideally support RGBA (for Software based rendering alternative to OpenGL) and RGB for simple unit testing of the screen rendering (text, complex unicode, images, emoji) .
See https://github.com/microsoft/terminal/pull/1263 for DirectWrite.
https://blend2d.com ?
Note to myself: Qt::AA_UseSoftwareOpenGL should do it, too, and can be mapped to a config setting.
- Is this runtime-switchable? (don't think so)
- Performance implications? Test how rendering performance changes (needs performance metrics first) :D
Note to myself:
- https://doc.qt.io/qt-5/qpainter.html
- https://doc.qt.io/qt-5/qpixmap.html
A QPainter based (software) renderer should be actually not harder than the OpenGL render target.
We have more and more users (to it seems) that are running on OpenGL 2.0 / 2.1 devices.