Browse Source

boring base case

Former-commit-id: d5d2340255130ce388070ca070603c5c93edfacf
Alec Jacobson 9 years ago
parent
commit
8160250468
1 changed files with 4 additions and 0 deletions
  1. 4 0
      include/igl/AABB.h

+ 4 - 0
include/igl/AABB.h

@@ -398,6 +398,10 @@ inline void igl::AABB<DerivedV,DIM>::init(
 {
   using namespace Eigen;
   using namespace std;
+  if(V.size() == 0 || Ele.size() == 0 || I.size() == 0)
+  {
+    return;
+  }
   assert(DIM == V.cols() && "V.cols() should matched declared dimension");
   //const Scalar inf = numeric_limits<Scalar>::infinity();
   m_box = AlignedBox<Scalar,DIM>();