-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Update Draco gltf models using ratified bitstream #145
Update Draco gltf models using ratified bitstream #145
Conversation
Models were created from branch: https://github.com/google/draco/tree/gltf_2.0_draco_extension
@donmccurdy Can you try these files? I might redo them with more compression later. But I just want to make sure they work for you. |
These are working with donmccurdy/three.js#6, thanks 👍 |
In ./javascript, should there be a glTF flavour of the encoder? Or are they the same? |
@FrankGalligan This causes validation errors: |
Encode sample models with all default settings
What's left before we can merge this? |
How does this PR relate to #116? |
I've tested 4-5 of these in the three.js Draco implementation, and they looked good to me. |
Some of of these - and soon all - have also been tested with Cesium. CC CesiumGS/cesium#6191 |
The fallback attributes are not working for me. Looks like https://github.com/KhronosGroup/glTF/blob/master/specification/2.0/schema/accessor.schema.json#L11 Edit: Even if I add the missing |
I just noticed that |
I believe accessors with missing bufferviews is the expected Draco-required output. |
From the spec:
We implemented it this way in three.js: if ( accessorDef.bufferView === undefined && accessorDef.sparse === undefined ) {
// Ignore empty accessors, which may be used to declare runtime
// information about attributes coming from another source (e.g. Draco
// compression extension).
return null;
} /cc @lexaknyazev |
Yes, sorry for my confusion. I reread the spec and I now understand what it is supposed to look like when the extension is required. I think we can add a couple of minor things to avoid confusion.
|
+1 for adding the explanation. Let's do that after the PR is merged.
Also +1. I tried to keep this case in mind with three.js implementation, but haven't tested it and would be surprised if it works yet. |
@bghgary @donmccurdy submitted KhronosGroup/glTF#1244. Please hit merge if this is otherwise ready. 🚀 🚀 🚀 |
I tried all the models with a glTF-Draco folder. All of them are working for me except:
Does this work for anyone else? It would be good to know if it's the model before I dig in to why. |
CesiumMan and Monster are working for me. I haven't tried RiggedFigure. See: mrdoob/three.js#13194 |
I think I figured it out, but would like confirmation. It looks like the unique ids are mapped wrong in RiggedFigure. I haven't checked the rest of them. Edit: Scratch that. VSCode debugger is reporting the wrong values. |
The JOINTS_0 attribute is returning floats that are not integers.
Is this expected? |
I fixed this issue from my end and all of the models are passing for me now. I am okay with merging if the JOINTS_0 issue is expected. |
Confirmed Rigged Figure is working in three.js, but as Gary mentions the joint indices are floats not ints, unlike the original file. |
I think the spec is fine as it should be int. Even the gltf for the draco version says the data should be int: I think this is an implementation bug. |
Thanks all! Merging this, and we can address the JOINTS_0 implementation bug with a followup. Meanwhile, opened another issue here: #147 |
Models were created from branch:
https://github.com/google/draco/tree/gltf_2.0_draco_extension