mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-22 20:21:26 +00:00
- reinstated rendering of mid textures over two-sided wall portals.
This was removed in the last PR due to z-fighting problems which now have also been addressed
This commit is contained in:
parent
a15216c90f
commit
0c0ef4f938
2 changed files with 12 additions and 1 deletions
|
@ -49,7 +49,7 @@ void HWDrawInfo::AddWall(HWWall *wall)
|
||||||
bool masked = HWWall::passflag[wall->type] == 1 ? false : (wall->texture && wall->texture->isMasked());
|
bool masked = HWWall::passflag[wall->type] == 1 ? false : (wall->texture && wall->texture->isMasked());
|
||||||
int list;
|
int list;
|
||||||
|
|
||||||
if ((wall->flags & HWWall::HWF_SKYHACK && wall->type == RENDERWALL_M2S))
|
if (wall->flags & HWWall::HWF_SKYHACK && wall->type == RENDERWALL_M2S)
|
||||||
{
|
{
|
||||||
list = GLDL_MASKEDWALLSOFS;
|
list = GLDL_MASKEDWALLSOFS;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1443,6 +1443,11 @@ void HWWall::DoMidTexture(HWDrawInfo *di, seg_t * seg, bool drawfogboundary,
|
||||||
tci.mScale.Y = -tci.mScale.Y;
|
tci.mScale.Y = -tci.mScale.Y;
|
||||||
flags |= HWF_NOSLICE;
|
flags |= HWF_NOSLICE;
|
||||||
}
|
}
|
||||||
|
if (seg->linedef->isVisualPortal())
|
||||||
|
{
|
||||||
|
// mid textures on portal lines need the same offsetting as mid textures on sky lines
|
||||||
|
flags |= HWF_SKYHACK;
|
||||||
|
}
|
||||||
SetWallCoordinates(seg, &tci, texturetop, topleft, topright, bottomleft, bottomright, t_ofs);
|
SetWallCoordinates(seg, &tci, texturetop, topleft, topright, bottomleft, bottomright, t_ofs);
|
||||||
|
|
||||||
//
|
//
|
||||||
|
@ -2165,6 +2170,12 @@ void HWWall::Process(HWDrawInfo *di, seg_t *seg, sector_t * frontsector, sector_
|
||||||
zbottom[0] = bfh1;
|
zbottom[0] = bfh1;
|
||||||
zbottom[1] = bfh2;
|
zbottom[1] = bfh2;
|
||||||
PutPortal(di, PORTALTYPE_LINETOLINE, -1);
|
PutPortal(di, PORTALTYPE_LINETOLINE, -1);
|
||||||
|
|
||||||
|
if (texture && seg->backsector != nullptr)
|
||||||
|
{
|
||||||
|
DoMidTexture(di, seg, drawfogboundary, frontsector, backsector, realfront, realback,
|
||||||
|
fch1, fch2, ffh1, ffh2, bch1, bch2, bfh1, bfh2);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue