mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-04-09 21:44:54 +00:00
fixed include, cleaned comments and indentation
This commit is contained in:
parent
31d412527d
commit
f78fa989ee
@ -5,7 +5,8 @@
|
||||
#include <sstream>
|
||||
#include <regex>
|
||||
#include <filesystem>
|
||||
#include <unordered_set>
|
||||
#include <set>
|
||||
#include <unordered_map>
|
||||
#include <osg/Program>
|
||||
|
||||
#include <components/debug/debuglog.hpp>
|
||||
@ -406,7 +407,6 @@ namespace Shader
|
||||
std::filesystem::path pathShaderToTest = (shader.first);
|
||||
|
||||
std::filesystem::file_time_type write_time = std::filesystem::last_write_time(pathShaderToTest);
|
||||
//Log(Debug::Info) << std::format("{} write time is {} compared to {} ", shader.first, write_time, mLastAutoRecompileTime);
|
||||
if (write_time.time_since_epoch() > mLastAutoRecompileTime.time_since_epoch())
|
||||
{
|
||||
for (const ShaderManager:: MapKey& descriptor : shader.second)
|
||||
@ -416,7 +416,6 @@ namespace Shader
|
||||
|
||||
ShaderManager::TemplateMap::iterator templateIt = Manager.mShaderTemplates.find(templateName); //Can't be Null, if we're here it means the template was added
|
||||
std::set<std::filesystem::path> insertedPaths;
|
||||
{
|
||||
std::filesystem::path path = (std::filesystem::path(Manager.mPath) / templateName);
|
||||
std::ifstream stream;
|
||||
stream.open(path);
|
||||
@ -437,8 +436,7 @@ namespace Shader
|
||||
}
|
||||
templateIt->second = source;
|
||||
|
||||
//if (shaderIt == Manager.mShaders.end())
|
||||
{
|
||||
|
||||
std::string shaderSource = templateIt->second;
|
||||
std::vector<std::string> linkedShaderNames;
|
||||
if (!Manager.createSourceFromTemplate(shaderSource, linkedShaderNames, templateName, descriptor.second))
|
||||
@ -446,8 +444,7 @@ namespace Shader
|
||||
break;
|
||||
}
|
||||
shaderIt->second->setShaderSource(shaderSource);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user