Non-FBO MSAA for OpenGL

Reporter: RobertBColton  |  Status: closed  |  Last Modified: May 12, 2019, 02:42:16 PM

Trying to bring the OpenGL systems in line with the Direct3D systems and do the MSAA on the default framebuffer instead of through an auxiliary one. This would obviously allow people whose drivers support MSAA but not FBOs to have MSAA. This is almost a failed experiment for several reasons. Right now, I have made it work flawlessly on OpenGL1, but there are caveats. Windows apparently only allows a window to have a single pixel format, so to change the MSAA I have to destroy and recreate the Window with an MSAA pixel format. OpenGL3 does not appear to like this and will draw nothing after the display reset which I think is because the shader objects are not being shared between the old and new context.
codecov[bot]  
>Codecov Report

Merging #1581 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1581   +/-   ##
=======================================
  Coverage   18.86%   18.86%           
=======================================
  Files         165      165           
  Lines       16677    16677           
=======================================
  Hits         3146     3146           
  Misses      13531    13531

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update aa54ade...0afa5f2. Read the comment docs.

RobertBColton  

Closing as stale and not worth it. Nobody is interested in recreating the window for OpenGL. The FBO version has already been fixed for all platforms in #1693 anyway.
RobertBColton  

Worth mentioning that overlay planes may be something to look into in the future.
https://www.opengl.org/archives/resources/faq/technical/contexts.htm

Also, this exact same issue was raised with MonoGame.
MonoGame/MonoGame#6061

What bothers me is that I just wish GameMaker would have made a game setting for the default MSAA selection and depth buffer size. Then also provided MSAA surfaces so the user could do whichever they wanted.

Please sign in to post comments, or you can view this issue on GitHub.