From other languages
The ABI uses only fixed-size integers, float, size_t, char *, a few
plain structs and one opaque pointer. No callbacks, no variadic functions,
no C++. Anything with a C FFI can bind it.
| Language | How |
|---|---|
| C# (Unity, Godot .NET) | [DllImport("ayatsuri_capi")] per function, IntPtr for the model, arrays marshalled for the call; ay2d_drawable as a [StructLayout(Sequential)] struct whose pointers you wrap in a Span<float> or copy into a NativeArray |
| Python | ctypes.CDLL, argtypes and restype per function, numpy.ctypeslib.as_array over positions for a view without a copy |
| Godot (GDExtension, C++) | include the header, link the static library, wrap the model in a RefCounted, feed an ArrayMesh or RenderingServer canvas items |
| Unreal | a third-party module around the static library; drawables into a procedural mesh |
| Node | koffi or ffi-napi with the same signatures, or the static library in a native addon |
Whatever the language, keep to the three-call frame. A binding pays per call, not per byte.