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

Attempt to get imnodes minimap working #87

Merged
merged 8 commits into from
Dec 5, 2021
Merged

Conversation

Tyruiop
Copy link
Contributor

@Tyruiop Tyruiop commented Nov 1, 2021

Hi,

I am trying to get ImNodes' minimap working, by reproducing their demo.

Unfortunately it is not working, when I try to run the example, everything starts fine but once I click on show imnodes window, I get

> Task :example:run FAILED
Exception in thread "main" java.lang.UnsatisfiedLinkError: imgui.extension.imnodes.ImNodes.miniMap(FI)V
        at imgui.extension.imnodes.ImNodes.miniMap(Native Method)
        at ExampleImNodes.show(ExampleImNodes.java:74)
        at Extra.show(Extra.java:31)
        at Main.process(Main.java:84)
        at imgui.app.Window.runFrame(Window.java:168)
        at imgui.app.Window.run(Window.java:158)
        at imgui.app.Application.launch(Application.java:83)
        at Main.main(Main.java:96)

I am not sure how to fix that, I've tried looking at the ImGizmo PR to see how it was done but imgui-binding/build/libsNative/ doesn't contain any .so after doing
./gradlew :imgui-binding:generateLibs -Denvs=linux64 -Dlocal

Any help would be appreciated ! Thanks in advance

@SpaiR
Copy link
Owner

SpaiR commented Nov 2, 2021

@Tyruiop Hi!
Thank you for your contribution. As you my see, there are problems with compiling of native libraries, which need to be addressed. I can't provide more info about that. It's an issue which need to be investigated in a scope of updating imnodes library.

@Tyruiop
Copy link
Contributor Author

Tyruiop commented Nov 2, 2021

@SpaiR thanks for your reply!

I've been digging more, and after updating ImGui to use a newer commit I've found out that imgui-node-editor is using outdated ImGui code, namely

IMGUI_API bool IsClippedEx(const ImRect& bb, ImGuiID id, bool clip_even_when_logged);
instead of the newer
IMGUI_API bool IsClippedEx(const ImRect& bb, ImGuiID id);
(see https://github.com/ocornut/imgui/blob/1b215ecb018ba0fd170618366ddc4be9bd45f283/imgui_internal.h#L2699) (it also applies to the master branch).

this is true for both the master and develop branch of imgui-node-editor.

I will continue working on my patch without worrying about imgui-node-editor, not sure how you'll want to proceed once I am done

@SpaiR
Copy link
Owner

SpaiR commented Nov 2, 2021

Yeah, I saw that too. I'm planning to do a fork with a patched code. So yes, don't mind about that.

@Tyruiop
Copy link
Contributor Author

Tyruiop commented Nov 2, 2021

The demo is with a working minimap now! There are quite a few other updates in the code to match the latest version of ImNodes, if you need me to, I'll document them

@Tyruiop
Copy link
Contributor Author

Tyruiop commented Nov 14, 2021

@SpaiR hi, any feedback on the PR ? :)

@SpaiR
Copy link
Owner

SpaiR commented Nov 14, 2021

@Tyruiop Sorry for a long response.
Basically, the PR looks good. I don't see anything major to fix. Yet in the mean time I'm a little bit into stuff, so not sure how soon I'll be able to merge the PR. The main blocker is imgui-node-editor changes and dear imgui update in general which is required as well. That requires attention, but I will come to it for sure.

@SpaiR SpaiR added 3rd party feat New feature or request labels Nov 14, 2021
@SpaiR
Copy link
Owner

SpaiR commented Dec 1, 2021

@Tyruiop I've made a new realease with an updated Dear ImGui and imgui-node-editor as well. Can you rebase your PR and tweak the code, so I will do a review for changes?

@Tyruiop
Copy link
Contributor Author

Tyruiop commented Dec 2, 2021

@SpaiR sounds good, will work on it this weekend

@Tyruiop
Copy link
Contributor Author

Tyruiop commented Dec 4, 2021

@SpaiR done!

@SpaiR
Copy link
Owner

SpaiR commented Dec 4, 2021

Can you rollback all changes about imgui-node-editor?

@Tyruiop
Copy link
Contributor Author

Tyruiop commented Dec 4, 2021

Right, forgot about at, working on it

@Tyruiop
Copy link
Contributor Author

Tyruiop commented Dec 4, 2021

@SpaiR done, I tested the demo, imgui-node-editor, imnodes, and the file explorer all work

@SpaiR SpaiR linked an issue Dec 5, 2021 that may be closed by this pull request
@SpaiR SpaiR merged commit a78f0b9 into SpaiR:master Dec 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Adding ImNodes MiniMap support
2 participants