using IBAccess=IndexBufferAccess

This commit is contained in:
2024-04-27 00:05:25 +08:00
parent 6dba761a80
commit bbf94767fe
9 changed files with 19 additions and 21 deletions

View File

@@ -129,12 +129,12 @@ bool RenderCmdBuffer::BindDescriptorSets(Material *mtl)
return(true);
}
void RenderCmdBuffer::BindIBO(const IndexBufferAccess *ibd)
void RenderCmdBuffer::BindIBO(const IBAccess *iba)
{
vkCmdBindIndexBuffer( cmd_buf,
ibd->buffer->GetBuffer(),
ibd->offset,
VkIndexType(ibd->buffer->GetType()));
iba->buffer->GetBuffer(),
iba->offset,
VkIndexType(iba->buffer->GetType()));
}
bool RenderCmdBuffer::BindVBO(Renderable *ri)

View File

@@ -6,7 +6,7 @@
#include<hgl/log/LogInfo.h>
VK_NAMESPACE_BEGIN
VertexInputData::VertexInputData(const uint32_t c,const uint32_t vc,const IndexBufferAccess *iba)
VertexInputData::VertexInputData(const uint32_t c,const uint32_t vc,const IBAccess *iba)
{
binding_count=c;
@@ -57,7 +57,7 @@ Renderable *CreateRenderable(Primitive *prim,MaterialInstance *mi,Pipeline *p)
VAB *vab;
VertexInputData *vid=new VertexInputData(input_count,prim->GetVertexCount(),prim->GetIndexBufferAccess());
VertexInputData *vid=new VertexInputData(input_count,prim->GetVertexCount(),prim->GetIBAccess());
const VertexInputFormat *vif=vil->GetVIFList(VertexInputGroup::Basic);
VABAccess vad;