From ca3a6e5c84c4d730bd8d0574820d6d5f90581541 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Branimir=20Karad=C5=BEi=C4=87?= Date: Fri, 20 Feb 2015 15:35:20 -0800 Subject: [PATCH] Fixed Emscripten. --- src/renderer_gl.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/renderer_gl.cpp b/src/renderer_gl.cpp index 84445e3b0..1ad0d691a 100644 --- a/src/renderer_gl.cpp +++ b/src/renderer_gl.cpp @@ -1165,7 +1165,8 @@ namespace bgfx } } - if (!isTextureFormatValid(TextureFormat::R8) ) + if (BX_ENABLED(BX_PLATFORM_EMSCRIPTEN) + || !isTextureFormatValid(TextureFormat::R8) ) { // GL core has to use GL_R8 Issue#208, GLES2 has to use GL_LUMINANCE issue#226 s_textureFormat[TextureFormat::R8].m_internalFmt = GL_LUMINANCE;