Function Kataglyphis::VulkanRendererInternals::recordSceneMeshDraws

Function Kataglyphis::VulkanRendererInternals::recordSceneMeshDraws#

Function Documentation#

MeshDrawStats Kataglyphis::VulkanRendererInternals::recordSceneMeshDraws(vk::CommandBuffer commandBuffer, vk::PipelineLayout pipelineLayout, vk::ShaderStageFlags pushConstantStages, Kataglyphis::Scene *scene, const std::optional<FrustumPlanes> &cameraFrustum, PushConstantRasterizer &pushConstant)#

Forward/deferred rasterization’s use of walkSceneMeshes: seeds pushConstant’s model/invModelRows per model, culls against one camera frustum, then pushes PushConstantRasterizer and sets the dynamic cull mode per mesh. pipelineLayout and pushConstantStages are the two genuine differences between the callers - forward pushes eVertex|eFragment through pipeline_layout, deferred pushes eAll through geometryPipelineLayout - and must NOT be collapsed to one value. pushConstant is taken by reference so the caller’s already-seeded fields (set via setPushConstant) survive; .model / .invModelRows / .objectIndex are (re)written per mesh exactly as the inline loops did.