Browse Source

comparison functor of priority queue is required to represent a strict ordering

Nico Schertler 6 năm trước cách đây
mục cha
commit
9621a87edd
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      include/igl/knn.cpp

+ 1 - 1
include/igl/knn.cpp

@@ -68,7 +68,7 @@ namespace igl {
                                              CN.row(right-n),
                                              W(right-n));
         }
-        return leftdistance >= rightdistance;
+        return leftdistance > rightdistance;
       };
       
       std::priority_queue<IndexType, std::vector<IndexType>,