- new renderer: take fog properties for walls and ceilings from the proper elements.

This commit is contained in:
Christoph Oelckers 2021-05-20 19:17:21 +02:00
parent ec976d9db7
commit 5cfd810311
2 changed files with 3 additions and 2 deletions

View File

@ -246,7 +246,6 @@ void HWFlat::ProcessSector(HWDrawInfo *di, sectortype * frontsector, int section
float florz, ceilz;
PlanesAtPoint(frontsector, float(vp.Pos.X) * 16.f, float(vp.Pos.Y) * -16.f, &ceilz, &florz);
fade = lookups.getFade(frontsector->floorpal); // fog is per sector.
visibility = sectorVisibility(frontsector);
sec = frontsector;
section = section_;
@ -264,6 +263,7 @@ void HWFlat::ProcessSector(HWDrawInfo *di, sectortype * frontsector, int section
{
// process the original floor first.
fade = lookups.getFade(frontsector->floorpal);
shade = frontsector->floorshade;
palette = frontsector->floorpal;
stack = frontsector->portalflags == PORTAL_SECTOR_FLOOR || frontsector->portalflags == PORTAL_SECTOR_FLOOR_REFLECT;
@ -304,6 +304,7 @@ void HWFlat::ProcessSector(HWDrawInfo *di, sectortype * frontsector, int section
{
// process the original ceiling first.
fade = lookups.getFade(frontsector->ceilingpal);
shade = frontsector->ceilingshade;
palette = frontsector->ceilingpal;
stack = frontsector->portalflags == PORTAL_SECTOR_CEILING || frontsector->portalflags == PORTAL_SECTOR_CEILING_REFLECT;

View File

@ -952,7 +952,7 @@ void HWWall::Process(HWDrawInfo* di, walltype* wal, sectortype* frontsector, sec
dynlightindex = -1;
shade = wal->shade;
palette = wal->pal;
fade = lookups.getFade(frontsector->floorpal); // fog is per sector.
fade = lookups.getFade(wal->pal);
visibility = sectorVisibility(frontsector);
alpha = 1.0f;