Improve shadow maps sharing in nested scene rendering
This commit is contained in:
@@ -1368,10 +1368,11 @@ RETRY_ATLAS_SETUP:
|
|||||||
tile.LinkedRectTile = nullptr;
|
tile.LinkedRectTile = nullptr;
|
||||||
auto& linkedTile = linkedAtlasLight->Tiles[tileIndex];
|
auto& linkedTile = linkedAtlasLight->Tiles[tileIndex];
|
||||||
|
|
||||||
// Check if both lights use the same projections
|
// Link tile and use its projection
|
||||||
if (tile.WorldToShadow == linkedTile.WorldToShadow && linkedTile.RectTile)
|
if (linkedTile.RectTile)
|
||||||
{
|
{
|
||||||
tile.LinkedRectTile = linkedTile.RectTile;
|
tile.LinkedRectTile = linkedTile.RectTile;
|
||||||
|
tile.WorldToShadow = linkedTile.WorldToShadow;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user