$ show hhoppe/Mesh-processing-library
This repository is a comprehensive C++ library and suite of command-line tools for mesh processing research, originally developed by Hugues Hoppe at Microsoft Research. It implements algorithms from several SIGGRAPH papers (1992–2003), including surface reconstruction from unorganized points, mesh optimization, progressive meshes, view-dependent refinement, subdivision surface fitting, spherical parameterization, and gradient-domain video looping. The core library, libHh, provides a rich set of reusable data structures (e.g., fixed-size vectors, D-dimensional grids, half-edge meshes, progressive mesh representations) and algorithms (spatial search, least-squares solvers, multigrid, image filtering, parallel patterns). The tools are designed as stream-oriented filters that read from stdin and write to stdout, enabling Unix-style pipelines for complex processing workflows. An interactive OpenGL viewer (G3dOGL) supports real-time rendering with level-of-detail and geomorph transitions. The build system supports multiple platforms (Windows, Linux, macOS via Cygwin/MinGW) using GNU make and Visual Studio, with optional dependencies on libpng, libjpeg, and ffmpeg for media I/O. The codebase is well-tested with a comprehensive suite of unit and integration tests, and includes numerous demo scripts that reproduce published research results.
The LLM identified 5 files worth highlighting for reuse:
A template for fixed-size vectors (Vec<T,n>) with full arithmetic operators, SIMD alignment, structured bindings, and views (segment, head, tail). It is self-contained, header-only, and can be extracted into any C++ project requiring efficient geometric or linear algebra operations.
A D-dimensional grid template (Grid<D,T>) with configurable boundary rules (reflected, periodic, clamped, etc.), coordinate range iteration, and parallel_for_coords support. It is reusable for image processing, simulation, and any multi-dimensional data manipulation.
Provides a collection of filter kernels (impulse, box, triangle, Mitchell, Keys, spline, OMOMS, Lanczos, Hamming) and boundary rules for high-quality image resampling. Includes inverse convolution for optimal reconstruction. The design is policy-based and can be reused in any image scaling or signal processing application.
A set of linear least-squares solvers (sparse conjugate gradient, LU, Givens rotations, SVD, QR) with a unified interface. It handles both dense and sparse systems and is reusable for optimization problems in geometry processing, statistics, and machine learning.
Implements the progressive mesh data structure (base mesh + vertex split records) for continuous level-of-detail control. Includes geomorph construction and selective refinement. This is a foundational component for real-time rendering and mesh streaming, reusable in any LOD system.