Home

Awesome

Biohazrd

MIT Licensed CI Status NuGet Version Sponsor

Biohazrd is a framework for creating binding generators for C and C++ libraries. It aims to lower the amount of ongoing boilerplate maintenance required to use native libraries from .NET as well as allow direct interoperation with C++ libraries without a C translation later.

Biohazrd's API is now stable, but the documentation and overall developer experience is still improving. If you're interested in this project, consider sponsoring development.

Interested in seeing how Biohazrd can be used in practice? Check out Mochi.DearImGui or Mochi.PhysX. (Also check out the preview of the upcoming hosted pipelines feature teased here.)

We also have peliminary documentation available in the docs folder.

License

This project is licensed under the MIT License. See the license file for details.

Additionally, this project has some third-party dependencies. See the third-party notice listing for details.

Quick Overview

Here's a quick overview of the individual components of this repository:

ProjectDescription
BiohazrdThe core of Biohazrd. This is the code is primarily responsible for parsing the Cursor tree of libclang` and translating it into a simplified model that's easier to work with.
Biohazrd.TransformationLanguage-agnostic functionality for transforming the immutable object model output by the core. (As well as a some common transformations you might need)
Biohazrd.OutputGenerationLanguage-agnostic functionality for writing out code and other files.
Biohazrd.CSharpTransformations, output generation, and other infrastructure for supporting emitting a C# interop layer.
Biohazrd.UtilitiesOptional helpers that don't fit anywhere else.
Biohazrd.AllInOneA convenience package which brings in all of the other components of Biohazrd.
TestsAutomated tests for Biohazrd.