Fix for travis-ci

This commit is contained in:
vlj 2014-08-04 02:08:03 +02:00
parent 072c118f95
commit fb9dc7af74
2 changed files with 8 additions and 2 deletions

View File

@ -598,6 +598,11 @@ void glUniform1fWrapper(GLuint a, float b)
glUniform1f(a, b); glUniform1f(a, b);
} }
bool needsUBO()
{
return irr_driver->needUBOWorkaround();
}
namespace MeshShader namespace MeshShader
{ {
// Solid Normal and depth pass shaders // Solid Normal and depth pass shaders

View File

@ -53,6 +53,7 @@ void glUniformMatrix4fvWraper(GLuint, size_t, unsigned, const float *mat);
void glUniform3fWraper(GLuint, float, float, float); void glUniform3fWraper(GLuint, float, float, float);
void glUniform2fWraper(GLuint a, float b, float c); void glUniform2fWraper(GLuint a, float b, float c);
void glUniform1fWrapper(GLuint, float); void glUniform1fWrapper(GLuint, float);
bool needsUBO();
struct UniformHelper struct UniformHelper
{ {
@ -128,7 +129,7 @@ public:
void setUniforms(const Args & ... args) const void setUniforms(const Args & ... args) const
{ {
if (irr_driver->needUBOWorkaround()) if (needsUBO())
bypassUBO(Program); bypassUBO(Program);
UniformHelper::setUniformsHelper(uniforms, args...); UniformHelper::setUniformsHelper(uniforms, args...);
} }
@ -158,7 +159,7 @@ public:
void setUniforms(const Args & ... args) const void setUniforms(const Args & ... args) const
{ {
if (irr_driver->needUBOWorkaround()) if (needsUBO())
bypassUBO(Program); bypassUBO(Program);
UniformHelper::setUniformsHelper(uniforms, args...); UniformHelper::setUniformsHelper(uniforms, args...);
} }