|
Wildmeshing Toolkit
|
The map between an application's input and its output, read from the tracking file the application wrote (its history_output option), in the terms its files use. More...
#include <tracking.hpp>
Classes | |
| struct | Naming |
Public Member Functions | |
| Tracking (const history::SurfaceHistory &h, const SurfaceMapOptions &options={}) | |
| bool | output_by_vertices () const |
| Whether output points are named by vertex triplets (a tet output) rather than triangles. | |
| bool | input_by_vertices () const |
| std::vector< OutputPoint > | to_output (const std::vector< InputPoint > &points, MapWarnings *warnings=nullptr) const |
| std::vector< InputPoint > | to_input (const std::vector< OutputPoint > &points, MapWarnings *warnings=nullptr) const |
| std::vector< std::array< uint64_t, 3 > > | output_triangles () const |
| std::vector< std::array< uint64_t, 3 > > | input_triangles () const |
| const std::vector< std::array< uint64_t, 3 > > & | input_faces () const |
| The triangles of the input files, in order, as the history holds them. | |
| const SurfaceMap & | map () const |
Static Public Member Functions | |
| static Tracking | load (const std::string &path, const SurfaceMapOptions &options={}) |
| The tracking file an application wrote. | |
Static Private Member Functions | |
| static SurfacePoint | by_vertices (const Naming &naming, const std::vector< std::array< uint64_t, 3 > > &faces, const std::map< std::array< uint64_t, 3 >, uint64_t > &face_of, const std::array< uint64_t, 3 > &vertices, const Eigen::Vector3d &bary) |
| static std::map< std::array< uint64_t, 3 >, uint64_t > | faces_by_corners (const std::vector< std::array< uint64_t, 3 > > &faces, const std::vector< uint8_t > &alive) |
| The live faces by their sorted corners. | |
| static std::vector< std::array< uint64_t, 3 > > | triangles (const Naming &naming, const std::vector< std::array< uint64_t, 3 > > &faces, const std::vector< uint8_t > &alive) |
| The live faces of a side, by the naming's vertex ids if it has them. | |
Private Attributes | |
| SurfaceMap | m_map |
| Naming | m_output |
| Naming | m_input |
| std::map< std::array< uint64_t, 3 >, uint64_t > | m_output_face_of |
| std::map< std::array< uint64_t, 3 >, uint64_t > | m_input_face_of |
The map between an application's input and its output, read from the tracking file the application wrote (its history_output option), in the terms its files use.
Built from the history alone; see SurfaceMap for how. A point that cannot be mapped – an input triangle the application dropped, a tracked face the output does not have – comes back with no face (kNoId), and the warnings of the call count it. Mapping never changes the object: several threads may map through one at once.
|
staticprivate |
A point named by vertices, as a point of faces: the live face with those corners, the coordinates in its corner order. No face if none has them.
|
inline |
Whether input points are named by vertex triplets (a history that starts at a tet mesh's tracked surface) rather than triangles of the input files.
| std::vector< std::array< uint64_t, 3 > > wmtk::components::tracking::Tracking::input_triangles | ( | ) | const |
The input's tracked surface likewise: for a history from a tet mesh, its tracked faces by the mesh's vertex ids, the triplets an InputPoint may name; otherwise the triangles of the input files, by index.
| std::vector< std::array< uint64_t, 3 > > wmtk::components::tracking::Tracking::output_triangles | ( | ) | const |
The output's tracked surface: for a tet output, its tracked faces by the output's vertex ids, the triplets an OutputPoint may name; for a surface output, its triangles, by index.
| std::vector< InputPoint > wmtk::components::tracking::Tracking::to_input | ( | const std::vector< OutputPoint > & | points, |
| MapWarnings * | warnings = nullptr |
||
| ) | const |
Output points to the input, the inverse map. A point named by vertices, on either side, may list the face's three vertices in any order, its barycentric coordinates following them.
| std::vector< OutputPoint > wmtk::components::tracking::Tracking::to_output | ( | const std::vector< InputPoint > & | points, |
| MapWarnings * | warnings = nullptr |
||
| ) | const |
Input points to the output. warnings, if given, gets where this call found the map not a bijection (SurfaceMap::to_output).
|
private |
The output's vertex ids (empty for a surface output) and the input mesh's (empty for a history from files).
|
private |
The live faces of the last and the first state by their sorted corners, for the sides named by vertices.