lmariscal / nimgl_gen

MIT License
2 stars 0 forks source link

Move imgui bindings to their own repo #1

Closed zacharycarter closed 5 years ago

zacharycarter commented 5 years ago

Hi lmariscal! Thanks for your hard work on this project, it's great! I just was able to get the imgui bindings generated on my machine without issue - I just had to copy the json files from cimgui into the working directory.

Onto the reason I've created this issue - I was wondering if we could perhaps separate out these projects? Then they could be submoduled / subtreed into a parent repo? The reason I'm suggesting this - is because I think there are many folks who would like to be able to generate the imgui bindings, without checking out the opengl bindings or resorting to sparse checkouts, etc...

Also - I was thinking it'd be neat if this project submoduled cimgui, or at least kept a copy of the json files locally so folks won't be scratching their heads when they run nimble bake and they're greeted with an error message about a json file not being found.

If you're on board with these changes - I'd be happy to help in any way I can!

I think then, the imgui bindings could easily be added to nimble. I have no use for the opengl bindings, and I imagine there are others in that category as well.

I'd love to hear your thoughts! Thanks!

Edit -

I've gone ahead and done ^ - https://github.com/zacharycarter/nimgui

I added my name to the LICENSE and .nimble file, renamed the project, and made it more nimble friendly, if you will...

I'm perfectly happy to transfer ownership of the repo to you, if you'd like - and you can even take my name off of everything - I don't mind at all :)

I just thought it'd be weird, if I had a project with someone else's name all over it, and no mention of my own - people might start to think things about me, or you lol...

Anyways - this structure will be a little easier for me to conume - but if it's not useful for your purposes - I totally understand... Either way - I think we should find a way to get the imgui bindings in their own nimble package and in the nimble package.json that powers https://nimble.directory/

lmariscal commented 5 years ago

Hi @zacharycarter, thanks for making the repo, it's more than okay if you keep ownership for it since I mostly plan to give support to nimgl. Please add your name in the License and if you want also change the license in the top of the file.

It would be great if you could in the future make some implementation examples with other gl bindings like nim-glfw, opengl or even sdl2. I would gladly help you since I already did both glfw and opengl implementations in nimgl.

I find that your repo nimgui is a more suitable place for the imgui binding generations and it would be silly to have two repos dedicated to them, so if it's okay with you to move work to your repo and for me to copy the generated files to nimgl to keep offering it as a "bundle". As for the nimble package it would be great to upload the generated files with some examples of the previous mentioned example implementations.

The syntax is thought to work with the whole nimgl project so procs that could be used like methods of objects would not start with the prefix "ig", I don't know if this should be changed. Other imgui bindings work closely to the language like imgui-rs which makes the whole api more type safe, so I was planning on making some helpers for this bindings to make them work closely with nim and avoid having to use discard in every other proc, I'm not really familiarized with nim macro programming but I feel it's something that could add value to this bindings just like the RAII issue in c++.

Also wanted to point out that the c++ compilation is not working correctly because of some namespace issues and varargs not having a persistent syntax/value in the cimgui generated json.

Thanks for everything!

Edit: I'm also in the #nim freenode channel by the username of cavariux

zacharycarter commented 5 years ago

Thanks Leo!

That all sounds great to me - I'm going to be working on an editor this afternoon / evening - and assuming I get far enough to incorporate imgui into my work, I will be sure to port the example I create over to the repo.

I'll then port that example to some other backends as well.

Feel free to ping me in IRC if you need me for anything - and I will do the same :)

Have a great afternoon Leo!