KhronosGroup / KhronosGroup/glTF

[glTF 2.1] Multiple Scenes Deprecation

Open
#2,591 0 comments 0 reactions 0 assignees View on GitHub
2.1
Dominant language
HTML
Stars
7.8k
Forks
1.2k
Avg merge
17h 26m
Merged PRs (30d)
5

Description

# Multiple scenes deprecation

glTF 2.1 deprecates the ability to have multiple scenes in a glTF file's `scenes` array. This means that, for glTF 2.1 files, one of the following SHOULD be the case:

- The `scenes` array has exactly one scene, and the `scene` property is either set to `0` or not present.

- Neither the `scene` nor `scenes` properties are present, since a glTF file is allowed to have zero scenes.

glTF 2.1 exporters should not create new files with multiple scenes, but glTF 2.1 importers should still handle files with multiple scenes in the same way as they did for glTF 2.0 for backward compatibility.

## Example

> [!NOTE]
> Examples are illustrative and not exhaustive.

```json
{
"nodes": [
{
"name": "RootNode"
}
],
"scene": 0,
"scenes": [{ "nodes": [0] }]
}
```

## Why this design

glTF 2.0 multiple scenes did not receive much use in practice, were not consistently implemented when they were implemented, and [have been asked to be removed](https://github.com/KhronosGroup/glTF/issues/1542) for a long time.

glTF 2.0 does not define a way to use multiple scenes. A scene cannot include another scene, or use it in any way. The glTF Object Model defines the `/scene` property as read-only, not something that can be changed at runtime.

glTF 2.1 adds support for complex scenes, which is considered a more useful design than multiple scenes. glTF 2.1 defines how to instantiate external assets in the hierarchy, allows for using external assets multiple times, and allows for external storage of all glTF content, none of which is possible with glTF 2.0 multiple scenes.

Contributor guide

Open the contributing guide

Research direction

The issue does not name repository files or tests. Start by locating the glTF 2.1 specification sections defining the scene and scenes properties, then compare their glTF 2.0 compatibility requirements. Done means the normative specification text and illustrative examples consistently express the proposed deprecation while preserving importer behavior for existing files.

Written by the indexing model from the issue text.

Assessment

Tech stack
json
Domain
documentation
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.