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

Upgrading to latest imgui and implot #17

Open
aybe opened this issue Feb 21, 2023 · 2 comments
Open

Upgrading to latest imgui and implot #17

aybe opened this issue Feb 21, 2023 · 2 comments

Comments

@aybe
Copy link
Owner

aybe commented Feb 21, 2023

Upgrading to imgui 1.89.3 and latest implot does build fine but CppSharp is having a hard time generating the bindings:

Running DearImGui.Generator
Generation starting...
Generating for X86 in C:\Users\aybe\source\repos\DearImGui\DearImGui.Generator\bin\Debug\net6.0\X86\ImGui.cs...
Parsing libraries...
Parsing code...
Parsed 'imgui.h'
Processing code...
Removed 3 passes of type CppSharp.Passes.CheckIgnoredDeclsPass in PreprocessPasses
Removed 1 passes of type CppSharp.Passes.CleanCommentsPass in PreprocessPasses
Changed usage to 'InOut' for parameter 'mouse_pos' in function 'IsMousePosValid'.
Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
   at DearGenerator.Library.Ignore(ASTContext ctx, String className, String memberName, IgnoreType ignoreType) in C:\Users\aybe\source\repos\DearImGui\DearGenerator\Library.cs:line 53
   at DearGenerator.Library.PreprocessIgnores(ASTContext ctx) in C:\Users\aybe\source\repos\DearImGui\DearGenerator\Library.cs:line 212
   at DearGenerator.Library.Preprocess(Driver driver, ASTContext ctx) in C:\Users\aybe\source\repos\DearImGui\DearGenerator\Library.cs:line 285
   at CppSharp.ConsoleDriver.Run(ILibrary library)
   at DearGenerator.CodeGenerator.Generate(String module, String sourceDirectory, String targetDirectory, CodeGeneratorFactory factory, CodeGeneratorTransform transform) in C:\Users\aybe\source\repos\DearImGui\DearGenerator\CodeGenerator.cs:line 352
   at DearGenerator.CodeGenerator.Generate(String module, String sourceDirectory, String targetDirectory, CodeGeneratorFactory factory, CodeGeneratorTransform transform) in C:\Users\aybe\source\repos\DearImGui\DearGenerator\CodeGenerator.cs:line 361
   at DearImGui.Generator.Program.Main() in C:\Users\aybe\source\repos\DearImGui\DearImGui.Generator\Program.cs:line 9
   at DearImGui.Generator.Program.<Main>()
Aborting, last command failed with error code -532462766
@aybe aybe mentioned this issue Feb 28, 2023
@nitrog0d
Copy link

nitrog0d commented Mar 4, 2023

It's erroring cause it's trying to ignore something that doesn't exist anymore it seems, commenting it out works.
I managed to update it to latest ImGui, just had to comment a few ignore lines.

aybe added a commit that referenced this issue Mar 8, 2023
Co-Authored-By: nitro <[email protected]>
@aybe
Copy link
Owner Author

aybe commented Mar 8, 2023

Yep, thanks, fixed it 32cd37b, I've added you as co-author ofc 😁

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

No branches or pull requests

2 participants