Add real-time environment probes support

This commit is contained in:
Wojciech Figat
2022-07-18 14:50:41 +02:00
parent 3dbff3cab7
commit 60f868a08b
7 changed files with 124 additions and 50 deletions

View File

@@ -89,8 +89,7 @@ void ForwardShadingFeature::Bind(MaterialShader::BindParameters& params, Span<by
if (probe && probe->GetProbe())
{
probe->SetupProbeData(params.RenderContext, &data.EnvironmentProbe);
const auto texture = probe->GetProbe()->GetTexture();
context->BindSR(envProbeShaderRegisterIndex, GET_TEXTURE_VIEW_SAFE(texture));
context->BindSR(envProbeShaderRegisterIndex, probe->GetProbe());
}
else
{