Merge remote-tracking branch 'public-gl/master' into 2122-version

This commit is contained in:
mazmazz 2018-12-25 00:19:45 -05:00
commit 842bcfc8a0
3 changed files with 10 additions and 4 deletions

View file

@ -428,6 +428,15 @@ INT32 I_GetKey(void);
#define max(x, y) (((x) > (y)) ? (x) : (y)) #define max(x, y) (((x) > (y)) ? (x) : (y))
#endif #endif
// Floating point comparison epsilons from float.h
#ifndef FLT_EPSILON
#define FLT_EPSILON 1.1920928955078125e-7f
#endif
#ifndef DBL_EPSILON
#define DBL_EPSILON 2.2204460492503131e-16
#endif
// An assert-type mechanism. // An assert-type mechanism.
#ifdef PARANOIA #ifdef PARANOIA
#define I_Assert(e) ((e) ? (void)0 : I_Error("assert failed: %s, file %s, line %d", #e, __FILE__, __LINE__)) #define I_Assert(e) ((e) ? (void)0 : I_Error("assert failed: %s, file %s, line %d", #e, __FILE__, __LINE__))

View file

@ -1220,7 +1220,7 @@ INT32 R_CreateColormap(char *p1, char *p2, char *p3)
continue; continue;
if (maskcolor == extra_colormaps[i].maskcolor if (maskcolor == extra_colormaps[i].maskcolor
&& fadecolor == extra_colormaps[i].fadecolor && fadecolor == extra_colormaps[i].fadecolor
&& fabsf((float)(maskamt - extra_colormaps[i].maskamt)) < 1.0E-36f && fabs(maskamt - extra_colormaps[i].maskamt) < DBL_EPSILON
&& fadestart == extra_colormaps[i].fadestart && fadestart == extra_colormaps[i].fadestart
&& fadeend == extra_colormaps[i].fadeend && fadeend == extra_colormaps[i].fadeend
&& fog == extra_colormaps[i].fog) && fog == extra_colormaps[i].fog)

View file

@ -1126,9 +1126,6 @@ void R_RenderThickSideRange(drawseg_t *ds, INT32 x1, INT32 x2, ffloor_t *pfloor)
// Get data for the column // Get data for the column
col = (column_t *)((UINT8 *)R_GetColumn(texnum,maskedtexturecol[dc_x]) - 3); col = (column_t *)((UINT8 *)R_GetColumn(texnum,maskedtexturecol[dc_x]) - 3);
// guess what I just fixed? -monster psychic cat
dc_colormap = colormaps;
// SoM: New code does not rely on R_DrawColumnShadowed_8 which // SoM: New code does not rely on R_DrawColumnShadowed_8 which
// will (hopefully) put less strain on the stack. // will (hopefully) put less strain on the stack.
if (dc_numlights) if (dc_numlights)