How to Load Application Specific Data as well..
I have a gltf file in which a mesh primitive looks like this: "primitives": [ { "attributes":{ "BATCHID":"accBatch_0", "NORMAL":"accNormal_0", "POSITION":"accPosition_0" }, "indices":"accIndex_0", "material":"Material_0", "mode":4 }, ] where accBatch_0 for batch id refers to an accessor for accessing all the application specific ids of the vertices
however the library fails to load the file
First, a snippet above looks like glTF 1.0. Unity loader supports only 2.0. Moreover, BATCHID is not a valid attribute name: all app-specific attribute names must start with _, i.e. it should be _BATCHID.
how about this??? "primitives": [ { "attributes": { "POSITION": 25, "_BATCHID": 0 }, "indices": 10, "material": 3, "mode": 1 } ]
This is from a gltf 2.0 that has a underscore as well. i cant get Unity to load the file... It also uses webquantized attributes. not sure whats causing the failure.. I can provide the complete gltf as well for testing if needed
It's hard to say what's causing the failure without seeing the complete asset (also, I'm not a developer of this particular plugin, so the reason might be somewhat Unity-specific). Anyway, could you please check the asset in the validator to ensure that it's valid glTF 2.0?
Btw, UnityGLTF certainly doesn't support quantized attributes extension.
It isnt a valid GLTF but im expected to get it working anyhow... oh then its probably the quantized attributes. Thanks alot!!!
We don't support loading invalid glTF files. Metadata information should go in the extensions or extras field of your file.