google / google/bigwheels

[glTF] Calculate normals if not provided

Open
#476 0 comments 0 reactions 0 assignees View on GitHub
enhancement good first issue
Dominant language
C++
Stars
107
Forks
42
PR merge metrics
No merged PRs in 30d

Description

`GltfLoader::LoadMeshData` will provide (0,0,0) for normals if not present. However [3.7.2.1](https://github.com/KhronosGroup/glTF-Sample-Assets/tree/main/Models/SimpleMaterial) says:

> When normals are not specified, client implementations MUST calculate flat normals and the provided tangents (if present) MUST be ignored.

This would allow BigWheels to correctly render:

- [SimpleMaterial](https://github.com/KhronosGroup/glTF-Sample-Assets/tree/main/Models/SimpleMaterial)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.