Add logging PixelFormat as string instead of integer value for better readability

This commit is contained in:
Wojtek Figat
2023-04-13 10:31:40 +02:00
parent bedb056645
commit b0966c9114
9 changed files with 23 additions and 15 deletions

View File

@@ -9,6 +9,7 @@
#include "Engine/Graphics/GPUDevice.h"
#include "Engine/Graphics/RenderTools.h"
#include "Engine/Graphics/Async/Tasks/GPUUploadTextureMipTask.h"
#include "Engine/Scripting/Enums.h"
TextureHeader_Deprecated::TextureHeader_Deprecated()
{
@@ -354,7 +355,7 @@ protected:
// Ensure that texture has been allocated before this task and has proper format
if (!texture->IsAllocated() || texture->Format() != _streamingTexture->GetHeader()->Format)
{
LOG(Error, "Cannot stream texture {0} (streaming format: {1})", texture->ToString(), (int32)_streamingTexture->GetHeader()->Format);
LOG(Error, "Cannot stream texture {0} (streaming format: {1})", texture->ToString(), ScriptingEnum::ToString(_streamingTexture->GetHeader()->Format));
return Result::Failed;
}