Ver Fonte

vulkan: fix #2032
when using the low level vertexmain and pixelmain entry points
it can happen that there are no local uniforms used.

niki há 1 ano atrás
pai
commit
ca0264e906
1 ficheiros alterados com 1 adições e 1 exclusões
  1. 1 1
      src/modules/graphics/vulkan/Shader.cpp

+ 1 - 1
src/modules/graphics/vulkan/Shader.cpp

@@ -229,7 +229,7 @@ void Shader::newFrame()
 		streamBuffers.clear();
 		streamBuffers.push_back(new StreamBuffer(vgfx, BUFFERUSAGE_UNIFORM, newSize));
 	}
-	else
+	else if (streamBuffers.size() == 1)
 		streamBuffers.at(0)->nextFrame();
 
 	for (VkDescriptorPool pool : descriptorPools[currentFrame])