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

Add OSX + Metal Backend #10

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Add OSX + Metal Backend #10

wants to merge 2 commits into from

Conversation

jrachele
Copy link

Hello,

I'm currently writing a Zig project that requires me to mess with Cocoa directly, so I decided to add the OSX/Metal backends from ImGui to this project. I took these from the v1.91.0 tagged backends: https://github.com/ocornut/imgui/blob/v1.91.0/backends

Zig changes:

  • Add backend_osx.zig, and backend_osx_metal.zig, which follow the same patterns as the other backends
  • Add objective C flags to build script to disable various warnings that Zig treats as errors

ImGui changes:

  • extern "C" {} wrappings around the exposed Objective C functions in both osx and metal backends.
  • Removed GameController support from imgui_impl_metal.mm as it was unhappy on macOS 10.15

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

Successfully merging this pull request may close these issues.

1 participant