Optimizing GLB Assets for Unity glTFast

Match GLB compression to Unity glTFast's installed decoder packages, reduce transfer and texture memory, and verify the result in a player build.

Unity glTFast is designed for efficient import, but a compressed GLB is only valid for the project when the matching optional packages are installed. OptimizeGLB should produce the asset contract that the player actually supports: core textures by default, Draco or KTX2 only when those dependencies are part of every target build.

Scope: This guide covers download bytes, texture dimensions, geometry density, duplicate data, codec requirements, and re-optimizing exported GLBs. It does not claim to fix Unity shader variants, disposal bugs, platform file access, or render-pipeline material conversion.

Asset decision path

Optimize the file for the runtime you actually ship

  1. 01

    Source pressure

    Download time, embedded texture memory, dense geometry

  2. 02

    OptimizeGLB decision

    Match the GLB extensions to installed Unity packages

  3. 03

    Unity glTFast handoff

    A player-tested asset with a known memory budget

Encoded size, decode cost, and runtime complexity are separate measurements. A codec is useful only when the complete handoff improves.

The same source model may need different outputs for a browser, a mobile player, and an editor import pipeline.

What teams actually run into

These are primary reports from framework users, filtered to symptoms that can be changed at the asset layer. Each response is intentionally narrower than the original runtime problem.

01

Downloading the GLB dominates runtime import

A glTFast issue reports that roughly 90% of import time was spent downloading the model and asks whether an extra ZIP layer would help. glTF already has more useful controls: geometry compression, texture conversion, and removing unused data.

OptimizeGLB response: Prune and deduplicate the GLB, cap textures, then enable Draco only after Draco for Unity is installed in every target. Measure the resulting GLB directly instead of wrapping an unoptimized asset in another archive.

glTFast issue #219 — a runtime load where network transfer accounted for most of the delay

02

Embedded 4K textures produce excessive Android memory use

A glTFast report shows editor-imported GLBs with large embedded textures consuming unexpectedly high memory and crashing on Android-class hardware. The runtime format can change, but decoded pixel count remains a hard cost.

OptimizeGLB response: Create a mobile delivery GLB with 1024- or 2048-pixel texture caps based on visual need. Use KTX2 only after KTX for Unity is installed and tested on the target; otherwise keep JPEG/PNG and rely on the lower dimensions.

Boundary: OptimizeGLB reduces the source workload. Unity's platform texture import and runtime allocation behavior still needs player profiling.

glTFast issue #552 — embedded texture memory pressure in Android builds

03

A runtime-exported GLB is larger than the input

One glTFast report describes an exported GLB that became larger and did not show the expected compression benefit. Export is a separate authoring step; its output should be measured like any other source asset.

OptimizeGLB response: Open the exported GLB in OptimizeGLB, establish a cleanup-only control, then add texture and geometry changes deliberately. Validate and test the optimized copy rather than assuming the Unity export settings produced a delivery-ready file.

glTFast issue #746 — a runtime export reported as invalid and larger than its source

Choose the output by compatibility, not fashion

Start with a control that uses the fewest optional extensions. Add a codec only when its measured benefit is worth the decoder and version requirement it creates.

Scroll horizontally to compare →

DecisionOptimizeGLB outputWhy
Portable baselineJPEG/PNG textures, pruning and deduplication; Draco, KTX2, and simplification offUses the core image path and provides a clean package check.
Smaller geometry transferEnable Draco only with Draco for Unity installed and built for every targetA required glTF extension has no uncompressed fallback inside the file.
GPU-oriented texturesUse KTX2 only with KTX for Unity and platform validationThe optional package and target transcoder are part of the asset contract.
Avoid WebP as the defaultPrefer JPEG/PNG or a proven KTX2 setupCurrent glTFast releases explicitly report unsupported WebP without a custom add-on.
Lower runtime geometryCreate a separate simplified GLB and inspect skins, morph targets, and silhouettesDraco reduces storage and transfer; simplification reduces triangle count.

A release workflow for Unity glTFast

Change one expensive dimension at a time. That makes a failed import or visual regression attributable to a decision instead of an opaque preset.

  1. 01

    Record the package and platform floor

    Pin the Unity glTFast version and note whether Draco for Unity and KTX for Unity are present in every player target.

  2. 02

    Build the portable baseline

    Use core textures with cleanup only. Import it through the same runtime or Editor path used by the product.

  3. 03

    Reduce decoded cost before adding codecs

    Cap oversized textures and simplify only a separate candidate. These controls reduce real resource demand even when compression formats change across platforms.

  4. 04

    Add one optional package contract

    Enable Draco or KTX2, not both at once, and test a clean player build on each target architecture.

  5. 05

    Measure download, import, memory, and frame time independently

    A smaller GLB can still add decode work, and a successful import can still exceed the runtime budget.

The useful boundary

For Unity glTFast, compatibility is a package manifest decision expressed in the asset. OptimizeGLB is valuable when it produces a GLB that matches that manifest—and when it reduces texture dimensions or triangle count instead of relying on encoded size alone.

Documentation and primary reports

Official documentation establishes support. Issue trackers and framework forums show the failure modes teams encounter in real projects. These links are the basis for the recommendations above.

Official documentation

Field reports

Build the delivery asset

Start with the compatible control, then compare one codec or fidelity change at a time.

Open OptimizeGLB