Geopipe / gltf2glb

GLTF to Binary GLTF (GLB) converter, supporting Cesium Batch and Instance files (b3dm and i3dm) as well.
BSD 3-Clause "New" or "Revised" License
93 stars 27 forks source link

i3dm Support #12

Closed KermMartian closed 5 years ago

KermMartian commented 5 years ago

Add support for generating CesiumJS i3dm files from a JSON describing the instances, and a GLB file to instance. Poorly documented sample instance JSON:

[
    {
        "POSITION": [0.0, 0.0, 0.0]
    },
    {
        "POSITION": [10.0, 20.0, 0.0]
    },
    {
        "POSITION": [10.0, 0.0, 0.0]
    },
    {
        "POSITION": [0.0, 0.0, 15.0]
    }
]

Just for fun, assigning to @elfprince13 for review (feel free to decline to do so). Tested functioning with CesiumJS for simple instancing like the above. Future work includes documenting the expected JSON format ~better~.