forked from teamnwah/openmw-tes3coop
Reduce error spam
This commit is contained in:
parent
7b4add2ae4
commit
244cc5b861
1 changed files with 4 additions and 0 deletions
|
@ -131,7 +131,11 @@ namespace Shader
|
||||||
{
|
{
|
||||||
std::string shaderSource = templateIt->second;
|
std::string shaderSource = templateIt->second;
|
||||||
if (!parseDefines(shaderSource, defines))
|
if (!parseDefines(shaderSource, defines))
|
||||||
|
{
|
||||||
|
// Add to the cache anyway to avoid logging the same error over and over.
|
||||||
|
mShaders.insert(std::make_pair(std::make_pair(shaderTemplate, defines), nullptr));
|
||||||
return NULL;
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
osg::ref_ptr<osg::Shader> shader (new osg::Shader(shaderType));
|
osg::ref_ptr<osg::Shader> shader (new osg::Shader(shaderType));
|
||||||
shader->setShaderSource(shaderSource);
|
shader->setShaderSource(shaderSource);
|
||||||
|
|
Loading…
Reference in a new issue