]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
Do a little precalculaiton when traversing BIH
authoruis <uis9936@gmail.com>
Fri, 10 May 2024 22:32:57 +0000 (01:32 +0300)
committeruis <uis9936@gmail.com>
Sat, 11 May 2024 03:08:58 +0000 (06:08 +0300)
model_brush.c

index 6233368ef1eb4ea95d24762ce314d08511c0c746..bd1ba3100a9c8b2364b7bcd0ae12d54fcfc3e6dd 100644 (file)
@@ -7002,26 +7002,115 @@ static void Mod_CollisionBIH_TraceLineShared(dp_model_t *model, const frameblend
                        d2 = node->backmax - nodeend[axis];
                        d3 = nodestart[axis] - node->frontmin;
                        d4 = nodeend[axis] - node->frontmin;
+                       f = 1.f / (nodeend[axis] - nodestart[axis]);
                        if (collision_bih_fullrecursion.integer)
                                d1 = d2 = d3 = d4 = 1; // force full recursion
                        switch((d1 < 0) | ((d2 < 0) << 1) | ((d3 < 0) << 2) | ((d4 < 0) << 3))
                        {
-                       case  0: /* >>>> */                     VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                      VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  1: /* <>>> */ f = d1 / (d1 - d2); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                      VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  2: /* ><>> */ f = d1 / (d1 - d2); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                      VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  3: /* <<>> */                                                                                                                                                                                                                      VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  4: /* >><> */                     VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  5: /* <><> */ f = d1 / (d1 - d2); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  6: /* ><<> */ f = d1 / (d1 - d2); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  7: /* <<<> */                                                                                                                                                                                                  f = d3 / (d3 - d4); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  8: /* >>>< */                     VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  9: /* <>>< */ f = d1 / (d1 - d2); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case 10: /* ><>< */ f = d1 / (d1 - d2); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case 11: /* <<>< */                                                                                                                                                                                                  f = d3 / (d3 - d4); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case 12: /* >><< */                     VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                                                                                                                                                                                                   break;
-                       case 13: /* <><< */ f = d1 / (d1 - d2); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                                                                                                                                                                                                   break;
-                       case 14: /* ><<< */ f = d1 / (d1 - d2); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                                                                                                                                                                                                   break;
-                       case 15: /* <<<< */                                                                                                                                                                                                                                                                                                                                                                                                   break;
+                       case  0: /* >>>> */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  1: /* <>>> */
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  2: /* ><>> */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  3: /* <<>> */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  4: /* >><> */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  5: /* <><> */
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  6: /* ><<> */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  7: /* <<<> */
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  8: /* >>>< */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  9: /* <>>< */
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case 10: /* ><>< */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case 11: /* <<>< */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case 12: /* >><< */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               break;
+                       case 13: /* <><< */
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               break;
+                       case 14: /* ><<< */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               break;
+                       case 15: /* <<<< */
+                               break;
                        }
                }
                else if (node->type == BIH_UNORDERED)
@@ -7159,24 +7248,113 @@ void Mod_CollisionBIH_TraceBrush(dp_model_t *model, const frameblend_t *frameble
                        d2 = node->backmax - nodeend[axis] - mins[axis];
                        d3 = nodestart[axis] - node->frontmin + maxs[axis];
                        d4 = nodeend[axis] - node->frontmin + maxs[axis];
+                       f = 1.f / (nodeend[axis] - nodestart[axis]);
                        switch((d1 < 0) | ((d2 < 0) << 1) | ((d3 < 0) << 2) | ((d4 < 0) << 3))
                        {
-                       case  0: /* >>>> */                     VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                      VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  1: /* <>>> */ f = d1 / (d1 - d2); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                      VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  2: /* ><>> */ f = d1 / (d1 - d2); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                      VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  3: /* <<>> */                                                                                                                                                                                                                      VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  4: /* >><> */                     VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  5: /* <><> */ f = d1 / (d1 - d2); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  6: /* ><<> */ f = d1 / (d1 - d2); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  7: /* <<<> */                                                                                                                                                                                                  f = d3 / (d3 - d4); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  8: /* >>>< */                     VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case  9: /* <>>< */ f = d1 / (d1 - d2); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case 10: /* ><>< */ f = d1 / (d1 - d2); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;  f = d3 / (d3 - d4); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case 11: /* <<>< */                                                                                                                                                                                                  f = d3 / (d3 - d4); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->front; break;
-                       case 12: /* >><< */                     VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                                                                                                                                                                                                   break;
-                       case 13: /* <><< */ f = d1 / (d1 - d2); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos]); VectorCopy(              nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                                                                                                                                                                                                   break;
-                       case 14: /* ><<< */ f = d1 / (d1 - d2); VectorCopy(nodestart,             nodestackline[nodestackpos]); VectorLerp(nodestart, f, nodeend, nodestackline[nodestackpos] + 3); nodestack[nodestackpos++] = node->back;                                                                                                                                                                                                   break;
-                       case 15: /* <<<< */                                                                                                                                                                                                                                                                                                                                                                                                   break;
+                       case  0: /* >>>> */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  1: /* <>>> */
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  2: /* ><>> */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  3: /* <<>> */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  4: /* >><> */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  5: /* <><> */
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  6: /* ><<> */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  7: /* <<<> */
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  8: /* >>>< */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case  9: /* <>>< */
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case 10: /* ><>< */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case 11: /* <<>< */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, -d3 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->front;
+                               break;
+                       case 12: /* >><< */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               break;
+                       case 13: /* <><< */
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos]);
+                               VectorCopy(nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               break;
+                       case 14: /* ><<< */
+                               VectorCopy(nodestart, nodestackline[nodestackpos]);
+                               VectorLerp(nodestart, d1 * f, nodeend, nodestackline[nodestackpos] + 3);
+                               nodestack[nodestackpos++] = node->back;
+                               break;
+                       case 15: /* <<<< */
+                               break;
                        }
                }
                else if (node->type == BIH_UNORDERED)