fix func_wrap argument type

Former-commit-id: c0340bec3d
This commit is contained in:
unclejimbo
2018-10-11 21:35:10 +08:00
parent 015063a627
commit 3ef2e16408
+2 -1
View File
@@ -44,13 +44,14 @@ inline void igl::redux(
const Func & func,
Eigen::PlainObjectBase<DerivedB> & B)
{
typedef typename Eigen::SparseMatrix<AType>::StorageIndex Index;
assert((dim == 1 || dim == 2) && "dim must be 2 or 1");
// Get size of input
int m = A.rows();
int n = A.cols();
// resize output
B = DerivedB::Zero(dim==1?n:m);
const auto func_wrap = [&func,&B,&dim](const int i, const int j, const int v)
const auto func_wrap = [&func,&B,&dim](const Index i, const Index j, const AType v)
{
if(dim == 1)
{