Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7660 in orxonox.OLD for branches/cd/src/lib


Ignore:
Timestamp:
May 18, 2006, 12:15:48 AM (19 years ago)
Author:
patrick
Message:

cd: collision boxes getting better. but still not centered correctly

File:
1 edited

Legend:

Unmodified
Added
Removed
  • TabularUnified branches/cd/src/lib/collision_detection/obb_tree_node.cc

    r7658 r7660  
    131131    for(int j = 0; j < 3; ++j)
    132132    {
    133       PRINTF(2)("  vertex[%i]: %f, %f, %f\n", j, modelInf.pVertices[modelInf.pTriangles[triangleIndexes[i]].indexToVertices[j]]);
     133      PRINTF(2)("  vertex[%i]: %f, %f, %f\n", j, (&modelInf.pVertices[modelInf.pTriangles[triangleIndexes[i]].indexToVertices[j]])[0],
     134      (&modelInf.pVertices[modelInf.pTriangles[triangleIndexes[i]].indexToVertices[j]])[1],
     135      (&modelInf.pVertices[modelInf.pTriangles[triangleIndexes[i]].indexToVertices[j]])[2]);
    134136    }
    135137  }
     
    231233  }
    232234  //box.center = center;
     235  //FIXME setting center to 0,0,0
    233236  box.center = Vector();
    234237
     
    281284  box.axis[2] = axis[2];
    282285
    283 //   box.axis[0] = Vector(1,0,0);
    284 //   box.axis[1] = Vector(0,1,0);
    285 //   box.axis[2] = Vector(0,0,1);
     286  box.axis[0] = Vector(1,0,0);
     287  box.axis[1] = Vector(0,1,0);
     288  box.axis[2] = Vector(0,0,1);
    286289
    287290  PRINTF(3)("Eigenvectors:\n");
     
    391394
    392395  // FIXME: += anstatt -= ????????? verwirr
    393   box.center.x -= centerOffset[0];
    394   box.center.y -= centerOffset[1];
    395   box.center.z -= centerOffset[2];
     396  box.center.x += centerOffset[0];
     397  box.center.y += centerOffset[1];
     398  box.center.z += centerOffset[2];
    396399
    397400  PRINTF(3)("\n");
Note: See TracChangeset for help on using the changeset viewer.