mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-01-17 22:50:51 +00:00
Revert an optimization that impacts legibility more than performance.
This commit is contained in:
parent
7813b9c1b7
commit
8afd4a870e
1 changed files with 12 additions and 24 deletions
|
@ -233,40 +233,28 @@ set_vertex (struct box_def *box, int face, int ind, vec3_t v)
|
|||
VectorAdd (v, r_refdef.vieworg, box->face[face].poly.verts[ind]);
|
||||
switch (face) {
|
||||
case 0:
|
||||
box->face[face].poly.verts[ind][3] = (1024 - v[1] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][4] = (1024 - v[2] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][3] = (1024 - v[1] + 4) / BOX_WIDTH;
|
||||
box->face[face].poly.verts[ind][4] = (1024 - v[2] + 4) / BOX_WIDTH;
|
||||
break;
|
||||
case 1:
|
||||
box->face[face].poly.verts[ind][3] = (1024 + v[0] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][4] = (1024 - v[2] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][3] = (1024 + v[0] + 4) / BOX_WIDTH;
|
||||
box->face[face].poly.verts[ind][4] = (1024 - v[2] + 4) / BOX_WIDTH;
|
||||
break;
|
||||
case 2:
|
||||
box->face[face].poly.verts[ind][3] = (1024 + v[0] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][4] = (1024 + v[1] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][3] = (1024 + v[0] + 4) / BOX_WIDTH;
|
||||
box->face[face].poly.verts[ind][4] = (1024 + v[1] + 4) / BOX_WIDTH;
|
||||
break;
|
||||
case 3:
|
||||
box->face[face].poly.verts[ind][3] = (1024 + v[1] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][4] = (1024 - v[2] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][3] = (1024 + v[1] + 4) / BOX_WIDTH;
|
||||
box->face[face].poly.verts[ind][4] = (1024 - v[2] + 4) / BOX_WIDTH;
|
||||
break;
|
||||
case 4:
|
||||
box->face[face].poly.verts[ind][3] = (1024 - v[0] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][4] = (1024 - v[2] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][3] = (1024 - v[0] + 4) / BOX_WIDTH;
|
||||
box->face[face].poly.verts[ind][4] = (1024 - v[2] + 4) / BOX_WIDTH;
|
||||
break;
|
||||
case 5:
|
||||
box->face[face].poly.verts[ind][3] = (1024 + v[0] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][4] = (1024 - v[1] + 4) *
|
||||
(1.0 / BOX_WIDTH);
|
||||
box->face[face].poly.verts[ind][3] = (1024 + v[0] + 4) / BOX_WIDTH;
|
||||
box->face[face].poly.verts[ind][4] = (1024 - v[1] + 4) / BOX_WIDTH;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue