Sparked by CesiumGS/cesium#13032 :
Apparently, when creating a glTF model and just writing it with the CesiumGltfWriter, it does not contain the asset.version = "2.0" property. First, that's invalid. Second (in case more reasoning is necessary), CesiumJS gets confused by this and can cause hard-do-diagnose follow-up errors.
One could argue that ~"the model should, by default, be completely unititialized" - and that's a valid point. We're not inserting some random Node or Animation just ~"because it is convenient for us". But I think that the asset version is pretty much a baseline.
Given that large parts of the code are auto-generated, and the version field does (of course) not have a 'default' value as of the spec, the question may be where it should be inserted. But there should be some place - maybe around
(given that the auto-generated part is
ModelSpec anyhow...)
Sparked by CesiumGS/cesium#13032 :
Apparently, when creating a glTF model and just writing it with the
CesiumGltfWriter, it does not contain theasset.version = "2.0"property. First, that's invalid. Second (in case more reasoning is necessary), CesiumJS gets confused by this and can cause hard-do-diagnose follow-up errors.One could argue that ~"the model should, by default, be completely unititialized" - and that's a valid point. We're not inserting some random
NodeorAnimationjust ~"because it is convenient for us". But I think that the asset version is pretty much a baseline.Given that large parts of the code are auto-generated, and the
versionfield does (of course) not have a 'default' value as of the spec, the question may be where it should be inserted. But there should be some place - maybe aroundcesium-native/CesiumGltf/include/CesiumGltf/Model.h
Line 15 in e876c13
ModelSpecanyhow...)