1#ifndef GENERATOR_AXISSWAPMESH_HPP
2#define GENERATOR_AXISSWAPMESH_HPP
12template<
typename mesh_t>
33 return triangles_.done();
58 : transform_mesh_{
std::move(mesh),
61 vertex.position = gml::dvec3{vertex.position[
static_cast<int>(
x)],
62 vertex.position[
static_cast<int>(
y)],
63 vertex.position[
static_cast<int>(
z)]};
64 vertex.normal = gml::dvec3{vertex.normal[
static_cast<int>(
x)],
65 vertex.normal[
static_cast<int>(
y)],
66 vertex.normal[
static_cast<int>(
z)]};
87 return transform_mesh_.vertices();
94template<
typename mesh_t>
triangle_t generate() const
bool done() const noexcept
Swaps any number of axis in the mesh.
vertices_t vertices() const noexcept
axis_swap_mesh_t(mesh_t mesh, axis_t x, axis_t y, axis_t z)
typename impl_t::vertices_t vertices_t
triangles_t triangles() const noexcept
gml::ivec3 vertices
Zero based indices of the triangle vertices in counterclockwise order.
axis_swap_mesh_t< mesh_t > axis_swap_mesh(mesh_t mesh, axis_t x, axis_t y, axis_t z)