Automatic generated bindings of GLFW3 for .NET
Automatic generated bindings of GLFW3 for .NET
Please report any bugs and suggestions!
Please keep in mind to add the file WrapperGLFW.dll.config to your project and change the option CopyToOutputPath
of the file WrapperGLFW.dll.config to Always.
The file can be found under /yoursolutionpath/packages/GLFW.NET.x.x.x/Content/WrapperGLFW.dll.config
.
This is required for Linux or Mac and if you don't do it, the library won't work.
This repository provides bindings for the latest GLFW3 version. It covers almost the complete API except Vulkan.
The binding is generated automatically but for a small part.
To get support for the Vulkan specific functions it's recommeneded to use the additional file GLFW3_Wrapper.cs which includes the missing bindings (for Vulkan) and an object oriented wrapper.
The projects under src are the generator, raw GLFW binding and an oop wrapper with binding for GLFW.
To get the binding as dll please read further.
Build.cmd
The x64 glfw3.dll can be found in the dependencies folder. If you need a custom binary for windows go to the glfw website Pre-build binaries for all other architectures on windows e.g. x86 can be found there.
sh build.sh
There are also custom targets available for FAKE:
Build WrapperBinding
to get the binding with oop wrapper (default target).Build RawBinding
to get the binding without oop wrapper.Build Generator
to build the generator.Build all bindings
to build the raw and wrapper binding.Clean
to clean the build folder.To use them simply add them with quotation marks after the build command.
Few usage examples are under the examples folder:
Other examples can be seen in the wiki page of this repository.
Contributions to make this binding better and staying up to date are readily appreciated, feel free to send PR's and open issues if there are any.
To build the generator under Linux or Mac you have to compile the latest CppSharp on your own.
Windows developers can easily use the existing dlls in the dependencies folder.
We're having a gitter chat for discussing binding generation and or additional features! Feel free to join us!