9#include <opencv2/core.hpp>
38 OBJWriter(filesystem::path outputPath, ITKMesh::Pointer mesh);
42 filesystem::path outputPath,
43 ITKMesh::Pointer mesh,
54 void setPath(
const filesystem::path& path);
std::shared_ptr< UVMap > Pointer
Write an ITKMesh to an OBJ file.
void setUVMap(UVMap::Pointer uvMap)
Set the input UV Map.
OBJWriter(filesystem::path outputPath, ITKMesh::Pointer mesh, UVMap::Pointer uvMap, cv::Mat uvImg)
Constructor with output path and textured mesh information.
std::map< std::uint32_t, cv::Vec3i > pointLinks_
void setTexture(cv::Mat uvImg)
Set the input texture image.
void write_texture_coordinates_()
void setPath(const filesystem::path &path)
Set the output path.
filesystem::path outputPath_
void write()
Write the OBJ to disk.
std::ofstream outputMesh_
OBJWriter()=default
Default constructor.
void setMesh(ITKMesh::Pointer mesh)
Set the input mesh.
OBJWriter(filesystem::path outputPath, ITKMesh::Pointer mesh)
Constructor with output path and input mesh.
void setTextureFormat(std::string fmt)
Set the texture image format.