Fixing raster rendering
This commit is contained in:
parent
afb8fe7874
commit
d19c8064c1
3 changed files with 5 additions and 4 deletions
|
|
@ -418,8 +418,8 @@ void HelloVulkan::rasterize(const VkCommandBuffer& cmdBuf)
|
|||
vkCmdBindPipeline(cmdBuf, VK_PIPELINE_BIND_POINT_GRAPHICS, m_graphicsPipeline);
|
||||
vkCmdBindDescriptorSets(cmdBuf, VK_PIPELINE_BIND_POINT_GRAPHICS, m_pipelineLayout, 0, 1, &m_descSet, 0, nullptr);
|
||||
|
||||
|
||||
for(int i = 0; i < m_objInstance.size(); ++i)
|
||||
uint32_t nbInst = static_cast<uint32_t>(m_objInstance.size() - 1); // Remove the implicit object
|
||||
for(uint32_t i = 0; i < nbInst; ++i)
|
||||
{
|
||||
auto& inst = m_objInstance[i];
|
||||
auto& model = m_objModel[inst.objIndex];
|
||||
|
|
|
|||
|
|
@ -200,7 +200,7 @@ int main(int argc, char** argv)
|
|||
|
||||
for(int n = 0; n < 50; ++n)
|
||||
{
|
||||
ObjInstance inst;
|
||||
ObjInstance inst = helloVk.m_objInstance[wusonIndex];
|
||||
inst.objIndex = wusonIndex;
|
||||
inst.txtOffset = 0;
|
||||
float scale = fabsf(disn(gen));
|
||||
|
|
|
|||
|
|
@ -427,7 +427,8 @@ void HelloVulkan::rasterize(const VkCommandBuffer& cmdBuf)
|
|||
vkCmdBindDescriptorSets(cmdBuf, VK_PIPELINE_BIND_POINT_GRAPHICS, m_pipelineLayout, 0, 1, &m_descSet, 0, nullptr);
|
||||
|
||||
|
||||
for(int i = 0; i < m_objInstance.size(); ++i)
|
||||
uint32_t nbInst = static_cast<uint32_t>(m_objInstance.size() - 1); // Remove the implicit object
|
||||
for(uint32_t i = 0; i < nbInst; ++i)
|
||||
{
|
||||
auto& inst = m_objInstance[i];
|
||||
auto& model = m_objModel[inst.objIndex];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue