diff --git a/src/Shaders/DistanceFieldVectorShader.cpp b/src/Shaders/DistanceFieldVectorShader.cpp index 5d39f356c..e3ec1c106 100644 --- a/src/Shaders/DistanceFieldVectorShader.cpp +++ b/src/Shaders/DistanceFieldVectorShader.cpp @@ -59,10 +59,11 @@ template DistanceFieldVectorShader::Distance #ifndef MAGNUM_TARGET_GLES if(!Context::current()->isExtensionSupported() || - Context::current()->version() == Version::GL210) { + Context::current()->version() == Version::GL210) #else - if(!Context::current()->isVersionSupported(Version::GLES300)) { + if(!Context::current()->isVersionSupported(Version::GLES300)) #endif + { AbstractShaderProgram::bindAttributeLocation(AbstractVectorShader::Position::Location, "position"); AbstractShaderProgram::bindAttributeLocation(AbstractVectorShader::TextureCoordinates::Location, "textureCoordinates"); } @@ -70,10 +71,9 @@ template DistanceFieldVectorShader::Distance AbstractShaderProgram::link(); #ifndef MAGNUM_TARGET_GLES - if(!Context::current()->isExtensionSupported()) { - #else - { + if(!Context::current()->isExtensionSupported()) #endif + { transformationProjectionMatrixUniform = AbstractShaderProgram::uniformLocation("transformationProjectionMatrix"); colorUniform = AbstractShaderProgram::uniformLocation("color"); outlineColorUniform = AbstractShaderProgram::uniformLocation("outlineColor"); diff --git a/src/Shaders/FlatShader.cpp b/src/Shaders/FlatShader.cpp index 7ee89d254..afbdb8731 100644 --- a/src/Shaders/FlatShader.cpp +++ b/src/Shaders/FlatShader.cpp @@ -58,20 +58,20 @@ template FlatShader::FlatShader(): transform #ifndef MAGNUM_TARGET_GLES if(!Context::current()->isExtensionSupported() || - Context::current()->version() == Version::GL210) { + Context::current()->version() == Version::GL210) #else - if(!Context::current()->isVersionSupported(Version::GLES300)) { + if(!Context::current()->isVersionSupported(Version::GLES300)) #endif + { bindAttributeLocation(Position::Location, "position"); } link(); #ifndef MAGNUM_TARGET_GLES - if(!Context::current()->isExtensionSupported()) { - #else - { + if(!Context::current()->isExtensionSupported()) #endif + { transformationProjectionMatrixUniform = uniformLocation("transformationProjectionMatrix"); colorUniform = uniformLocation("color"); } diff --git a/src/Shaders/PhongShader.cpp b/src/Shaders/PhongShader.cpp index cbba095c0..a953c3d8a 100644 --- a/src/Shaders/PhongShader.cpp +++ b/src/Shaders/PhongShader.cpp @@ -52,10 +52,11 @@ PhongShader::PhongShader(): transformationMatrixUniform(0), projectionMatrixUnif #ifndef MAGNUM_TARGET_GLES if(!Context::current()->isExtensionSupported() || - Context::current()->version() == Version::GL210) { + Context::current()->version() == Version::GL210) #else - if(!Context::current()->isVersionSupported(Version::GLES300)) { + if(!Context::current()->isVersionSupported(Version::GLES300)) #endif + { bindAttributeLocation(Position::Location, "position"); bindAttributeLocation(Normal::Location, "normal"); } @@ -63,10 +64,9 @@ PhongShader::PhongShader(): transformationMatrixUniform(0), projectionMatrixUnif link(); #ifndef MAGNUM_TARGET_GLES - if(!Context::current()->isExtensionSupported()) { - #else - { + if(!Context::current()->isExtensionSupported()) #endif + { transformationMatrixUniform = uniformLocation("transformationMatrix"); projectionMatrixUniform = uniformLocation("projectionMatrix"); normalMatrixUniform = uniformLocation("normalMatrix"); diff --git a/src/Shaders/VectorShader.cpp b/src/Shaders/VectorShader.cpp index af1c7ba2f..11e48d1dc 100644 --- a/src/Shaders/VectorShader.cpp +++ b/src/Shaders/VectorShader.cpp @@ -59,10 +59,11 @@ template VectorShader::VectorShader(): trans #ifndef MAGNUM_TARGET_GLES if(!Context::current()->isExtensionSupported() || - Context::current()->version() == Version::GL210) { + Context::current()->version() == Version::GL210) #else - if(!Context::current()->isVersionSupported(Version::GLES300)) { + if(!Context::current()->isVersionSupported(Version::GLES300)) #endif + { AbstractShaderProgram::bindAttributeLocation(AbstractVectorShader::Position::Location, "position"); AbstractShaderProgram::bindAttributeLocation(AbstractVectorShader::TextureCoordinates::Location, "textureCoordinates"); } @@ -70,10 +71,9 @@ template VectorShader::VectorShader(): trans AbstractShaderProgram::link(); #ifndef MAGNUM_TARGET_GLES - if(!Context::current()->isExtensionSupported()) { - #else - { + if(!Context::current()->isExtensionSupported()) #endif + { transformationProjectionMatrixUniform = AbstractShaderProgram::uniformLocation("transformationProjectionMatrix"); colorUniform = AbstractShaderProgram::uniformLocation("color"); } diff --git a/src/Shaders/VertexColorShader.cpp b/src/Shaders/VertexColorShader.cpp index 8c6b4699e..82e25231f 100644 --- a/src/Shaders/VertexColorShader.cpp +++ b/src/Shaders/VertexColorShader.cpp @@ -58,10 +58,11 @@ template VertexColorShader::VertexColorShade #ifndef MAGNUM_TARGET_GLES if(!Context::current()->isExtensionSupported() || - Context::current()->version() == Version::GL210) { + Context::current()->version() == Version::GL210) #else - if(!Context::current()->isVersionSupported(Version::GLES300)) { + if(!Context::current()->isVersionSupported(Version::GLES300)) #endif + { bindAttributeLocation(Position::Location, "position"); bindAttributeLocation(Color::Location, "color"); } @@ -69,10 +70,9 @@ template VertexColorShader::VertexColorShade link(); #ifndef MAGNUM_TARGET_GLES - if(!Context::current()->isExtensionSupported()) { - #else - { + if(!Context::current()->isExtensionSupported()) #endif + { transformationProjectionMatrixUniform = uniformLocation("transformationProjectionMatrix"); } }