SlimeYummy / recastnavigation-rs

A rust binding for recastnavigation path finding library adds cross-platform deterministic.
Mozilla Public License 2.0
6 stars 0 forks source link

Question: Support for WebAssembly (WASM) #27

Open Sorte1 opened 3 days ago

Sorte1 commented 3 days ago

Hi,

First of all, thank you for this library.

I was wondering if there are any plans to add support for compiling recastnavigation-rs to WebAssembly?

It would be great to use this library in a browser environment.

I’m aware of the recast-detour package for JavaScript, but it would be nice to have a Rust implementation available for this purpose.

If this isn't currently on the roadmap, could you provide any guidance on what might be required to make it compatible? For example:

Thank you for your time and effort!

Best regards, Noah (Sorte)

SlimeYummy commented 5 hours ago

Hi @Sorte1,

At present, I have not compiled this library into wasm yet. Because this require to compile Rust and C++ (recastnavigation) at the same time. I will try to add WebAssembly support for tests in recastnavigation-rs, using wasm-bindgen and wasm-bindgen-test, like my another library ozz-animation-rs. if successful, it will ensure that recastnavigation-rs can be compiled to wasm. For further works, I have no plan currently.

Thanks