use AnsiString in shader
This commit is contained in:
@@ -28,11 +28,11 @@ public:
|
||||
bool End(){return(vkEndCommandBuffer(cmd_buf)==VK_SUCCESS);}
|
||||
|
||||
#ifdef _DEBUG
|
||||
void SetDebugName(const UTF8String &);
|
||||
void BeginRegion(const UTF8String &,const Color4f &);
|
||||
void SetDebugName(const AnsiString &);
|
||||
void BeginRegion(const AnsiString &,const Color4f &);
|
||||
void EndRegion();
|
||||
#else
|
||||
void BeginRegion(const UTF8String &,const Color4f &){}
|
||||
void BeginRegion(const AnsiString &,const Color4f &){}
|
||||
void EndRegion(){}
|
||||
#endif//_DEBUG
|
||||
};//class GPUCmdBuffer
|
||||
|
@@ -90,11 +90,11 @@ VK_NAMESPACE_BEGIN
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
T *GetDeviceProc(const char *name)
|
||||
T *GetDeviceProc(VkDevice *dev,const char *name)
|
||||
{
|
||||
if(!GetDeviceProcAddr)return(nullptr);
|
||||
|
||||
return reinterpret_cast<T>(GetDeviceProcAddr(name));
|
||||
return reinterpret_cast<T>(GetDeviceProcAddr(dev,name));
|
||||
}
|
||||
|
||||
void DestroySurface(VkSurfaceKHR);
|
||||
|
@@ -7,7 +7,7 @@
|
||||
VK_NAMESPACE_BEGIN
|
||||
class MaterialDescriptorManager
|
||||
{
|
||||
UTF8String mtl_name;
|
||||
AnsiString mtl_name;
|
||||
|
||||
BindingMapArray binding_map[DESCRIPTOR_SET_TYPE_COUNT];
|
||||
|
||||
@@ -19,11 +19,11 @@ private:
|
||||
|
||||
public:
|
||||
|
||||
MaterialDescriptorManager(const UTF8String &,ShaderDescriptor *,const uint);
|
||||
MaterialDescriptorManager(const UTF8String &,const ShaderDescriptorSetArray &);
|
||||
MaterialDescriptorManager(const AnsiString &,ShaderDescriptor *,const uint);
|
||||
MaterialDescriptorManager(const AnsiString &,const ShaderDescriptorSetArray &);
|
||||
~MaterialDescriptorManager();
|
||||
|
||||
const UTF8String &GetMaterialName()const{return mtl_name;}
|
||||
const AnsiString &GetMaterialName()const{return mtl_name;}
|
||||
|
||||
const uint GetBindCount(const DescriptorSetType &set_type)const
|
||||
{
|
||||
|
@@ -171,7 +171,7 @@ namespace hgl
|
||||
|
||||
AABB GetAABB()const
|
||||
{
|
||||
vec min_point,max_point;
|
||||
glm::vec4 min_point,max_point;
|
||||
|
||||
GetBoundingBox(min_point,max_point);
|
||||
|
||||
@@ -264,7 +264,7 @@ namespace hgl
|
||||
|
||||
AABB GetAABB()const
|
||||
{
|
||||
vec min_point,max_point;
|
||||
glm::vec4 min_point,max_point;
|
||||
|
||||
GetBoundingBox(min_point,max_point);
|
||||
|
||||
@@ -462,10 +462,10 @@ namespace hgl
|
||||
template<typename V>
|
||||
bool WriteRect(const T left,const T top,const T width,const T height)
|
||||
{
|
||||
const vec2<V> lt(left ,top);
|
||||
const vec2<V> rt(left+width,top);
|
||||
const vec2<V> rb(left+width,top+height);
|
||||
const vec2<V> lb(left ,top+height);
|
||||
const glm::vec<2,V,glm::defaultp> lt(left ,top);
|
||||
const glm::vec<2,V,glm::defaultp> rt(left+width,top);
|
||||
const glm::vec<2,V,glm::defaultp> rb(left+width,top+height);
|
||||
const glm::vec<2,V,glm::defaultp> lb(left ,top+height);
|
||||
|
||||
return WriteQuad(lt,rt,rb,lb);
|
||||
}
|
||||
@@ -580,7 +580,7 @@ namespace hgl
|
||||
|
||||
AABB GetAABB()const
|
||||
{
|
||||
vec min_point,max_point;
|
||||
glm::vec4 min_point,max_point;
|
||||
|
||||
GetBoundingBox(min_point,max_point);
|
||||
|
||||
@@ -850,7 +850,7 @@ namespace hgl
|
||||
|
||||
AABB GetAABB()const
|
||||
{
|
||||
vec min_point,max_point;
|
||||
glm::vec4 min_point,max_point;
|
||||
|
||||
GetBoundingBox(min_point,max_point);
|
||||
|
||||
|
@@ -58,7 +58,7 @@ public:
|
||||
|
||||
bool AddConstValue(ConstValueDescriptor *sd);
|
||||
|
||||
void SetPushConstant(const AnsiString name,uint8_t offset,uint8_t size);
|
||||
void SetPushConstant(const AnsiString &name,uint8_t offset,uint8_t size);
|
||||
};//class ShaderDescriptorInfo
|
||||
|
||||
template<VkShaderStageFlagBits SS,typename IArray,typename I,typename OArray,typename O> class CustomShaderDescriptorInfo:public ShaderDescriptorInfo
|
||||
@@ -98,7 +98,7 @@ public:
|
||||
using CustomShaderDescriptorInfo<VK_SHADER_STAGE_VERTEX_BIT,VIAArray,VIA,SVArray,ShaderVariable>::CustomShaderDescriptorInfo;
|
||||
~VertexShaderDescriptorInfo()override=default;
|
||||
|
||||
bool AddSubpassInput(const AnsiString name,uint8_t index);
|
||||
bool AddSubpassInput(const AnsiString &name,uint8_t index);
|
||||
};//class VertexShaderDescriptorInfo
|
||||
|
||||
using TessCtrlShaderDescriptorInfo=CustomShaderDescriptorInfo<VK_SHADER_STAGE_TESSELLATION_CONTROL_BIT, SVArray, ShaderVariable, SVArray, ShaderVariable >;
|
||||
|
Reference in New Issue
Block a user