diff options
| author | 2020-12-07 00:41:47 -0500 | |
|---|---|---|
| committer | 2020-12-07 00:41:50 -0500 | |
| commit | 4c5f5c9bf301d3626df104dbed6fed6f115cedc8 (patch) | |
| tree | 968245c43735e546fff2a8c7dcecfe653dee33fd /src/video_core/surface.cpp | |
| parent | Merge pull request #5147 from comex/xx-purevirt (diff) | |
| download | yuzu-4c5f5c9bf301d3626df104dbed6fed6f115cedc8.tar.gz yuzu-4c5f5c9bf301d3626df104dbed6fed6f115cedc8.tar.xz yuzu-4c5f5c9bf301d3626df104dbed6fed6f115cedc8.zip | |
video_core: Remove unnecessary enum class casting in logging messages
fmt now automatically prints the numeric value of an enum class member
by default, so we don't need to use casts any more.
Reduces the line noise a bit.
Diffstat (limited to 'src/video_core/surface.cpp')
| -rw-r--r-- | src/video_core/surface.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/video_core/surface.cpp b/src/video_core/surface.cpp index 1688267bb..937e29d1e 100644 --- a/src/video_core/surface.cpp +++ b/src/video_core/surface.cpp | |||
| @@ -28,7 +28,7 @@ SurfaceTarget SurfaceTargetFromTextureType(Tegra::Texture::TextureType texture_t | |||
| 28 | case Tegra::Texture::TextureType::Texture2DArray: | 28 | case Tegra::Texture::TextureType::Texture2DArray: |
| 29 | return SurfaceTarget::Texture2DArray; | 29 | return SurfaceTarget::Texture2DArray; |
| 30 | default: | 30 | default: |
| 31 | LOG_CRITICAL(HW_GPU, "Unimplemented texture_type={}", static_cast<u32>(texture_type)); | 31 | LOG_CRITICAL(HW_GPU, "Unimplemented texture_type={}", texture_type); |
| 32 | UNREACHABLE(); | 32 | UNREACHABLE(); |
| 33 | return SurfaceTarget::Texture2D; | 33 | return SurfaceTarget::Texture2D; |
| 34 | } | 34 | } |
| @@ -47,7 +47,7 @@ bool SurfaceTargetIsLayered(SurfaceTarget target) { | |||
| 47 | case SurfaceTarget::TextureCubeArray: | 47 | case SurfaceTarget::TextureCubeArray: |
| 48 | return true; | 48 | return true; |
| 49 | default: | 49 | default: |
| 50 | LOG_CRITICAL(HW_GPU, "Unimplemented surface_target={}", static_cast<u32>(target)); | 50 | LOG_CRITICAL(HW_GPU, "Unimplemented surface_target={}", target); |
| 51 | UNREACHABLE(); | 51 | UNREACHABLE(); |
| 52 | return false; | 52 | return false; |
| 53 | } | 53 | } |
| @@ -66,7 +66,7 @@ bool SurfaceTargetIsArray(SurfaceTarget target) { | |||
| 66 | case SurfaceTarget::TextureCubeArray: | 66 | case SurfaceTarget::TextureCubeArray: |
| 67 | return true; | 67 | return true; |
| 68 | default: | 68 | default: |
| 69 | LOG_CRITICAL(HW_GPU, "Unimplemented surface_target={}", static_cast<u32>(target)); | 69 | LOG_CRITICAL(HW_GPU, "Unimplemented surface_target={}", target); |
| 70 | UNREACHABLE(); | 70 | UNREACHABLE(); |
| 71 | return false; | 71 | return false; |
| 72 | } | 72 | } |
| @@ -85,7 +85,7 @@ PixelFormat PixelFormatFromDepthFormat(Tegra::DepthFormat format) { | |||
| 85 | case Tegra::DepthFormat::D32_FLOAT_S8X24_UINT: | 85 | case Tegra::DepthFormat::D32_FLOAT_S8X24_UINT: |
| 86 | return PixelFormat::D32_FLOAT_S8_UINT; | 86 | return PixelFormat::D32_FLOAT_S8_UINT; |
| 87 | default: | 87 | default: |
| 88 | UNIMPLEMENTED_MSG("Unimplemented format={}", static_cast<u32>(format)); | 88 | UNIMPLEMENTED_MSG("Unimplemented format={}", format); |
| 89 | return PixelFormat::S8_UINT_D24_UNORM; | 89 | return PixelFormat::S8_UINT_D24_UNORM; |
| 90 | } | 90 | } |
| 91 | } | 91 | } |
| @@ -183,7 +183,7 @@ PixelFormat PixelFormatFromRenderTargetFormat(Tegra::RenderTargetFormat format) | |||
| 183 | case Tegra::RenderTargetFormat::R8_UINT: | 183 | case Tegra::RenderTargetFormat::R8_UINT: |
| 184 | return PixelFormat::R8_UINT; | 184 | return PixelFormat::R8_UINT; |
| 185 | default: | 185 | default: |
| 186 | UNIMPLEMENTED_MSG("Unimplemented format={}", static_cast<int>(format)); | 186 | UNIMPLEMENTED_MSG("Unimplemented format={}", format); |
| 187 | return PixelFormat::A8B8G8R8_UNORM; | 187 | return PixelFormat::A8B8G8R8_UNORM; |
| 188 | } | 188 | } |
| 189 | } | 189 | } |
| @@ -197,7 +197,7 @@ PixelFormat PixelFormatFromGPUPixelFormat(Tegra::FramebufferConfig::PixelFormat | |||
| 197 | case Tegra::FramebufferConfig::PixelFormat::B8G8R8A8_UNORM: | 197 | case Tegra::FramebufferConfig::PixelFormat::B8G8R8A8_UNORM: |
| 198 | return PixelFormat::B8G8R8A8_UNORM; | 198 | return PixelFormat::B8G8R8A8_UNORM; |
| 199 | default: | 199 | default: |
| 200 | UNIMPLEMENTED_MSG("Unimplemented format={}", static_cast<u32>(format)); | 200 | UNIMPLEMENTED_MSG("Unimplemented format={}", format); |
| 201 | return PixelFormat::A8B8G8R8_UNORM; | 201 | return PixelFormat::A8B8G8R8_UNORM; |
| 202 | } | 202 | } |
| 203 | } | 203 | } |