QT5 OpenGL multisampling not functional
Original Reporter info from Mantis: crlab @neurolabusc1
-
Reporter name: Chris Rorden
Original Reporter info from Mantis: crlab @neurolabusc1
- Reporter name: Chris Rorden
Description:
Multisampling works fine when OpenGL projects are compiled to GTK2, but no longer work for QT5. I helped test and develop the GLQTContext, so at one stage multi-sampling worked. However, now all images are jagged. This behavior can be seen with the sample projects that come with Lazarus (/components/opengl/examples), but the fast animation (testopengl1) and the 90-degree edges (imggui). It is clearly evidence in the 'Cube' project
https://github.com/neurolabusc/OpenGLCoreTutorials
Compare running the 'Cube' project with the 'GTK2' widgetset versus the 'QT5' widgetset.
Is it possible that the sampling needs to be set for the parent window? Looking at the command line when "VerboseMultiSampling" is defined in 'GLQTContext.pas', it is clear that the OpenGL context supports multisampling, but I can not see a call for the QSurfaceFormat_setSamples from qsurfaceformat_c:
https://stackoverflow.com/questions/14474259/how-do-i-enable-multisampling-antialiasing-in-opengl-with-qt5
Mantis conversion info:
- Mantis ID: 36875
- OS: Ubuntu
- OS Build: 20.04
- Build: 62843
- Platform: Ryzen 3900X, NVidida 1080 Ti
- Version: 2.1 (SVN)
- Fixed in revision: 62895 (#7a087965)