wined3d: Use INFINITY.
This commit is contained in:
parent
cb8af0152c
commit
a6510b3fbc
|
@ -1049,7 +1049,7 @@ void state_fogstartend(struct wined3d_context *context, const struct wined3d_sta
|
|||
fogend = tmpvalue.f;
|
||||
/* In GL, fogstart == fogend disables fog, in D3D everything's fogged.*/
|
||||
if(fogstart == fogend) {
|
||||
fogstart = -1.0f / 0.0f;
|
||||
fogstart = -INFINITY;
|
||||
fogend = 0.0f;
|
||||
}
|
||||
break;
|
||||
|
|
|
@ -199,7 +199,7 @@ static inline float float_16_to_32(const unsigned short *in) {
|
|||
} else if(e < 31) {
|
||||
return sgn * powf(2, (float)e - 15.0f) * (1.0f + ((float)m / 1024.0f));
|
||||
} else {
|
||||
if(m == 0) return sgn / 0.0f; /* +INF / -INF */
|
||||
if(m == 0) return sgn * INFINITY;
|
||||
else return NAN;
|
||||
}
|
||||
}
|
||||
|
@ -221,7 +221,7 @@ static inline float float_24_to_32(DWORD in)
|
|||
}
|
||||
else
|
||||
{
|
||||
if (m == 0) return sgn / 0.0f; /* +INF / -INF */
|
||||
if (m == 0) return sgn * INFINITY;
|
||||
else return NAN;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue