Skip to content

Add Advanced glTF tutorial#382

Open
gpx1000 wants to merge 20 commits into
KhronosGroup:mainfrom
gpx1000:gltf-tutorial
Open

Add Advanced glTF tutorial#382
gpx1000 wants to merge 20 commits into
KhronosGroup:mainfrom
gpx1000:gltf-tutorial

Conversation

@gpx1000

@gpx1000 gpx1000 commented May 28, 2026

Copy link
Copy Markdown
Contributor

Scene Graph Hierarchy chapter with optimization techniques and physics integration

Add three new sections covering unified scene graph architecture, dirty flag optimization, and bidirectional physics syncing. Include comprehensive appendix with common types reference for scene graph, animation, physics, and IK systems. Implement data-oriented design with cache-friendly flat arrays and topological sorting for efficient transform updates.

gpx1000 and others added 20 commits May 26, 2026 02:56
…hniques and physics integration

Add three new sections covering unified scene graph architecture, dirty flag optimization, and bidirectional physics syncing. Include comprehensive appendix with common types reference for scene graph, animation, physics, and IK systems. Implement data-oriented design with cache-friendly flat arrays and topological sorting for efficient transform updates.
* Add in advanced_gltf tutorial demo code
* Add in nav.adoc updates.
…e copies for localization to directory purposes. (i.e. renderer.h is changed in this tutorial, and if we let those files exist in their normal state in simple_engine they will include that renderer.h and MSVC can't accept that the defines here prevent the defines there and cause redefinition errors if using force include).
# Conflicts:
#	antora/modules/ROOT/nav.adoc
@SaschaWillems SaschaWillems self-requested a review June 27, 2026 10:02
@SaschaWillems

Copy link
Copy Markdown
Collaborator

The new chapters have not yet been added to the navigation, so accessing them from a site-build is not possible right now.

Throughout this series, we will upgrade our development toolkit to reflect modern standards:

* **Slang Shaders**: All of our new shader work—from compute skinning to PBR enhancements—will be written in **Slang**. Slang's modularity and natural alignment features make it far more productive than raw GLSL for complex rendering pipelines.
* **Vulkan 1.4**: We will utilize features like **Dynamic Rendering** and **Descriptor Indexing** to simplify our pipeline management and improve performance.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Vulkan 1.3 has both features and wider support.


* **Slang Shaders**: All of our new shader work—from compute skinning to PBR enhancements—will be written in **Slang**. Slang's modularity and natural alignment features make it far more productive than raw GLSL for complex rendering pipelines.
* **Vulkan 1.4**: We will utilize features like **Dynamic Rendering** and **Descriptor Indexing** to simplify our pipeline management and improve performance.
* **Jolt Physics**: We have selected **Jolt Physics** as our simulation engine. Its performance-first design and clean C++ API make it the ideal choice for real-time character dynamics and ragdolls.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should at least have a link to the Jolt site and/or repo


=== 3. Khronos glTF-Validator
To ensure our custom glTF assets are valid, we will use the official validator.
* **Installation**: Follow the instructions on the link:https://github.com/KhronosGroup/glTF-Validator[glTF-Validator repository]. It is available as a standalone CLI tool or via NPM.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs a line-break, otherwise the list won't be rendered properly


This series assumes you have a working engine from the "Building a Simple Engine" series. To transition to the Advanced glTF architecture, you should prepare a "Starter Project" that:

1. **Supports Vulkan 1.4**: Ensure your instance and device creation request the 1.4 API version.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would lower that to 1.3

This series assumes you have a working engine from the "Building a Simple Engine" series. To transition to the Advanced glTF architecture, you should prepare a "Starter Project" that:

1. **Supports Vulkan 1.4**: Ensure your instance and device creation request the 1.4 API version.
2. **Enables Dynamic Rendering**: This series moves away from fixed Render Passes and Framebuffers in favor of `VK_KHR_dynamic_rendering`.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"moves away" in relation to what exactly? The tutorial already uses dynamic rendering.


== The Power of "Extras"

In a professional production, an artist shouldn't have to write code to define where a character's collision shapes go. Instead, they define them as custom properties in Blender. When the glTF is exported, these properties are embedded in the `extras` field of the corresponding node.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be nice to add some details on how to do this in Blender. Screenshot would be a good option.


[NOTE]
====
To follow this section, you will need the **Slang compiler (`slangc`)**. You can download the latest binaries from the link:https://github.com/shader-slang/slang/releases[Slang GitHub releases page]. Ensure `slangc` is in your system PATH.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could mention that Slang is part of the SDK, so most people following the tutorial already have that available and don't need a separate download.

@SaschaWillems SaschaWillems left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm now at the part where the tutorial actually starts showing code and I'm a bit confused. The code shown on the documentation does not match the C++ ode at all. If I look at the "The Compute Skinning Pipeline" and compare that with the C++ code, they look totally different.

Is that intentional, or will the C++ code updated to match the actual tutorial (or vice versa)? If not, what's the ideal way to actually review the code shown in the tutorial?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants