Skip to content

Commit

Permalink
Test
Browse files Browse the repository at this point in the history
  • Loading branch information
viciious committed Jun 28, 2024
1 parent 42fdd26 commit d77312c
Showing 1 changed file with 6 additions and 12 deletions.
18 changes: 6 additions & 12 deletions r_phase1.c
Original file line number Diff line number Diff line change
Expand Up @@ -134,19 +134,13 @@ static boolean R_CheckBBox(rbspWork_t *rbsp, int16_t bspcoord_[4])
bspcoord[3] = bspcoord_[3] << 16;

// find the corners of the box that define the edges from current viewpoint
if(vd->viewx <= bspcoord[BOXLEFT])
boxx = 0;
else if(vd->viewx < bspcoord[BOXRIGHT])
boxx = 1;
else
boxx = 2;
boxx = 2;
boxx -= (vd->viewx < bspcoord[BOXRIGHT]);
boxx -= (vd->viewx <= bspcoord[BOXLEFT]);

if(vd->viewy >= bspcoord[BOXTOP])
boxy = 0;
else if(vd->viewy > bspcoord[BOXBOTTOM])
boxy = 1;
else
boxy = 2;
boxy = 2;
boxy -= (vd->viewy > bspcoord[BOXBOTTOM]);
boxy -= (vd->viewy >= bspcoord[BOXTOP]);

boxpos = (boxy << 2) + boxx;
if(boxpos == 5)
Expand Down

0 comments on commit d77312c

Please sign in to comment.