add BaseType in vulkan namespace

This commit is contained in:
hyzboy 2020-07-28 16:33:26 +08:00
parent 43fc64211e
commit bd811a009c
2 changed files with 3 additions and 3 deletions

View File

@ -2,7 +2,7 @@
#include<hgl/type/BaseString.h>
#include<hgl/type/List.h>
#include<hgl/type/StringList.h>
#include<hgl/graph/vulkan/VKNamespace.h>
#include<hgl/graph/vulkan/VKFormat.h>
VK_NAMESPACE_BEGIN
struct ShaderStage
@ -10,7 +10,7 @@ VK_NAMESPACE_BEGIN
AnsiString name;
uint location;
uint base_type; ///<基本类型(如vec4中的vec)
BaseType base_type; ///<基本类型(如vec4中的vec)
uint component; ///<成份数量(如vec4中的4)
VkFormat format; ///<对应的Vulkan格式(如vec4对应的FMT_RGBA32F)

View File

@ -36,7 +36,7 @@ VK_NAMESPACE_BEGIN
ss=new ShaderStage;
ss->location=*data++;
ss->base_type=*data++;
ss->base_type=(VK_NAMESPACE::BaseType)*data++;
ss->component=*data++;
VK_NAMESPACE::GetVulkanFormatStride(ss->format,ss->stride,ss->base_type,ss->component);