mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-02-25 21:41:04 +00:00
remove log spam on failures
This commit is contained in:
parent
a987b01717
commit
ee6e60005b
@ -103,7 +103,15 @@ namespace MWRender
|
|||||||
if (filtered.empty() || !bufferData.postprocessing)
|
if (filtered.empty() || !bufferData.postprocessing)
|
||||||
{
|
{
|
||||||
if (bufferData.postprocessing)
|
if (bufferData.postprocessing)
|
||||||
Log(Debug::Error) << "Critical error, postprocess shaders failed to compile. Using default shader.";
|
{
|
||||||
|
if (!mLoggedLastError)
|
||||||
|
{
|
||||||
|
Log(Debug::Error) << "Critical error, postprocess shaders failed to compile. Using default shader.";
|
||||||
|
mLoggedLastError = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
mLoggedLastError = false;
|
||||||
|
|
||||||
mFallbackStateSet->setTextureAttributeAndModes(0, bufferData.sceneTex);
|
mFallbackStateSet->setTextureAttributeAndModes(0, bufferData.sceneTex);
|
||||||
|
|
||||||
|
@ -82,6 +82,8 @@ namespace MWRender
|
|||||||
|
|
||||||
mutable std::optional<fx::DispatchArray> mQueuedDispatchArray;
|
mutable std::optional<fx::DispatchArray> mQueuedDispatchArray;
|
||||||
mutable size_t mQueuedDispatchFrameId;
|
mutable size_t mQueuedDispatchFrameId;
|
||||||
|
|
||||||
|
mutable bool mLoggedLastError = false;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -378,7 +378,7 @@ namespace MWRender
|
|||||||
const auto lastWriteTime = std::filesystem::last_write_time(mTechniqueFileMap[technique->getName()]);
|
const auto lastWriteTime = std::filesystem::last_write_time(mTechniqueFileMap[technique->getName()]);
|
||||||
const bool isDirty = technique->setLastModificationTime(lastWriteTime);
|
const bool isDirty = technique->setLastModificationTime(lastWriteTime);
|
||||||
|
|
||||||
if (technique->isValid() && !isDirty)
|
if (!isDirty)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (technique->compile())
|
if (technique->compile())
|
||||||
@ -671,6 +671,9 @@ namespace MWRender
|
|||||||
|
|
||||||
bool PostProcessor::disableTechnique(std::shared_ptr<fx::Technique> technique, bool dirty)
|
bool PostProcessor::disableTechnique(std::shared_ptr<fx::Technique> technique, bool dirty)
|
||||||
{
|
{
|
||||||
|
if (Misc::StringUtils::ciEqual(technique->getName(), "main"))
|
||||||
|
return false;
|
||||||
|
|
||||||
auto it = std::find(mTechniques.begin(), mTechniques.end(), technique);
|
auto it = std::find(mTechniques.begin(), mTechniques.end(), technique);
|
||||||
if (it == std::end(mTechniques))
|
if (it == std::end(mTechniques))
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user