mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-23 12:52:46 +00:00
Properly terminate each fisheye quad strip.
The horizontal quad strips need to be rendered individually rather than as one single strip. The latter results in ugly triangles crossing the screen.
This commit is contained in:
parent
b9d21cbe9a
commit
47e55fe1c6
1 changed files with 2 additions and 3 deletions
|
@ -898,9 +898,8 @@ R_InitFishEye (void)
|
||||||
|
|
||||||
qfglEnable (GL_TEXTURE_CUBE_MAP_ARB);
|
qfglEnable (GL_TEXTURE_CUBE_MAP_ARB);
|
||||||
qfglBindTexture (GL_TEXTURE_CUBE_MAP_ARB, cube_map_tex);
|
qfglBindTexture (GL_TEXTURE_CUBE_MAP_ARB, cube_map_tex);
|
||||||
qfglBegin (GL_QUAD_STRIP);
|
|
||||||
|
|
||||||
for (y = 0; y < gl_cube_map_size; y += gl_cube_map_step) {
|
for (y = 0; y < gl_cube_map_size; y += gl_cube_map_step) {
|
||||||
|
qfglBegin (GL_QUAD_STRIP);
|
||||||
for (x = 0; x <= gl_cube_map_size; x += gl_cube_map_step) { // quad_strip, X should be inclusive
|
for (x = 0; x <= gl_cube_map_size; x += gl_cube_map_step) { // quad_strip, X should be inclusive
|
||||||
struct xyz *v = &FisheyeLookupTbl[x / gl_cube_map_step]
|
struct xyz *v = &FisheyeLookupTbl[x / gl_cube_map_step]
|
||||||
[y / gl_cube_map_step + 1];
|
[y / gl_cube_map_step + 1];
|
||||||
|
@ -910,8 +909,8 @@ R_InitFishEye (void)
|
||||||
qfglTexCoord3f (v->x, v->y, v->z);
|
qfglTexCoord3f (v->x, v->y, v->z);
|
||||||
qfglVertex2i (x, y);
|
qfglVertex2i (x, y);
|
||||||
}
|
}
|
||||||
|
qfglEnd ();
|
||||||
}
|
}
|
||||||
qfglEnd ();
|
|
||||||
qfglDisable (GL_TEXTURE_CUBE_MAP_ARB);
|
qfglDisable (GL_TEXTURE_CUBE_MAP_ARB);
|
||||||
qfglEnable (GL_DEPTH_TEST);
|
qfglEnable (GL_DEPTH_TEST);
|
||||||
qfglEndList ();
|
qfglEndList ();
|
||||||
|
|
Loading…
Reference in a new issue