docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Features

    Workflows

    Runtime Editor (design-time)
    GameObject
    Import ✅️ ✅
    Export ¹☑️ ¹ ☑️
    Entities (see DOTS)
    Import ☑️ n/a
    Export n/a

    ¹: Experimental. Core features missing

    Core glTF™ features

    The glTF 2.0 specification is fully supported, with only a few minor remarks.

    Import Export
    Format
    glTF (.gltf) ✅ ✅
    glTF-Binary (.glb) ✅ ✅
    Buffer
    External URIs ✅ ✅
    GLB main buffer ✅ ✅
    Embed buffers or textures (base-64 encoded within JSON) ✅
    meshoptimizer compression (via package) ✅
    Basics
    Scenes ✅ ✅
    Node hierarchies ✅ ✅
    Cameras ✅ ✅
    Images
    PNG ✅ ✅
    Jpeg ✅ ✅
    KTX™ with Basis Universal compression (via KtxUnity) ✅
    Texture sampler
    Filtering ✅ with limitations ✅ with limitations
    Wrap modes ✅ ✅
    Materials Overview (see details)
    Universal Render Pipeline (URP) ✅ ☑️
    High Definition Render Pipeline (HDRP) ✅ ☑️
    Built-in Render Pipeline ✅ ☑️
    Topologies / Primitive Types
    TRIANGLES ✅ ✅
    POINTS ✅ ✅
    LINES ✅ ✅
    LINE_STRIP ✅ ✅
    ¹LINE_LOOP ✅ ✅
    TRIANGLE_STRIP
    TRIANGLE_FAN
    Quads n/a ✅ via triangulation
    Meshes
    Positions ✅ ✅
    Normals ✅ ✅
    Tangents ✅ ✅
    Texture coordinates / UV sets ✅ ?
    Three or more texture coordinates / UV sets ²☑️ ?
    Vertex colors ✅ ?
    Draco™ mesh compression (via DracoForUnity) ✅ ✅
    Implicit (no) indices ✅
    Per primitive material ✅ ✅
    Joints (up to 4 per vertex) ✅
    Weights (up to 4 per vertex) ✅
    Morph Targets / Blend Shapes
    Sparse accessors ³ ✅
    Skins ✅
    Animation
    via legacy Animation System ✅
    via Playable API (issue)
    via Mecanim (issue)

    ¹: Untested due to lack of demo files.

    ²: Up to eight UV sets can imported, but Unity glTFast shaders only support two (see issue).

    ³: Not on all accessor types; morph targets and vertex positions only

    Extensions

    Official Khronos® extensions

    Import Export
    Khronos
    KHR_draco_mesh_compression ✅ ✅
    KHR_materials_pbrSpecularGlossiness ✅
    KHR_materials_unlit ✅ ✅
    KHR_texture_transform ✅ ✅
    KHR_mesh_quantization ✅
    KHR_texture_basisu ✅
    KHR_lights_punctual ✅ ✅
    KHR_materials_clearcoat ✅ ✅
    KHR_materials_sheen ℹ️
    KHR_materials_transmission ℹ️
    KHR_materials_variants ✅
    KHR_materials_ior ℹ️
    KHR_materials_specular ℹ️
    KHR_materials_volume ℹ️
    KHR_xmp_json_ld ️
    Vendor
    ¹EXT_mesh_gpu_instancing ✅
    EXT_meshopt_compression ✅
    EXT_lights_image_based ℹ️

    ¹: Without support for custom vertex attributes (e.g. _ID)

    Not investigated yet:

    • AGI_articulations
    • AGI_stk_metadata
    • CESIUM_primitive_outline
    • MSFT_lod
    • MSFT_packing_normalRoughnessMetallic
    • MSFT_packing_occlusionRoughnessMetallic

    Will not become supported (reason in brackets):

    • KHR_xmp (archived; prefer KHR_xmp_json_ld)
    • KHR_techniques_webgl (archived)
    • ADOBE_materials_clearcoat_specular (prefer KHR_materials_clearcoat)
    • ADOBE_materials_thin_transparency (prefer KHR_materials_transmission)
    • EXT_texture_webp (prefer KTX/basisu)
    • FB_geometry_metadata (prefer KTX_xmp)
    • MSFT_texture_dds (prefer KTX/basisu)

    Custom extras and extensions

    Optional extras and extensions object properties are supported. glTFast uses Newtonsoft JSON parser to access these additional properties.

    See glTFast Add-on API for an example to import the extras property in a gltf asset.

    Materials Details

    Material Import

    Material Feature URP HDRP Built-In
    PBR¹ Metallic-Roughness ✅ ✅ ✅
    PBR¹ Specular-Glossiness ✅ ✅ ✅
    Unlit ✅ ✅ ✅
    Normal texture ✅ ✅ ✅
    Occlusion texture ✅ ✅ ✅
    Emission texture ✅ ✅ ✅
    Alpha modes OPAQUE/MASK/BLEND ✅ ✅ ✅
    Double sided / Two sided ✅ ✅ ✅
    Vertex colors ✅ ✅ ✅
    Multiple UV sets ✅² ✅² ✅²
    Texture Transform ✅ ✅ ✅
    Clear coat ☑️³ ✅ ⛔️
    Sheen ℹ️ ℹ️ ⛔️
    Transmission ☑️⁴ ☑️⁵ ☑️⁵
    Variants ✅ ✅ ✅
    IOR ℹ️ ℹ️ ⛔️
    Specular ℹ️ ℹ️ ⛔️
    Volume ℹ️ ℹ️ ⛔️
    Point clouds Unlit only

    ¹: Physically-Based Rendering (PBR) material model

    ²: Two sets of texture coordinates (as required by the glTF 2.0 specification) are supported, but not three or more (issue)

    ³: Only supports Universal Render Pipeline versions >= 12.0; Only coat mask and smoothness are supported, other coat related properties, such as coat normal, are not supported

    ⁴: There are two approximation implementations for transmission in Universal render pipeline. If the Opaque Texture is enabled (in the Universal RP Asset settings), it is sampled to provide proper transmissive filtering. The downside of this approach is transparent objects are not rendered on top of each other. If the opaque texture is not available, the common approximation (see ⁴ below) is used.

    ⁵: Transmission in Built-In and HD render pipeline does not support transmission textures and is only 100% correct in certain cases like clear glass (100% transmission, white base color). Otherwise it's an approximation.

    Material Export

    Material export support depends largely on the shaders used. We differentiate between Unity shaders (default shaders of Unity render pipelines) and glTFast's own shaders.

    Unity Shaders

    Unity shaders are typically used on pre-existing assets.

    Supported Unity shaders:

    • Universal and High Definition render pipeline
      • Lit
      • Unlit
    • Built-In render pipeline
      • Standard
      • Unlit

    Other shaders might (partially) work if they have similar properties (with identical names).

    Material Feature URP¹ HDRP² Built-In³
    PBR Metallic-Roughness ✅ ✅ ✅
    PBR Specular-Glossiness  
    Unlit ✅ ✅ ✅
    Normal texture ✅ ✅ ✅
    Occlusion texture ✅ ✅ ✅
    Emission texture ✅ ✅ ✅
    Alpha modes OPAQUE/MASK/BLEND ✅ ✅ ✅
    Double sided / Two sided ✅ ✅ ✅
    Vertex colors ✅⁴ ✅⁴ ✅⁴
    Texture Transform ✅ ✅ ✅
    Clear coat n/a ✅ n/a
    Sheen ? ? n/a
    Transmission n/a
    IOR n/a
    Specular  
    Volume n/a

    ¹: Universal Render Pipeline Lit Shader

    ²: High Definition Render Pipeline Lit Shader

    ³: Built-In Render Pipeline Standard and Unlit Shader

    ⁴: Vertex colors are always exported, regardless whether the shader makes use of them.

    glTFast Shaders

    glTFast's own shaders are typically used when the assets were imported with glTFast. This enables round-trip import-export workflows. They are also the preferred way to author assets for glTF export specifically.

    Supported glTFast shaders/shader graphs:

    • Shader Graphs
      • [x] Shader Graphs/glTF-pbrMetallicRoughness
      • [x] Shader Graphs/glTF-unlit
      • [ ] Shader Graphs/glTF-pbrSpecularGlossiness
      • [ ] Legacy shader graphs (in folder Runtime/Shader/Legacy; used for Universal Render Pipeline 10.x and older)
    • Shaders
      • [x] glTF/PbrMetallicRoughness
      • [x] glTF/Unlit
      • [ ] glTF/PbrSpecularGlossiness
    Material Feature URP HDRP Built-In
    Normal texture ✅ ✅ ✅
    Occlusion texture ✅ ✅ ✅
    Emission texture ✅ ✅ ✅
    Alpha modes OPAQUE/MASK/BLEND ✅ ✅ ✅
    Double sided / Two sided ✅ ✅ ✅
    Vertex colors ✅ ✅ ✅
    Multiple UV sets ✅¹ ✅¹ ✅¹
    Texture Transform ✅ ✅ ✅
    Clear coat n/a n/a
    Sheen ? ? n/a
    Transmission n/a
    IOR n/a
    Specular  
    Volume n/a

    ¹: Only two UV sets are supported by the shaders.

    Data-Oriented Technology Stack

    ⚠️ Note: DOTS is highly experimental and many features don't work yet. Do not use it for production ready projects!

    Unity's Data-Oriented Technology Stack (DOTS) allows users to create high performance gameplay. Unity glTFast has experimental import support for it.

    Instead of traditional GameObjects, Unity glTFast will instantiate Entities and render them via Entities Graphics.

    Possibly incomplete list of things that are known to not work with Entities yet:

    • Animation
    • Skinning
    • Morph targets
    • Cameras
    • Lights

    DOTS Setup

    • Install the Entities Graphics package
    • Use GltfEntityAsset instead of GltfAsset
    • For customized behavior, use the EntityInstantiator instead of the GameObjectInstantiator

    Unity Version Support

    Unity glTFast requires Unity 2020.1 or newer.

    Legend

    • ✅ Fully supported
    • ☑️ Partially supported
    • ℹ️ Planned (click for issue)
    • ⛔️ No plan to support (click for issue)
    • ?: Unknown / Untested
    • n/a: Not available

    Trademarks

    Unity® is a registered trademark of Unity Technologies.

    Khronos® is a registered trademark and glTF™ is a trademark of The Khronos Group Inc.

    KTX™ and the KTX logo are trademarks of the The Khronos Group Inc.

    Draco™ is a trademark of Google LLC.

    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)