Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there a C API? #428

Open
n0bra1n3r opened this issue Dec 25, 2023 · 2 comments
Open

Is there a C API? #428

n0bra1n3r opened this issue Dec 25, 2023 · 2 comments
Labels
question Further information is requested

Comments

@n0bra1n3r
Copy link

n0bra1n3r commented Dec 25, 2023

I have been looking around for C language bindings for ogre-next. My purpose is to use ogre-next from another language via the C API. Does anyone know of a C language bindings I can use?

@darksylinc
Copy link
Member

darksylinc commented Dec 26, 2023

Hi!

No, there is not.

Ogre1 has SWIG bindings and there is a WIP PR that wanted to add SWIG based on Ogre1. The PR aims to add Python bindings though, and a quick google it seems that SWIG does not support generating C bindings.

It feels odd, automatically generating C bindings using libclang by parsing headers should be a piece cake.

We already have a python script that parses libclang and could be repurposed to parse the entire database and generate bindings.

I also have a C++ (instead of Python) project that parses headers using libclang; in case you're interested.

It seems that such project already exists.

I don't have plans of adding C bindings, but if you want to add a PR it will be welcomed.

@darksylinc darksylinc added the question Further information is requested label Dec 26, 2023
@n0bra1n3r
Copy link
Author

n0bra1n3r commented Dec 31, 2023

Thanks! Currently attempting to generate bindings for my target language directly, which is nim. Will post a link to the repo here if I'm successful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants