v0.12
This release contains a few improvements for various algorithms, introduces support for triangle strips with degenerate triangles and adds gltfpack (alpha).
Interface changes:
meshopt_stripify
andmeshopt_unstripify
now require an extra argument,restart_index
Improvements:
- Improve
meshopt_simplifySloppy
performance by up to 10% by using three-point interpolation search - Improve results of
meshopt_optimizeVertexCache
by up to 0.5% by using a new data set obtained with differential evolution meshopt_stripify
now supports stitching strips using degenerate triangles instead of restart indices; this typically results in a 10% larger index buffer compared to restart indices, but on some GPUs it can be substantially faster to render
gltfpack:
This release introduces an alpha vesion of gltfpack. gltfpack is a command-line tool that converts .obj or .gltf files to glTF files that are optimized for render performance and transmission time. gltfpack merges meshes and materials to reduce draw call count, merges buffers to reduce draw setup cost, quantizes vertex attributes to reduce GPU memory footprint, optimizes vertex and index data for more efficient GPU rendering, resamples and quantizes animation data to reduce memory footprint, and can optionally compress the vertex/index/animation buffers in the output using meshoptimizer codecs to further reduce the file size.
The resulting files rely on two not-yet-standardized extensions; when compression is not used, the resulting files can be loaded using three.js (r107+) and Babylon.js (4.1+) glTF loaders. Loading compressed files requires integrating JavaScript decoders (js/meshopt_decoder.js
); demo/GLTFLoader.js
contains a custom version of three.js loader that can be used to load them.