Skip to content

glTFast 3.0.0-preview

Pre-release
Pre-release
Compare
Choose a tag to compare
@atteneder atteneder released this 01 Feb 01:13
· 1190 commits to main since this release

Note: this is a preview release. Testing and feedback is highly appreciated.

This is a new major release, since the API chanced due to switching from coroutines to async.
However, the performance increases resulting from process optimizations that followed alone would justify a major release. Have a look:

The performance benchmark introduced in 2.6.0 allows comparing changes. The tests consisted of loading every glTF from the glTF-Sample-Model collection, which has a wide range of models (no KTX though).

On average models load ~35% faster.

smooth

If you look at individual tests (sorted from slowest to fastest in 2.6.0), you see that the majority got faster, some didn't change much and only a few regressed. The worst case got 25% slower and the best got 82% faster.

smooth_times

This regression is mostly because of a much more stable, smooth frame rate. Look at how the average maximum frame time decreased considerably while the average minimum and average(across tests) average(across frames within a test) increased. This means that that work is spread more evenly across frames, sometimes increasing the overall loading time slightly. The goal is maximum staying below 16.6 ms (for 60 fps), so there's still some work to do.

smooth_frames

But glTFast can also load as fast as possible, regardless of frame times. In this case the loading times also improved:

fast_times

Changed

  • Converted API and internals to async/await. This is more convenient in some cases and eases future optimizations.
  • Performance improvements
    • Non-trivial JSONs are parsed in a thread now
    • More consistent frame rates due to task duration estimation in various places along the loading code
    • Embed base 64 buffers are decoded in a thread now
    • Less memory usage (and likely faster) du to Jpeg and PNG textures being loaded non-readable (if possible)