odin-blend2d

Odin bindings to Blend2D
Log | Files | Refs | README | LICENSE

README.md (924B)


      1 # `odin-blend2d`
      2 
      3 > Bindings for [Blend2D](https://blend2d.com) vector graphics library.
      4 
      5 Bindings are generated with [bindgen](https://github.com/karl-zylinski/odin-c-bindgen),
      6 with custom patches applied to fix some naive output.
      7 
      8 ## Generate
      9 
     10 Blend2D source (and asmjit) is wholly included as a subtree.
     11 
     12 The file `./script/generate.sh` will compile a static library from source for
     13 your system, and generate the bindings from the headers.
     14 
     15 You will need to run `./script/generate.sh` to acquire the static library compatible
     16 with your system, or follow Blend2D's [build instructions](https://blend2d.com/doc/build-instructions.html) yourself.
     17 
     18 ## Examples
     19 
     20 The examples folder contains some samples directly ported from Blend2D.
     21 Run the samples like so:
     22 
     23 ```sh
     24 odin run ./example/sample_1.odin -file -extra-linker-flags:"-lstdc++"
     25 ```
     26 
     27 While Blend2D offers a C api, we still need to link stdc++ the static lib uses C++.