Creating Buffer Geometry


We have THREE JS based viewer used to view our CAD geometry. What we do is, we have C++ program that reads the geometry and writes into JSON file supported by THREE JS(JSON Loader). But now as we know, simple geometry is not supported, we would like to export Buffer geometry from our C++ program itself.

So are there any thoughts how to export buffer geometry from C++? i.e. not using THREE JS.

Please let me know.

Thank you in advance

I would consider using something like to export glTF, which will be loaded in three.js (by THREE.GLTFLoader) as BufferGeometry. That may be easier than trying to maintain a separate implementation of three.js’s custom format.