Foundation
Loading...
Searching...
No Matches
Namespaces | Macros | Functions | Variables
Mesh.cpp File Reference
#include "Mesh.hpp"
#include <Core/DefaultAllocator.hpp>
#include <Math/Math.hpp>
#include <Native/Filesystem.hpp>
#include <meshoptimizer.h>
#include <fast_obj.h>

Namespaces

namespace  ModelViewer
 ModelViewer implementation.
 

Macros

#define FAST_OBJ_IMPLEMENTATION
 

Functions

static voidModelViewer::meshoptAlloc (size_t size)
 
static void ModelViewer::meshoptFree (void *ptr)
 
template<typename Vertex , typename Index >
void ModelViewer::optimizeVertexIndex (Vector< Vertex > &vertices, Vector< Index > &indices)
 
float ModelViewer::meshGenerateLod (Vector< MeshIndex > &outIndices, Span< const MeshVertex > vertices, Span< const MeshIndex > indices, const float lodScale)
 Generate a simplified LOD mesh index buffer from the input mesh.
 
void ModelViewer::meshBuildMeshlets (Vector< MeshMeshlet > &outMeshlet, Vector< MeshIndex > &outMeshletVertices, Vector< MeshMicroIndex > &outMeshletTriangles, Span< const MeshVertex > vertices, Span< const MeshIndex > indices)
 Build meshlets from a mesh.
 
void ModelViewer::meshLoadObjFile (Vector< MeshVertex > &outVertex, Vector< MeshIndex > &outIndex, const Native::Path &path)
 Load a mesh from an OBJ file.
 

Variables

static DefaultAllocator ModelViewer::MeshoptAllocator
 

Macro Definition Documentation

◆ FAST_OBJ_IMPLEMENTATION

#define FAST_OBJ_IMPLEMENTATION