libigl v2.5.0
Loading...
Searching...
No Matches
slice_into.h
Go to the documentation of this file.
1// This file is part of libigl, a simple c++ geometry processing library.
2//
3// Copyright (C) 2013 Alec Jacobson <alecjacobson@gmail.com>
4//
5// This Source Code Form is subject to the terms of the Mozilla Public License
6// v. 2.0. If a copy of the MPL was not distributed with this file, You can
7// obtain one at http://mozilla.org/MPL/2.0/.
8#ifndef IGL_SLICE_INTO_H
9#define IGL_SLICE_INTO_H
10#include "igl_inline.h"
11
12#define EIGEN_YES_I_KNOW_SPARSE_MODULE_IS_NOT_STABLE_YET
13#include <Eigen/Dense>
14#include <Eigen/Sparse>
15namespace igl
16{
27 template <typename T, typename DerivedR, typename DerivedC>
29 const Eigen::SparseMatrix<T>& X,
30 const Eigen::MatrixBase<DerivedR> & R,
31 const Eigen::MatrixBase<DerivedC> & C,
32 Eigen::SparseMatrix<T>& Y);
39 template <typename MatX, typename MatY, typename DerivedR>
41 const MatX & X,
42 const Eigen::MatrixBase<DerivedR> & R,
43 const int dim,
44 MatY& Y);
50 template <typename DerivedX, typename DerivedY, typename DerivedR, typename DerivedC>
52 const Eigen::MatrixBase<DerivedX> & X,
53 const Eigen::MatrixBase<DerivedR> & R,
54 const Eigen::MatrixBase<DerivedC> & C,
55 Eigen::PlainObjectBase<DerivedY> & Y);
58 template <typename DerivedX, typename DerivedR, typename DerivedY>
60 const Eigen::MatrixBase<DerivedX>& X,
61 const Eigen::MatrixBase<DerivedR>& R,
62 Eigen::PlainObjectBase<DerivedY>& Y);
63}
64
65#ifndef IGL_STATIC_LIBRARY
66# include "slice_into.cpp"
67#endif
68
69#endif
#define IGL_INLINE
Definition igl_inline.h:15
Definition AABB.h:17
void slice_into(const Eigen::SparseMatrix< T > &X, const Eigen::MatrixBase< DerivedR > &R, const Eigen::MatrixBase< DerivedC > &C, Eigen::SparseMatrix< T > &Y)
Act like the matlab Y(row_indices,col_indices) = X.