Hi all,
I am currently working on creating 3DTiles 1.1 tilesets (with GLTF files) for visualization in CesiumJS.
To add arbitrary metadata to the tiles, I am using the EXT_structural_metadata
extension together with the EXT_mesh_features
extension.
I have some questions about the usage of the concepts of the EXT_structural_metadata
extension and its current implementation in CesiumJS.
As the concepts are still quite new and therefore not completely implemented in CesiumJS yet, it’s sometimes a bit difficult to see if I misunderstand the specifications or the capabilities of Cesium, so please bare with me.
(As this is mainly about the usage of those concepts in CesiumJS I added the question to the CesiumJS category, although it overlaps with the 3DTiles category.)
- I am currently using the same buffer views in the gLTF for
PropertyAttributes
and for aPropertyTable
. ThePropertyTable
is using the buffer views directly to reference the property data. ThePropertyAttributes
use accessors on the same buffer views.
The data in the buffer is aligned to 4 bytes (every value is either 4 bytes big or padded with zeros to equal 4 bytes) and the buffer views define a byte stride of 4.
Now in CesiumJS it looks like the data is correctly read from thePropertyAttributes
(in a custom shader) but when accessed via thePropertyTable
(on the “cpu side” in the viewer) the data is incorrect.
Should my approach work or does the property table need a different alignment or something similar? I am retreiving the data from thePropertyTable
(of a picked tileset) viacontent.batchTable.getProperty()
.
It looks like some values are correct but others return the same value as a neighboring primitive (which makes me believe there is some “bleeding” happening from the range of one value into the other one).
If I use a tileset with only one single primitive (and only one property) then the value of that property is correct in thePropertyAttribute
and thePropertyTable
. - Is it correct that
PropertyAttributes
can’t contain integers bigger than 16 bit (because that’s part of the gLTF specification for accessors) whilePropertyTextures
andPropertyTables
can contain bigger integers (as they don’t use accessors)? - If so, is it correct that it is currently not possible to use integers > 16bit for visualization purposes in CesiumJS custom shaders (because
PropertyTables
are not available and CesiumJS currently only supports UINT8 values inPropertyTextures
)? - Is it correct that by using
PropertyAttributes
you are limited to a relatively small number of attributes because they are added as vertex attributes and most GPUs only support the usage of 16 vertex attributes which also includes texture coordinates etc.?
Thank you!