mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-04-20 09:11:01 +00:00
Terrible non-sloped flat scaling, based on the X component of the scaling for software renderer.
This commit is contained in:
parent
4dd39e4063
commit
95c0b791b0
3 changed files with 16 additions and 3 deletions
|
@ -915,6 +915,7 @@ static void R_Subsector(size_t num)
|
|||
#ifdef ESLOPE
|
||||
, frontsector->f_slope
|
||||
#endif
|
||||
, frontsector->floor_scalex
|
||||
);
|
||||
}
|
||||
else
|
||||
|
@ -937,6 +938,7 @@ static void R_Subsector(size_t num)
|
|||
#ifdef ESLOPE
|
||||
, frontsector->c_slope
|
||||
#endif
|
||||
, frontsector->ceiling_scalex
|
||||
);
|
||||
}
|
||||
else
|
||||
|
@ -998,6 +1000,7 @@ static void R_Subsector(size_t num)
|
|||
#ifdef ESLOPE
|
||||
, *rover->b_slope
|
||||
#endif
|
||||
, frontsector->floor_scalex
|
||||
);
|
||||
|
||||
#ifdef ESLOPE
|
||||
|
@ -1044,6 +1047,7 @@ static void R_Subsector(size_t num)
|
|||
#ifdef ESLOPE
|
||||
, *rover->t_slope
|
||||
#endif
|
||||
, frontsector->ceiling_scalex
|
||||
);
|
||||
|
||||
#ifdef ESLOPE
|
||||
|
@ -1094,6 +1098,7 @@ static void R_Subsector(size_t num)
|
|||
#ifdef ESLOPE
|
||||
, NULL // will ffloors be slopable eventually?
|
||||
#endif
|
||||
, polysec->floor_scalex
|
||||
);
|
||||
|
||||
ffloor[numffloors].height = polysec->floorheight;
|
||||
|
@ -1122,6 +1127,7 @@ static void R_Subsector(size_t num)
|
|||
#ifdef ESLOPE
|
||||
, NULL // will ffloors be slopable eventually?
|
||||
#endif
|
||||
, polysec->ceiling_scalex
|
||||
);
|
||||
|
||||
ffloor[numffloors].polyobj = po;
|
||||
|
|
|
@ -322,6 +322,7 @@ visplane_t *R_FindPlane(fixed_t height, INT32 picnum, INT32 lightlevel,
|
|||
#ifdef ESLOPE
|
||||
, pslope_t *slope
|
||||
#endif
|
||||
, fixed_t scale
|
||||
)
|
||||
{
|
||||
visplane_t *check;
|
||||
|
@ -390,6 +391,7 @@ visplane_t *R_FindPlane(fixed_t height, INT32 picnum, INT32 lightlevel,
|
|||
#ifdef ESLOPE
|
||||
&& check->slope == slope
|
||||
#endif
|
||||
&& check->scale == scale
|
||||
)
|
||||
{
|
||||
return check;
|
||||
|
@ -405,6 +407,7 @@ visplane_t *R_FindPlane(fixed_t height, INT32 picnum, INT32 lightlevel,
|
|||
check->maxx = -1;
|
||||
check->xoffs = xoff;
|
||||
check->yoffs = yoff;
|
||||
check->scale = scale;
|
||||
check->extra_colormap = planecolormap;
|
||||
check->ffloor = pfloor;
|
||||
check->viewx = viewx;
|
||||
|
@ -490,6 +493,7 @@ visplane_t *R_CheckPlane(visplane_t *pl, INT32 start, INT32 stop)
|
|||
#ifdef ESLOPE
|
||||
new_pl->slope = pl->slope;
|
||||
#endif
|
||||
new_pl->scale = pl->scale;
|
||||
pl = new_pl;
|
||||
pl->minx = start;
|
||||
pl->maxx = stop;
|
||||
|
@ -989,9 +993,9 @@ void R_DrawSinglePlane(visplane_t *pl)
|
|||
viewangle = pl->viewangle+pl->plangle;
|
||||
}
|
||||
|
||||
xoffs = pl->xoffs;
|
||||
yoffs = pl->yoffs;
|
||||
planeheight = abs(pl->height - pl->viewz);
|
||||
xoffs = FixedMul(pl->scale, pl->xoffs);
|
||||
yoffs = FixedMul(pl->scale, pl->yoffs);
|
||||
planeheight = FixedMul(pl->scale, abs(pl->height - pl->viewz));
|
||||
|
||||
currentplane = pl;
|
||||
levelflat = &levelflats[pl->picnum];
|
||||
|
|
|
@ -46,6 +46,8 @@ typedef struct visplane_s
|
|||
|
||||
fixed_t xoffs, yoffs; // Scrolling flats.
|
||||
|
||||
fixed_t scale; // Scale.
|
||||
|
||||
struct ffloor_s *ffloor;
|
||||
#ifdef POLYOBJECTS_PLANES
|
||||
polyobj_t *polyobj;
|
||||
|
@ -89,6 +91,7 @@ visplane_t *R_FindPlane(fixed_t height, INT32 picnum, INT32 lightlevel, fixed_t
|
|||
#ifdef ESLOPE
|
||||
, pslope_t *slope
|
||||
#endif
|
||||
, fixed_t scale
|
||||
);
|
||||
visplane_t *R_CheckPlane(visplane_t *pl, INT32 start, INT32 stop);
|
||||
void R_ExpandPlane(visplane_t *pl, INT32 start, INT32 stop);
|
||||
|
|
Loading…
Reference in a new issue