mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-02-28 06:22:05 +00:00
Changes:
- OpenGL: Fix a possibly incorrect use of HWR_SplitWall on extra textures on 3D floor sides - OpenGL: Fix a missing use of PF_Decal on extra textures on 3D floor sides
This commit is contained in:
parent
902c61a32f
commit
b888832114
1 changed files with 23 additions and 20 deletions
|
@ -1761,20 +1761,29 @@ static void HWR_RenderExtraTexture(unsigned which, side_t *side, sector_t *sec_f
|
|||
wallVerts[2].y = FIXED_TO_FLOAT(hS);
|
||||
wallVerts[1].y = FIXED_TO_FLOAT(lS);
|
||||
|
||||
blendmode |= PF_Decal;
|
||||
|
||||
extracolormap_t *colormap = gl_frontsector->extra_colormap;
|
||||
|
||||
#define RENDER_WALL_POLYGON() { \
|
||||
if (gl_frontsector->numlights) \
|
||||
{ \
|
||||
if (!(blendmode & PF_Masked)) \
|
||||
HWR_SplitWall(gl_frontsector, wallVerts, texnum, &Surf, FOF_TRANSLUCENT, pfloor, blendmode); \
|
||||
else \
|
||||
HWR_SplitWall(gl_frontsector, wallVerts, texnum, &Surf, FOF_CUTLEVEL, pfloor, blendmode); \
|
||||
} \
|
||||
else \
|
||||
{ \
|
||||
if (!(blendmode & PF_Masked)) \
|
||||
HWR_AddTransparentWall(wallVerts, &Surf, texnum, blendmode, blendmode & PF_Fog, lightnum, colormap); \
|
||||
else \
|
||||
HWR_ProjectWall(wallVerts, &Surf, blendmode, lightnum, colormap); \
|
||||
} \
|
||||
}
|
||||
|
||||
if (!(h == l && hS == lS))
|
||||
{
|
||||
if (gl_frontsector->numlights)
|
||||
HWR_SplitWall(gl_frontsector, wallVerts, texnum, &Surf, FOF_CUTLEVEL, pfloor, blendmode);
|
||||
else
|
||||
{
|
||||
if (blendmode != PF_Masked)
|
||||
HWR_AddTransparentWall(wallVerts, &Surf, texnum, blendmode, blendmode & PF_Fog, lightnum, colormap);
|
||||
else
|
||||
HWR_ProjectWall(wallVerts, &Surf, blendmode, lightnum, colormap);
|
||||
}
|
||||
}
|
||||
RENDER_WALL_POLYGON();
|
||||
|
||||
if (!intersected)
|
||||
return;
|
||||
|
@ -1850,15 +1859,9 @@ static void HWR_RenderExtraTexture(unsigned which, side_t *side, sector_t *sec_f
|
|||
wallVerts[1].t = (hS - lS + texturevpegslope) * yscale * grTex->scaleY;
|
||||
wallVerts[2].s = wallVerts[1].s = ((xcliphigh * xscale) + overlay->offsetx) * grTex->scaleX;
|
||||
|
||||
if (gl_frontsector->numlights)
|
||||
HWR_SplitWall(gl_frontsector, wallVerts, texnum, &Surf, FOF_CUTLEVEL, pfloor, blendmode);
|
||||
else
|
||||
{
|
||||
if (blendmode != PF_Masked)
|
||||
HWR_AddTransparentWall(wallVerts, &Surf, texnum, blendmode, blendmode & PF_Fog, lightnum, colormap);
|
||||
else
|
||||
HWR_ProjectWall(wallVerts, &Surf, blendmode, lightnum, colormap);
|
||||
}
|
||||
RENDER_WALL_POLYGON();
|
||||
|
||||
#undef RENDER_WALL_POLYGON
|
||||
}
|
||||
|
||||
static void HWR_RenderFFloorExtraTextures(ffloor_t *pfloor, v2d_t vs, v2d_t ve, float xcliplow, float xcliphigh, FSurfaceInfo Surf, FBITFIELD blendmode, UINT32 lightnum)
|
||||
|
|
Loading…
Reference in a new issue