fixing light culling

This commit is contained in:
Dynamitos committed 2024-02-23 08:31:21 +01:00
1 parent 15813ba612
commit a3f5ad2841
8 files changed
+37 -24

No files matched your search

@@ -169,7 +169,6 @@ void BasePass::render()
}
graphics->executeCommands(commands);
graphics->endRenderPass();
vkDeviceWaitIdle(((Vulkan::Graphics*)graphics.getHandle())->getDevice());
}
void BasePass::endFrame()
@@ -28,6 +28,7 @@ void RenderPass::beginFrame(const Component::Camera& cam)
viewParams = {
.viewMatrix = cam.getViewMatrix(),
.projectionMatrix = viewport->getProjectionMatrix(),
.inverseProjection = glm::inverse(viewport->getProjectionMatrix()),
.cameraPosition = Vector4(cam.getCameraPosition(), 1),
.screenDimensions = Vector2(static_cast<float>(viewport->getWidth()), static_cast<float>(viewport->getHeight())),
};
@@ -31,6 +31,7 @@ protected:
{
Matrix4 viewMatrix;
Matrix4 projectionMatrix;
Matrix4 inverseProjection;
Vector4 cameraPosition;
Vector2 screenDimensions;
} viewParams;