Recast navigation bindings for Hashlink
Reuses some work from Babylon.js's recast bindings
This project only supports Hashlink, and JS. It uses webIDL, and additionally emscripten for the JS port.
haxe -lib webidl --macro recast.Generator.generateCpp()"
msbuild recast.vcxproj
Make sure you run emsdk_env
first.
haxe -lib webidl --macro "recast.Generator.generateJs()"
The sample uses Heaps, and is setup with lix.
The haxe WebIDL wrapper doesn't actually use embind in a good way. This means we have do some pretty gross platform specific JS when passing arrays into recast (such as when building the mesh). I'd like to fix this, but it'll likely require upstream work in Cannasse's WebIDL lib. See the sample for an example on this; essentially you need to use malloc
to create space on the heap, copy the buffer over, then pass the offset in.