- depth bias fixes.

This commit is contained in:
Christoph Oelckers 2021-06-09 00:47:13 +02:00
parent 5b38343407
commit 9d36e61d3f
3 changed files with 3 additions and 3 deletions

View file

@ -538,7 +538,7 @@ void HWDrawInfo::RenderScene(FRenderState &state)
drawlists[GLDL_MASKEDWALLSH].DrawWalls(this, state, false);
state.SetColorMask(true);
state.SetDepthBias(-1, 128);
state.SetDepthBias(-1, -128);
state.SetDepthMask(false);
drawlists[GLDL_MASKEDFLATS].DrawFlats(this, state, false);
state.SetDepthMask(true);

View file

@ -272,7 +272,7 @@ void HWWall::RenderTexturedWall(HWDrawInfo *di, FRenderState &state, int rflags)
else if (!(rflags & RWF_TRANS))
{
auto oldbias = state.GetDepthBias();
if (walldist >= 0) state.SetDepthBias(-1, glseg.x1 == glseg.x2 || glseg.y1 == glseg.y2? -128 : -192);
if (walldist >= 0) state.SetDepthBias(-1, glseg.x1 == glseg.x2 || glseg.y1 == glseg.y2? -129 : -192);
else state.ClearDepthBias();
RenderWall(di, state, rflags);
state.SetDepthBias(oldbias);

View file

@ -74,7 +74,7 @@ const char *GetVersionString();
#define MINSAVEVER_SW 12
#define MINSAVEVER_PS 12
#define SAVEVER_DN3D 10
#define SAVEVER_DN3D 11
#define SAVEVER_BLD 11
#define SAVEVER_SW 12
#define SAVEVER_PS 13