blob: b0a66ef08714ea8dd4ae5be49d1d204aba833335 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
// This file is part of libigl, a simple c++ geometry processing library.
//
// Copyright (C) 2017 Alec Jacobson <alecjacobson@gmail.com>
//
// This Source Code Form is subject to the terms of the Mozilla Public License
// v. 2.0. If a copy of the MPL was not distributed with this file, You can
// obtain one at http://mozilla.org/MPL/2.0/.
#ifndef IGL_ORIENTED_FACETS_H
#define IGL_ORIENTED_FACETS_H
#include "igl_inline.h"
#include <Eigen/Dense>
namespace igl
{
// ORIENTED_FACETS Determines all "directed
// [facets](https://en.wikipedia.org/wiki/Simplex#Elements)" of a given set
// of simplicial elements. For a manifold triangle mesh, this computes all
// half-edges. For a manifold tetrahedral mesh, this computes all half-faces.
//
// Inputs:
// F #F by simplex_size list of simplices
// Outputs:
// E #E by simplex_size-1 list of facets
//
// Note: this is not the same as igl::edges because this includes every
// directed edge including repeats (meaning interior edges on a surface will
// show up once for each direction and non-manifold edges may appear more than
// once for each direction).
//
// Note: This replaces the deprecated `all_edges` function
template <typename DerivedF, typename DerivedE>
IGL_INLINE void oriented_facets(
const Eigen::MatrixBase<DerivedF> & F,
Eigen::PlainObjectBase<DerivedE> & E);
}
#ifndef IGL_STATIC_LIBRARY
# include "oriented_facets.cpp"
#endif
#endif
|