mirror of
https://github.com/id-Software/DOOM-3-BFG.git
synced 2025-04-24 02:32:18 +00:00
Restored internal envprobe fallback if map has no envprobes. close #836
This commit is contained in:
parent
7d0f68b9d5
commit
4357e0f7a3
2 changed files with 4 additions and 1 deletions
|
@ -585,6 +585,9 @@ void idImage::FinalizeImage( bool fromBackEnd, nvrhi::ICommandList* commandList
|
|||
|
||||
AllocImage();
|
||||
|
||||
// default it again because it was unset by AllocImage().PurgeImage()
|
||||
defaulted = true;
|
||||
|
||||
// clear the data so it's not left uninitialized
|
||||
idTempArray<byte> clear( opts.width * opts.height * 4 );
|
||||
memset( clear.Ptr(), 0, clear.Size() );
|
||||
|
|
|
@ -532,7 +532,7 @@ static void R_FindClosestEnvironmentProbes()
|
|||
RenderEnvprobeLocal* nearest = viewEnvprobes[0];
|
||||
tr.viewDef->globalProbeBounds = nearest->globalProbeBounds;
|
||||
|
||||
if( !nearest->irradianceImage->IsDefaulted() )
|
||||
if( nearest->irradianceImage->IsLoaded() && !nearest->irradianceImage->IsDefaulted() )
|
||||
{
|
||||
tr.viewDef->irradianceImage = nearest->irradianceImage;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue