From d0035493282c033dc24c24ebbed42c6c973793ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Fri, 3 Jan 2014 00:32:26 +0100 Subject: [PATCH] Platform: fixed compilation of magnum-info on ES3. --- src/Platform/magnum-info.cpp | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/src/Platform/magnum-info.cpp b/src/Platform/magnum-info.cpp index 1d9f8e386..adac9c2fb 100644 --- a/src/Platform/magnum-info.cpp +++ b/src/Platform/magnum-info.cpp @@ -323,28 +323,44 @@ MagnumInfo::MagnumInfo(const Arguments& arguments): Platform::WindowlessApplicat } #endif + /** @todo Somehow sort the following into previous list for ES3 */ + #ifndef MAGNUM_TARGET_GLES2 - if(c->isExtensionSupported()) { + #ifndef MAGNUM_TARGET_GLES + if(c->isExtensionSupported()) + #endif + { + #ifndef MAGNUM_TARGET_GLES _h(ARB::uniform_buffer_object) + #endif _l(Shader::maxUniformBlocks(Shader::Type::Vertex)) + #ifndef MAGNUM_TARGET_GLES _l(Shader::maxUniformBlocks(Shader::Type::TessellationControl)) _l(Shader::maxUniformBlocks(Shader::Type::TessellationEvaluation)) _l(Shader::maxUniformBlocks(Shader::Type::Geometry)) _l(Shader::maxUniformBlocks(Shader::Type::Compute)) + #endif _l(Shader::maxUniformBlocks(Shader::Type::Fragment)) _l(Shader::maxCombinedUniformBlocks()) _l(Shader::maxCombinedUniformComponents(Shader::Type::Vertex)) + #ifndef MAGNUM_TARGET_GLES _l(Shader::maxCombinedUniformComponents(Shader::Type::TessellationControl)) _l(Shader::maxCombinedUniformComponents(Shader::Type::TessellationEvaluation)) _l(Shader::maxCombinedUniformComponents(Shader::Type::Geometry)) _l(Shader::maxCombinedUniformComponents(Shader::Type::Compute)) + #endif _l(Shader::maxCombinedUniformComponents(Shader::Type::Fragment)) _l(AbstractShaderProgram::maxUniformBlockSize()) } - if(c->isExtensionSupported()) { + #ifndef MAGNUM_TARGET_GLES + if(c->isExtensionSupported()) + #endif + { + #ifndef MAGNUM_TARGET_GLES _h(EXT::gpu_shader4) + #endif _l(Buffer::maxUniformBindings()) _l(AbstractShaderProgram::minTexelOffset())