#define VERBOSE 1 /* tell me what happens */
#define DEPTH 15.0f
-#define EPS 1e-6f
typedef void (GLAPIENTRYP GLFOGCOORDFEXTPROC) (GLfloat f);
typedef void (GLAPIENTRYP GLFOGCOORDPOINTEREXTPROC) (GLenum, GLsizei, const GLvoid *);
static GLint fogMode;
static GLboolean fogCoord;
static GLfloat fogDensity = 0.75;
-static GLfloat fogStart = 0.0, fogEnd = 1.0;
+static GLfloat fogStart = 1.0, fogEnd = 40.0;
static GLfloat fogColor[4] = {0.6f, 0.3f, 0.0f, 1.0f};
fogMode = SetFogMode(fogMode + 1);
break;
case '+':
- if (fogDensity < 1.0 - EPS) {
+ if (fogDensity < 1.0) {
fogDensity += 0.05;
}
SetFogMode(fogMode);
break;
case '-':
- if (fogDensity > EPS) {
+ if (fogDensity > 0.0) {
fogDensity -= 0.05;
}
SetFogMode(fogMode);
break;
case 's':
- if (fogStart > EPS) {
- fogStart -= 0.1;
+ if (fogStart > 0.0) {
+ fogStart -= 1.0;
}
SetFogMode(fogMode);
break;
case 'S':
- if (fogStart < fogEnd - EPS) {
- fogStart += 0.1;
+ if (fogStart < fogEnd) {
+ fogStart += 1.0;
}
SetFogMode(fogMode);
break;
case 'e':
- if (fogEnd > fogStart + EPS) {
- fogEnd -= 0.1;
+ if (fogEnd > fogStart) {
+ fogEnd -= 1.0;
}
SetFogMode(fogMode);
break;
case 'E':
- if (fogEnd < 1.0 - EPS) {
- fogEnd += 0.1;
+ if (fogEnd < 100.0) {
+ fogEnd += 1.0;
}
SetFogMode(fogMode);
break;
ASSERT_OUTSIDE_BEGIN_END_AND_FLUSH(ctx);
if (MESA_VERBOSE & VERBOSE_API)
- _mesa_debug(ctx, "glFrustum(%f, %f, %f, %f, %f, %f)\n",
+ _mesa_debug(ctx, "glOrtho(%f, %f, %f, %f, %f, %f)\n",
left, right, bottom, top, nearval, farval);
if (left == right ||