Browse Source

missing sort header

Former-commit-id: 4ccac53005994f695eea123cd85e92be27caecb2
Alec Jacobson 9 years ago
parent
commit
58f09a919c
1 changed files with 9 additions and 0 deletions
  1. 9 0
      include/igl/sort.h

+ 9 - 0
include/igl/sort.h

@@ -53,6 +53,15 @@ namespace igl
     const bool ascending,
     Eigen::PlainObjectBase<DerivedY>& Y,
     Eigen::PlainObjectBase<DerivedIX>& IX);
+  // Special case if size(X,dim) == 3
+  template <typename DerivedX, typename DerivedY, typename DerivedIX>
+  IGL_INLINE void sort3(
+    const Eigen::PlainObjectBase<DerivedX>& X,
+    const int dim,
+    const bool ascending,
+    Eigen::PlainObjectBase<DerivedY>& Y,
+    Eigen::PlainObjectBase<DerivedIX>& IX);
+
 
   // Act like matlab's [Y,I] = SORT(X) for std library vectors
   // Templates: