MVE - Multi-View Environment mve-devel
Loading...
Searching...
No Matches
Namespaces | Functions
mesh_tools.cc File Reference
#include <vector>
#include <stdexcept>
#include <algorithm>
#include <list>
#include <limits>
#include <fstream>
#include <cerrno>
#include <cstring>
#include "math/algo.h"
#include "math/vector.h"
#include "mve/mesh_info.h"
#include "mve/mesh_tools.h"
Include dependency graph for mesh_tools.cc:

Go to the source code of this file.

Namespaces

namespace  mve
 Multi-View Environment library.
 
namespace  mve::geom
 Geometric tools, loading and processing functions.
 

Functions

void mve::geom::mesh_components (TriangleMesh::Ptr mesh, std::size_t vertex_threshold)
 Discards isolated components with a vertex count below a threshold.
 
std::size_t mve::geom::mesh_delete_unreferenced (TriangleMesh::Ptr mesh)
 Cleans unreferenced vertices from the mesh.
 
void mve::geom::mesh_find_aabb (TriangleMesh::ConstPtr mesh, math::Vec3f &aabb_min, math::Vec3f &aabb_max)
 Calculates the mesh axis-aligned bounding box (AABB).
 
void mve::geom::mesh_invert_faces (TriangleMesh::Ptr mesh)
 Inverts the orientation of all faces in the mesh.
 
void mve::geom::mesh_merge (TriangleMesh::ConstPtr mesh1, TriangleMesh::Ptr mesh2)
 Merges the first given mesh with the second one, modifying the second one.
 
void mve::geom::mesh_scale_and_center (TriangleMesh::Ptr mesh, bool scale=true, bool center=true)
 Scales the mesh such that it fits into a cube with length 1 and centers the mesh in the coordinate origin.
 
void mve::geom::mesh_transform (TriangleMesh::Ptr mesh, math::Matrix3f const &rot)
 Transforms the vertices and normals of the mesh using the specified rotation matrix.
 
void mve::geom::mesh_transform (TriangleMesh::Ptr mesh, math::Matrix4f const &trans)
 Transforms the vertices of the mesh using the specified transformation matrix and rotates the normals of the mesh using the roation matrix of the transformation.