diff options
| author | Egor Yusov <egor.yusov@gmail.com> | 2018-03-25 16:27:11 +0000 |
|---|---|---|
| committer | Egor Yusov <egor.yusov@gmail.com> | 2018-03-25 16:27:11 +0000 |
| commit | 35b9c182978d7f585940504a4f05f12c00426d07 (patch) | |
| tree | c110a78a8405cc3c74533c632f731b0125cb23e7 /Graphics/GraphicsEngine | |
| parent | Added vulkan texture type conversions + texture view initialization (diff) | |
| download | DiligentCore-35b9c182978d7f585940504a4f05f12c00426d07.tar.gz DiligentCore-35b9c182978d7f585940504a4f05f12c00426d07.zip | |
Implementing texture views in Vulkan
Diffstat (limited to 'Graphics/GraphicsEngine')
| -rw-r--r-- | Graphics/GraphicsEngine/src/Texture.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Graphics/GraphicsEngine/src/Texture.cpp b/Graphics/GraphicsEngine/src/Texture.cpp index 366f7e93..b1769cf3 100644 --- a/Graphics/GraphicsEngine/src/Texture.cpp +++ b/Graphics/GraphicsEngine/src/Texture.cpp @@ -31,6 +31,11 @@ namespace Diligent void ValidateTextureDesc( const TextureDesc& Desc ) { #define LOG_TEXTURE_ERROR_AND_THROW(...) LOG_ERROR_AND_THROW("Texture \"", Desc.Name ? Desc.Name : "", "\": ", ##__VA_ARGS__) + + if (Desc.Type == RESOURCE_DIM_UNDEFINED) + { + LOG_TEXTURE_ERROR_AND_THROW("Resource dimension is undefined"); + } // Perform some parameter correctness check if( Desc.Type == RESOURCE_DIM_TEX_1D || Desc.Type == RESOURCE_DIM_TEX_1D_ARRAY ) |
