PhysicsBasedAnimationToolkit 0.0.10
Cross-platform C++20 library of algorithms and data structures commonly used in computer graphics research on physically-based simulation.
Loading...
Searching...
No Matches
Mesh.h File Reference

Mesh graph utilities. More...

Go to the source code of this file.

Namespaces

namespace  pbat
 The main namespace of the library.
 
namespace  pbat::graph
 

Enumerations

enum class  pbat::graph::EMeshDualGraphOptions : std::int32_t { VertexAdjacent = 0b001 , EdgeAdjacent = 0b010 , FaceAdjacent = 0b100 , All = 0b111 }
 Types of dual graph adjacencies.
 

Functions

template<class TDerivedE, class TDerivedW, common::CIndex TIndex = typename TDerivedE::Scalar, common::CArithmetic TScalar = typename TDerivedW::Scalar>
auto pbat::graph::MeshAdjacencyMatrix (Eigen::DenseBase< TDerivedE > const &E, Eigen::DenseBase< TDerivedW > const &w, TIndex nNodes=TIndex(-1), bool bVertexToElement=false, bool bHasDuplicates=false) -> Eigen::SparseMatrix< TScalar, Eigen::ColMajor, TIndex >
 Construct adjacency matrix from mesh.
 
template<class TDerivedE, common::CIndex TIndex = typename TDerivedE::Scalar>
auto pbat::graph::MeshAdjacencyMatrix (Eigen::DenseBase< TDerivedE > const &E, TIndex nNodes=TIndex(-1), bool bVertexToElement=false, bool bHasDuplicates=false) -> Eigen::SparseMatrix< TIndex, Eigen::ColMajor, TIndex >
 Construct adjacency matrix from mesh.
 
template<class TDerivedE, common::CIndex TIndex = typename TDerivedE::Scalar>
auto pbat::graph::MeshPrimalGraph (Eigen::DenseBase< TDerivedE > const &E, TIndex nNodes=TIndex(-1)) -> Eigen::SparseMatrix< TIndex, Eigen::ColMajor, TIndex >
 Construct primal graph of input mesh, i.e. the graph of adjacent vertices.
 
template<class TDerivedE, common::CIndex TIndex = typename TDerivedE::Scalar>
auto pbat::graph::MeshDualGraph (Eigen::DenseBase< TDerivedE > const &E, TIndex nNodes=TIndex(-1), EMeshDualGraphOptions opts=EMeshDualGraphOptions::All) -> Eigen::SparseMatrix< TIndex, Eigen::ColMajor, TIndex >
 Construct dual graph of input mesh, i.e. the graph of adjacent elements.
 

Detailed Description

Mesh graph utilities.

Author
Quoc-Minh Ton-That (tonth.nosp@m.at.q.nosp@m.uocmi.nosp@m.nh@g.nosp@m.mail..nosp@m.com)
Date
2025-02-10