Various fixes and stability improvements

This commit is contained in:
Wojtek Figat
2023-12-06 00:28:03 +01:00
parent 38a0718b70
commit fdfca5156b
3 changed files with 10 additions and 3 deletions

View File

@@ -729,7 +729,12 @@ bool ModelData::Pack2ModelHeader(WriteStream* stream) const
// Amount of meshes
const int32 meshes = lod.Meshes.Count();
if (meshes == 0 || meshes > MODEL_MAX_MESHES)
if (meshes == 0)
{
LOG(Warning, "Empty LOD.");
return true;
}
if (meshes > MODEL_MAX_MESHES)
{
LOG(Warning, "Too many meshes per LOD.");
return true;

View File

@@ -4,10 +4,8 @@
#if USE_EDITOR
#include "Engine/Core/Cache.h"
#include "Engine/Scripting/Script.h"
#include "Engine/Scripting/ScriptingObjectReference.h"
#include "Engine/Serialization/JsonWriters.h"
/// <summary>
/// Actor script component that represents missing script.

View File

@@ -434,6 +434,10 @@ void PostProcessingPass::Render(RenderContext& renderContext, GPUTexture* input,
// Set lens flares output
context->BindSR(3, bloomTmp2->View(0, 1));
}
else
{
context->BindSR(3, (GPUResourceView*)nullptr);
}
////////////////////////////////////////////////////////////////////////////////////
// Final composite