libigl v2.5.0
Loading...
Searching...
No Matches
marching_cubes.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) 2014 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_COPYLEFT_MARCHINGCUBES_H
9#define IGL_COPYLEFT_MARCHINGCUBES_H
10#include "../igl_inline.h"
11
12#include <Eigen/Core>
13namespace igl
14{
15 namespace copyleft
16 {
39 template <typename DerivedValues, typename DerivedPoints, typename DerivedVertices, typename DerivedFaces>
41 const Eigen::MatrixBase<DerivedValues> &values,
42 const Eigen::MatrixBase<DerivedPoints> &points,
43 const unsigned x_res,
44 const unsigned y_res,
45 const unsigned z_res,
46 const double isovalue,
47 Eigen::PlainObjectBase<DerivedVertices> &vertices,
48 Eigen::PlainObjectBase<DerivedFaces> &faces);
51 template <typename DerivedValues, typename DerivedPoints, typename DerivedVertices, typename DerivedFaces>
53 const Eigen::MatrixBase<DerivedValues> &values,
54 const Eigen::MatrixBase<DerivedPoints> &points,
55 const unsigned x_res,
56 const unsigned y_res,
57 const unsigned z_res,
58 Eigen::PlainObjectBase<DerivedVertices> &vertices,
59 Eigen::PlainObjectBase<DerivedFaces> &faces);
62 template <
63 typename DerivedValue,
64 typename DerivedPoint,
65 typename DerivedPoints,
66 typename DerivedVertices,
67 typename DerivedFaces>
69 const std::function< DerivedValue(const DerivedPoint & ) > & value_fun,
70 const Eigen::MatrixBase<DerivedPoints> &points,
71 const unsigned x_res,
72 const unsigned y_res,
73 const unsigned z_res,
74 const double isovalue,
75 Eigen::PlainObjectBase<DerivedVertices> &vertices,
76 Eigen::PlainObjectBase<DerivedFaces> &faces);
94 template <typename DerivedValues, typename DerivedPoints, typename DerivedVertices, typename DerivedIndices, typename DerivedFaces>
96 const Eigen::MatrixBase<DerivedValues> &values,
97 const Eigen::MatrixBase<DerivedPoints> &points,
98 const Eigen::MatrixBase<DerivedIndices> &indices,
99 const double isovalue,
100 Eigen::PlainObjectBase<DerivedVertices> &vertices,
101 Eigen::PlainObjectBase<DerivedFaces> &faces);
104 template <typename DerivedValues, typename DerivedPoints, typename DerivedVertices, typename DerivedIndices, typename DerivedFaces>
106 const Eigen::MatrixBase<DerivedValues> &values,
107 const Eigen::MatrixBase<DerivedPoints> &points,
108 const Eigen::MatrixBase<DerivedIndices> &indices,
109 Eigen::PlainObjectBase<DerivedVertices> &vertices,
110 Eigen::PlainObjectBase<DerivedFaces> &faces);
111 }
112}
113
114#ifndef IGL_STATIC_LIBRARY
115# include "marching_cubes.cpp"
116#endif
117
118#endif
#define IGL_INLINE
Definition igl_inline.h:15
void marching_cubes(const Eigen::MatrixBase< DerivedValues > &values, const Eigen::MatrixBase< DerivedPoints > &points, const unsigned x_res, const unsigned y_res, const unsigned z_res, const double isovalue, Eigen::PlainObjectBase< DerivedVertices > &vertices, Eigen::PlainObjectBase< DerivedFaces > &faces)
Performs marching cubes reconstruction on a grid defined by values, and points, and generates a mesh ...
Definition AABB.h:17