I'm interested in making little games with Erlang. I've made a super basic NIF binding to SDL in order to test this out. When I try to open a window with SDL, however, I get this error message:
Error creating window: NSWindow drag regions should only be invalidated on the Main Thread!
(This is on MacOS btw, hence the NSWindow)
How do I ensure that my Erlang code runs on the "main thread"?
I've tried it with running Erlang with SMP disabled, which my understanding was that then it'd run single-threaded. But I still get the same error.