summaryrefslogtreecommitdiff
path: root/indra/llrender
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llrender')
-rw-r--r--indra/llrender/llgl.cpp10
-rw-r--r--indra/llrender/llglslshader.cpp10
-rw-r--r--indra/llrender/llshadermgr.cpp4
3 files changed, 14 insertions, 10 deletions
diff --git a/indra/llrender/llgl.cpp b/indra/llrender/llgl.cpp
index 35b6951779..c0f0cec80b 100644
--- a/indra/llrender/llgl.cpp
+++ b/indra/llrender/llgl.cpp
@@ -1890,7 +1890,7 @@ void LLGLState::checkClientArrays(const std::string& msg, U32 data_mask)
GL_TEXTURE_COORD_ARRAY
};
- U32 mask[] =
+ static const U32 mask[] =
{ //copied from llvertexbuffer.h
0x0001, //MAP_VERTEX,
0x0002, //MAP_NORMAL,
@@ -2561,5 +2561,11 @@ void LLGLSyncFence::wait()
#endif
}
-
+#if LL_WINDOWS
+// Expose desired use of high-performance graphics processor to Optimus driver
+extern "C"
+{
+ _declspec(dllexport) DWORD NvOptimusEnablement = 0x00000001;
+}
+#endif
diff --git a/indra/llrender/llglslshader.cpp b/indra/llrender/llglslshader.cpp
index 4702042ab9..141ed51260 100644
--- a/indra/llrender/llglslshader.cpp
+++ b/indra/llrender/llglslshader.cpp
@@ -561,7 +561,7 @@ BOOL LLGLSLShader::mapAttributes(const std::vector<LLStaticHashedString> * attri
mAttribute[i] = index;
#endif
mAttributeMask |= 1 << i;
- LL_DEBUGS("ShaderLoading") << "Attribute " << name << " assigned to channel " << index << LL_ENDL;
+ LL_DEBUGS("ShaderUniform") << "Attribute " << name << " assigned to channel " << index << LL_ENDL;
}
}
if (attributes != NULL)
@@ -573,7 +573,7 @@ BOOL LLGLSLShader::mapAttributes(const std::vector<LLStaticHashedString> * attri
if (index != -1)
{
mAttribute[LLShaderMgr::instance()->mReservedAttribs.size() + i] = index;
- LL_DEBUGS("ShaderLoading") << "Attribute " << name << " assigned to channel " << index << LL_ENDL;
+ LL_DEBUGS("ShaderUniform") << "Attribute " << name << " assigned to channel " << index << LL_ENDL;
}
}
}
@@ -658,7 +658,7 @@ void LLGLSLShader::mapUniform(GLint index, const vector<LLStaticHashedString> *
mUniformNameMap[location] = name;
mUniformMap[hashedName] = location;
- LL_DEBUGS("ShaderLoading") << "Uniform " << name << " is at location " << location << LL_ENDL;
+ LL_DEBUGS("ShaderUniform") << "Uniform " << name << " is at location " << location << LL_ENDL;
//find the index of this uniform
for (S32 i = 0; i < (S32) LLShaderMgr::instance()->mReservedUniforms.size(); i++)
@@ -706,7 +706,7 @@ GLint LLGLSLShader::mapUniformTextureChannel(GLint location, GLenum type)
type == GL_SAMPLER_2D_MULTISAMPLE)
{ //this here is a texture
glUniform1iARB(location, mActiveTextureChannels);
- LL_DEBUGS("ShaderLoading") << "Assigned to texture channel " << mActiveTextureChannels << LL_ENDL;
+ LL_DEBUGS("ShaderUniform") << "Assigned to texture channel " << mActiveTextureChannels << LL_ENDL;
return mActiveTextureChannels++;
}
return -1;
@@ -849,7 +849,7 @@ BOOL LLGLSLShader::mapUniforms(const vector<LLStaticHashedString> * uniforms)
unbind();
- LL_DEBUGS("ShaderLoading") << "Total Uniform Size: " << mTotalUniformSize << LL_ENDL;
+ LL_DEBUGS("ShaderUniform") << "Total Uniform Size: " << mTotalUniformSize << LL_ENDL;
return res;
}
diff --git a/indra/llrender/llshadermgr.cpp b/indra/llrender/llshadermgr.cpp
index e721ad93fa..643c368870 100644
--- a/indra/llrender/llshadermgr.cpp
+++ b/indra/llrender/llshadermgr.cpp
@@ -537,8 +537,6 @@ GLhandleARB LLShaderMgr::loadShaderFile(const std::string& filename, S32 & shade
}
}
- LL_DEBUGS("ShaderLoading") << "Loading shader file: " << filename << " class " << shader_level << LL_ENDL;
-
if (filename.empty())
{
return 0;
@@ -558,7 +556,7 @@ GLhandleARB LLShaderMgr::loadShaderFile(const std::string& filename, S32 & shade
fname << getShaderDirPrefix();
fname << gpu_class << "/" << filename;
- LL_DEBUGS("ShaderLoading") << "Looking in " << fname.str() << LL_ENDL;
+
file = LLFile::fopen(fname.str(), "r"); /* Flawfinder: ignore */
if (file)
{