Minor fixes
This commit is contained in:
parent
f580ba523d
commit
34348b2dde
|
|
@ -292,7 +292,6 @@ namespace Nz
|
||||||
const Matrix4f& viewProjMatrix = lightData->camera->GetViewerInstance().GetViewProjMatrix();
|
const Matrix4f& viewProjMatrix = lightData->camera->GetViewerInstance().GetViewProjMatrix();
|
||||||
|
|
||||||
Frustumf frustum = Frustumf::Extract(viewProjMatrix);
|
Frustumf frustum = Frustumf::Extract(viewProjMatrix);
|
||||||
GetDebugDrawer().DrawFrustum(frustum, Nz::Color::Blue);
|
|
||||||
|
|
||||||
std::size_t visibilityHash = 5U;
|
std::size_t visibilityHash = 5U;
|
||||||
|
|
||||||
|
|
@ -371,7 +370,6 @@ namespace Nz
|
||||||
std::size_t depthVisibilityHash = visibilityHash;
|
std::size_t depthVisibilityHash = visibilityHash;
|
||||||
|
|
||||||
m_visibleLights.clear();
|
m_visibleLights.clear();
|
||||||
for (const LightData& lightData : m_lightPool)
|
|
||||||
for (auto it = m_lightPool.begin(); it != m_lightPool.end(); ++it)
|
for (auto it = m_lightPool.begin(); it != m_lightPool.end(); ++it)
|
||||||
{
|
{
|
||||||
const LightData& lightData = *it;
|
const LightData& lightData = *it;
|
||||||
|
|
@ -597,6 +595,7 @@ namespace Nz
|
||||||
});
|
});
|
||||||
|
|
||||||
lightData->camera->UpdateFOV(spotLight.GetOuterAngle() * 2.f);
|
lightData->camera->UpdateFOV(spotLight.GetOuterAngle() * 2.f);
|
||||||
|
lightData->camera->UpdateZNear(0.01f);
|
||||||
lightData->camera->UpdateZFar(spotLight.GetRadius());
|
lightData->camera->UpdateZFar(spotLight.GetRadius());
|
||||||
lightData->camera->UpdateViewport(Recti(0, 0, SafeCast<int>(shadowMapSize), SafeCast<int>(shadowMapSize)));
|
lightData->camera->UpdateViewport(Recti(0, 0, SafeCast<int>(shadowMapSize), SafeCast<int>(shadowMapSize)));
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -57,7 +57,6 @@ namespace Nz
|
||||||
const auto& depthTexture2D = Graphics::Instance()->GetDefaultTextures().depthTextures[UnderlyingCast(ImageType::E2D)];
|
const auto& depthTexture2D = Graphics::Instance()->GetDefaultTextures().depthTextures[UnderlyingCast(ImageType::E2D)];
|
||||||
const auto& depthTextureCube = Graphics::Instance()->GetDefaultTextures().depthTextures[UnderlyingCast(ImageType::Cubemap)];
|
const auto& depthTextureCube = Graphics::Instance()->GetDefaultTextures().depthTextures[UnderlyingCast(ImageType::Cubemap)];
|
||||||
const auto& whiteTexture2D = Graphics::Instance()->GetDefaultTextures().whiteTextures[UnderlyingCast(ImageType::E2D)];
|
const auto& whiteTexture2D = Graphics::Instance()->GetDefaultTextures().whiteTextures[UnderlyingCast(ImageType::E2D)];
|
||||||
const auto& whiteTextureCube = Graphics::Instance()->GetDefaultTextures().whiteTextures[UnderlyingCast(ImageType::Cubemap)];
|
|
||||||
const auto& defaultSampler = graphics->GetSamplerCache().Get({});
|
const auto& defaultSampler = graphics->GetSamplerCache().Get({});
|
||||||
|
|
||||||
TextureSamplerInfo samplerInfo;
|
TextureSamplerInfo samplerInfo;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue