Optimize which surfaces are passed to lightmapper
This commit is contained in:
parent
1d2427c146
commit
7cd33cc060
4 changed files with 9 additions and 1 deletions
|
|
@ -204,6 +204,7 @@ void DoomLevelMesh::PropagateLight(const LevelMeshLight* light, std::set<LevelMe
|
|||
|
||||
// TODO skip any surface which isn't physically connected to the sector group in which the light resides
|
||||
//if (light-> == surface.sectorGroup)
|
||||
if (IsInFrontOfPlane(surface.plane, light->RelativeOrigin))
|
||||
{
|
||||
if (surface.portalIndex >= 0)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -869,7 +869,7 @@ void UpdateLightmaps(DFrameBuffer* screen, FRenderState& RenderState)
|
|||
{
|
||||
for (auto& e : level.levelMesh->Surfaces)
|
||||
{
|
||||
if (e.needsUpdate)
|
||||
if (e.needsUpdate && !e.bSky)
|
||||
{
|
||||
list.Push(&e);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue