score
Home
Classes
Namespaces
Files
Loading...
Searching...
No Matches
VcgImporters.hpp
1
#pragma once
2
#include <Threedim/TinyObj.hpp>
3
4
#include <string_view>
5
6
namespace
Threedim
7
{
8
9
// vcglib bridges. Load a 3D file via vcg::tri::io::Importer<Mesh>::Open
10
// and convert the loaded mesh into the same flat float_vec + mesh record
11
// format that TinyObjFromFile / PlyFromFile produce, so downstream
12
// `sceneStateFromMeshes` (or GeometryLoader's `rebuild_geometry`)
13
// consumes them uniformly.
14
//
15
// Adds STL and OFF support (the two remaining generally-useful formats
16
// vcglib offers that we weren't already covering via tinyobj / miniply).
17
18
std::vector<Threedim::mesh> StlFromFile(
19
std::string_view filename, Threedim::float_vec& buffer);
20
21
std::vector<Threedim::mesh> OffFromFile(
22
std::string_view filename, Threedim::float_vec& buffer);
23
24
}