From 8ac9750a811e316b704c5f4fa98db1eb260da706 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Wed, 15 Jul 2020 16:32:21 +0200 Subject: [PATCH] Platform: properly initialize EmscriptenApp GLConfiguration. --- doc/changelog.dox | 3 +++ src/Magnum/Platform/EmscriptenApplication.cpp | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/doc/changelog.dox b/doc/changelog.dox index eef409ed1..4e175fe26 100644 --- a/doc/changelog.dox +++ b/doc/changelog.dox @@ -89,6 +89,9 @@ See also: @subsection changelog-latest-bugfixes Bug fixes +- @ref Platform::EmscriptenApplication randomly created antialiased contexts + due to an uninitialized variable in its + @ref Platform::EmscriptenApplication::GLConfiguration "GLConfiguration" - Creating @ref Platform::WindowlessEglApplication again after it was destroyed could fail with an error saying "cannot make the previous context current" on certain system. This was due to EGL not destroying the context diff --git a/src/Magnum/Platform/EmscriptenApplication.cpp b/src/Magnum/Platform/EmscriptenApplication.cpp index 010c4cb92..c0f84a4d6 100644 --- a/src/Magnum/Platform/EmscriptenApplication.cpp +++ b/src/Magnum/Platform/EmscriptenApplication.cpp @@ -692,7 +692,8 @@ void EmscriptenApplication::textInputEvent(TextInputEvent&) {} #ifdef MAGNUM_TARGET_GL EmscriptenApplication::GLConfiguration::GLConfiguration(): - _colorBufferSize{8, 8, 8, 8}, _depthBufferSize{24}, _stencilBufferSize{0} {} + _colorBufferSize{8, 8, 8, 8}, _depthBufferSize{24}, _stencilBufferSize{0}, + _sampleCount{0} {} #endif int EmscriptenApplication::exec() {