HaxeFoundation / HaxeFoundation/hxcpp
Embind
Open
- Dominant language
- C++
- Stars
- 330
- Forks
- 227
- Avg merge
- 2d 16h
- Merged PRs (30d)
- 18
Description
Embind is used to bind C++ functions and classes to JavaScript, so that the compiled code can be used in a natural way by “normal” JavaScript.
According to this documentation how can i use Embind in my Haxe code ?
https://kripken.github.io/emscripten-site/docs/porting/connecting_cpp_and_javascript/embind.html
```cpp
#include
using namespace emscripten;
float lerp(float a, float b, float t) {
return (1 - t) * a + t * b;
}
EMSCRIPTEN_BINDINGS(my_module) {
function("lerp", &lerp);
}
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.