Ejemplo n.º 1
0
int main(int argc, char* argv[]) {
    convMatrix("mat_1_b", 1, 1000);
    convMatrix("mat_1_w", 784, 1000);
    convMatrix("mat_2_b", 1, 500);
    convMatrix("mat_2_w", 1000, 500);
    convMatrix("mat_3_b", 1, 300);
    convMatrix("mat_3_w", 500, 300);
    convMatrix("mat_4_b", 1, 50);
    convMatrix("mat_4_w", 300, 50);
    convMatrix("SemPtr", 10, 50);
    convMatrix("samplesPtr", 100, 784);
    return 0;
}
Ejemplo n.º 2
0
int collideBoxBox(const Eigen::Vector3d& size0, const Eigen::Isometry3d& T0,
                  const Eigen::Vector3d& size1, const Eigen::Isometry3d& T1,
                  std::vector<Contact>* result)
{
  dVector3 halfSize0;
  dVector3 halfSize1;

  convVector(0.5 * size0, halfSize0);
  convVector(0.5 * size1, halfSize1);

  dMatrix3 R0, R1;

  convMatrix(T0, R0);
  convMatrix(T1, R1);

  dVector3 p0;
  dVector3 p1;

  convVector(T0.translation(), p0);
  convVector(T1.translation(), p1);

  return dBoxBox(p1, R1, halfSize1, p0, R0, halfSize0, *result);
}
Ejemplo n.º 3
0
int collideBoxBox(CollisionObject* o1, CollisionObject* o2,
                  const Eigen::Vector3d& size0, const Eigen::Isometry3d& T0,
                  const Eigen::Vector3d& size1, const Eigen::Isometry3d& T1,
                  CollisionResult& result)
{
  dVector3 halfSize0;
  dVector3 halfSize1;

  convVector(0.5 * size0, halfSize0);
  convVector(0.5 * size1, halfSize1);

  dMatrix3 R0, R1;

  convMatrix(T0, R0);
  convMatrix(T1, R1);

  dVector3 p0;
  dVector3 p1;

  convVector(T0.translation(), p0);
  convVector(T1.translation(), p1);

  return dBoxBox(o1, o2, p1, R1, halfSize1, p0, R0, halfSize0, result);
}