File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ struct EnvMapRenderer::EnvMapShaderAttribs
5353 float Alpha = 0 .f;
5454 float Padding = 0 .f;
5555
56- float4 Scale;
56+ float4 Scale{ 1 , 1 , 1 , 1 } ;
5757};
5858
5959EnvMapRenderer::EnvMapRenderer (const CreateInfo& CI) :
@@ -229,7 +229,8 @@ void EnvMapRenderer::Prepare(IDeviceContext* pContext,
229229 if (std::memcmp (&m_ShaderAttribs->ToneMapping , &ToneMapping, sizeof (ToneMapping)) != 0 ||
230230 m_ShaderAttribs->AverageLogLum != Attribs.AverageLogLum ||
231231 m_ShaderAttribs->MipLevel != Attribs.MipLevel ||
232- m_ShaderAttribs->Alpha != Attribs.Alpha )
232+ m_ShaderAttribs->Alpha != Attribs.Alpha ||
233+ m_ShaderAttribs->Scale != float4{Attribs.Scale , 1 })
233234 {
234235 m_ShaderAttribs->ToneMapping = ToneMapping;
235236 m_ShaderAttribs->AverageLogLum = Attribs.AverageLogLum ;
@@ -250,6 +251,7 @@ void EnvMapRenderer::Prepare(IDeviceContext* pContext,
250251 EnvMapAttribs->AverageLogLum = Attribs.AverageLogLum ;
251252 EnvMapAttribs->MipLevel = Attribs.MipLevel ;
252253 EnvMapAttribs->Alpha = Attribs.Alpha ;
254+ EnvMapAttribs->Scale = float4{Attribs.Scale , 1 };
253255 }
254256 }
255257}
You can’t perform that action at this time.
0 commit comments