bufferViews missing target types
viperscape opened this issue · comments
On the latest exporter in Blenders 2.8 Beta, the bufferViews are missing their target types, is this expected behavior?
"bufferViews" : [
{
"buffer" : 0,
"byteLength" : 124992,
"byteOffset" : 0
},
{
"buffer" : 0,
"byteLength" : 124992,
"byteOffset" : 124992
},
{
"buffer" : 0,
"byteLength" : 166656,
"byteOffset" : 249984
},
{
"buffer" : 0,
"byteLength" : 83328,
"byteOffset" : 416640
},
{
"buffer" : 0,
"byteLength" : 122292,
"byteOffset" : 499968
}
],
Where before (2.7 exporter) they existed:
"bufferViews" : [
{
"buffer" : 0,
"byteLength" : 8064,
"byteOffset" : 0,
"target" : 34963
},
{
"buffer" : 0,
"byteLength" : 5196,
"byteOffset" : 8064,
"target" : 34962
},
{
"buffer" : 0,
"byteLength" : 5196,
"byteOffset" : 13260,
"target" : 34962
},
{
"buffer" : 0,
"byteLength" : 6928,
"byteOffset" : 18456,
"target" : 34962
},
{
"buffer" : 0,
"byteLength" : 3464,
"byteOffset" : 25384,
"target" : 34962
}
],
Target is optional. The spec says:
When
bufferView.target
is defined, runtime must use it to determine data usage, otherwise it could be inferred from mesh' accessor objects.
Yes, the target property isn't added to the glTF by the exporter any more
I have also have the same issue here, I had to add to runtime sanity check which apply ELEMENT_ARRAY_BUFFER as target when bufferView is use in primitive indices accessor.
I use blender 2.80 2019-04-12