排版
This commit is contained in:
parent
cd331365fe
commit
e53a57fe00
@ -71,10 +71,11 @@ bool CommandBuffer::Bind(Pipeline *p)
|
||||
{
|
||||
if(!p)return(false);
|
||||
|
||||
vkCmdBindPipeline(cmd_buf, VK_PIPELINE_BIND_POINT_GRAPHICS,*p);
|
||||
|
||||
if(p->GetDescriptorSetCount()>0)
|
||||
vkCmdBindDescriptorSets(cmd_buf, VK_PIPELINE_BIND_POINT_GRAPHICS, p->GetLayout(), 0, p->GetDescriptorSetCount(),p->GetDescriptorSets(), 0, nullptr);
|
||||
|
||||
vkCmdBindPipeline(cmd_buf, VK_PIPELINE_BIND_POINT_GRAPHICS,*p);
|
||||
return(true);
|
||||
}
|
||||
|
||||
|
@ -26,8 +26,8 @@ public:
|
||||
|
||||
VkPipelineLayout GetLayout(){return pipeline_layout;}
|
||||
|
||||
const uint32_t GetDescriptorSetCount()const{return desc_sets->GetCount();}
|
||||
const VkDescriptorSet * GetDescriptorSets()const{return desc_sets->GetData();}
|
||||
const uint32_t GetDescriptorSetCount ()const{return desc_sets->GetCount();}
|
||||
const VkDescriptorSet * GetDescriptorSets ()const{return desc_sets->GetData();}
|
||||
};//class GraphicsPipeline
|
||||
|
||||
class Shader;
|
||||
|
@ -172,7 +172,7 @@ private:
|
||||
|
||||
if(!ubo_mvp)
|
||||
return(false);
|
||||
|
||||
|
||||
return material_instance->UpdateUBO("world",*ubo_mvp);
|
||||
}
|
||||
|
||||
@ -259,7 +259,7 @@ int main(int,char **)
|
||||
app.AcquireNextFrame();
|
||||
app.Draw();
|
||||
|
||||
//wait_seconds(0.1);
|
||||
wait_seconds(0.5);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user