Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remaining issues with the gltf loader #1802

Open
jakobhellermann opened this issue Apr 2, 2021 · 6 comments
Open

Remaining issues with the gltf loader #1802

jakobhellermann opened this issue Apr 2, 2021 · 6 comments
Labels
A-Assets Load files from disk to use for things like images, models, and sounds A-Rendering Drawing game state to the screen C-Bug An unexpected or incorrect behavior C-Feature A new feature, making something new possible C-Usability A targeted quality-of-life change that makes Bevy easier to use

Comments

@jakobhellermann
Copy link
Contributor

jakobhellermann commented Apr 2, 2021

I've tried all the gltf samples models from here and while many already load, here's the list of remaining issues:

TODO:

  • Animations
  • Coating (ClearCoatTest)
  • Environment (EnvironmentTest)
  • Morph primitives (MorphPrimitivesTest)
  • Multiple UVs (MultiUVTest)
  • Material Variants (SheenChair, SheenCloth)
  • Transmission (TransmissionTest)
  • Two Sided (TwoSidedPlane)
  • Texture Transform (TextureTransformMultiTest, TextureTransformTest)
  • Loading lights
  • KHR_draco_mesh_compression
  • glTF-Quantized
  • "Embedded" gltf variants (inline data URIs)
  • Cameras
  • Vertex colors (VertexColorTest)
  • data URIs in images
  • Missing Vertex_Normal
  • Missing UV

Bugs:

  • glTF-Sample-Models/2.0/SheenCloth/glTF/SheenCloth.gltf (range end index 263168 out of range for slice of length 262144)
  • glTF-Sample-Models/2.0/SimpleSparseAccessor/glTF/SimpleSparseAccessor.gltf (subtract with overflow)
  • glTF-Sample-Models/2.0/Box With Spaces/glTF/Box With Spaces.gltf (failed to load path)
@alice-i-cecile alice-i-cecile added A-Assets Load files from disk to use for things like images, models, and sounds C-Usability A targeted quality-of-life change that makes Bevy easier to use C-Bug An unexpected or incorrect behavior A-Rendering Drawing game state to the screen C-Feature A new feature, making something new possible labels Apr 2, 2021
@julhe
Copy link
Contributor

julhe commented Apr 2, 2021

I've adressed vertex colors in #1775

bors bot pushed a commit that referenced this issue Apr 13, 2021
This allows the `glTF-Embedded` variants in the [sample models](https://github.com/KhronosGroup/glTF-Sample-Models/) to be used.
The data url format is relatively small, so I didn't include a crate like [docs.rs/data-url](https://docs.rs/data-url/0.1.0/data_url/).

Also fixes the 'Box With Spaces' model as URIs are now percent-decoded.

cc #1802
bors bot pushed a commit that referenced this issue Apr 15, 2021
If the gltf loader encounters a mesh without normal attributes, it will duplicate the vertex attributes and compute flat normals, as defined by https://github.com/KhronosGroup/glTF/blob/master/specification/2.0/README.md#meshes:

> **Implementation Note**: When normals are not specified, client implementations should calculate flat normals.

![image](https://user-images.githubusercontent.com/22177966/113483243-bb204880-94a2-11eb-8fa1-c4828a4882c5.png)

Helps with #1802 

Co-authored-by: Carter Anderson <[email protected]>
jihiggins pushed a commit to jihiggins/bevy that referenced this issue Apr 18, 2021
This allows the `glTF-Embedded` variants in the [sample models](https://github.com/KhronosGroup/glTF-Sample-Models/) to be used.
The data url format is relatively small, so I didn't include a crate like [docs.rs/data-url](https://docs.rs/data-url/0.1.0/data_url/).

Also fixes the 'Box With Spaces' model as URIs are now percent-decoded.

cc bevyengine#1802
bors bot pushed a commit that referenced this issue May 6, 2021
fixes a lot of gltf loading failures (see #1802)
@lassade
Copy link
Contributor

lassade commented Jun 3, 2021

@jakobhellermann I was doing a similar work here, can you post the link for your test repo?

ostwilkens pushed a commit to ostwilkens/bevy that referenced this issue Jul 27, 2021
This allows the `glTF-Embedded` variants in the [sample models](https://github.com/KhronosGroup/glTF-Sample-Models/) to be used.
The data url format is relatively small, so I didn't include a crate like [docs.rs/data-url](https://docs.rs/data-url/0.1.0/data_url/).

Also fixes the 'Box With Spaces' model as URIs are now percent-decoded.

cc bevyengine#1802
ostwilkens pushed a commit to ostwilkens/bevy that referenced this issue Jul 27, 2021
If the gltf loader encounters a mesh without normal attributes, it will duplicate the vertex attributes and compute flat normals, as defined by https://github.com/KhronosGroup/glTF/blob/master/specification/2.0/README.md#meshes:

> **Implementation Note**: When normals are not specified, client implementations should calculate flat normals.

![image](https://user-images.githubusercontent.com/22177966/113483243-bb204880-94a2-11eb-8fa1-c4828a4882c5.png)

Helps with bevyengine#1802 

Co-authored-by: Carter Anderson <[email protected]>
ostwilkens pushed a commit to ostwilkens/bevy that referenced this issue Jul 27, 2021
vabrador pushed a commit to vabrador/bevy that referenced this issue Sep 15, 2021
This allows the `glTF-Embedded` variants in the [sample models](https://github.com/KhronosGroup/glTF-Sample-Models/) to be used.
The data url format is relatively small, so I didn't include a crate like [docs.rs/data-url](https://docs.rs/data-url/0.1.0/data_url/).

Also fixes the 'Box With Spaces' model as URIs are now percent-decoded.

cc bevyengine#1802
@wotori
Copy link

wotori commented Mar 11, 2022

For now we can't play gltf animations right? Only import?

@kirusfg
Copy link
Contributor

kirusfg commented Mar 14, 2022

@wotori I think you are referring to #3751, which has not been merged yet. This PR includes an example of playing simple animations; stuff like skeletal animation would only make sense to implement after #4026 is completed (see bevy_prototype_animation)

@rlidwka
Copy link
Contributor

rlidwka commented Jun 25, 2024

Loading lights

I believe this is fixed (see #1331). And I can confirm that lights work (after checking "Punctual lights" in blender export settings for glTF).

Can this item be crossed off the list? Or are there other light options that aren't supported?

@janhohenheim
Copy link
Member

janhohenheim commented Jun 25, 2024

"Texture Transform (TextureTransformMultiTest, TextureTransformTest)" was probably resolved by #11869

dekirisu pushed a commit to dekirisu/bevy_gltf_trait that referenced this issue Jul 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Assets Load files from disk to use for things like images, models, and sounds A-Rendering Drawing game state to the screen C-Bug An unexpected or incorrect behavior C-Feature A new feature, making something new possible C-Usability A targeted quality-of-life change that makes Bevy easier to use
Projects
None yet
Development

No branches or pull requests

8 participants