mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Implement support for FSAA in combination with post-processing (#15392)
- Actually it's MSAA I think, or perhaps the terms are equivalent - I've made it fit into the existing Irrlicht architecture, but that has resulted in code duplication compared to my original "hacky" approach - OpenGL 3.2+ and OpenGL ES 3.1+ are supported - EDT_OPENGL3 is not required, EDT_OPENGL works too - Helpful tutorial: https://learnopengl.com/Advanced-OpenGL/Anti-Aliasing, section "Off-screen MSAA" - This may be rough around the edges, but in general it works
This commit is contained in:
parent
a8ea165042
commit
9b6a399011
23 changed files with 290 additions and 42 deletions
|
@ -179,7 +179,10 @@ RenderingEngine::RenderingEngine(MyEventReceiver *receiver)
|
|||
|
||||
// bpp, fsaa, vsync
|
||||
bool vsync = g_settings->getBool("vsync");
|
||||
bool enable_fsaa = g_settings->get("antialiasing") == "fsaa";
|
||||
// Don't enable MSAA in OpenGL context creation if post-processing is enabled,
|
||||
// the post-processing pipeline handles it.
|
||||
bool enable_fsaa = g_settings->get("antialiasing") == "fsaa" &&
|
||||
!g_settings->getBool("enable_post_processing");
|
||||
u16 fsaa = enable_fsaa ? MYMAX(2, g_settings->getU16("fsaa")) : 0;
|
||||
|
||||
// Determine driver
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue