HFO4/gameboy.live

Issue with High Sierra

andydotxyz opened this issue · 1 comments

Since merging in #10 the app has been working but today I tested on mac OS High Sierra and saw a lot of

2019-05-14 23:30:17.338 main[50763:1244727] pid(50763)/euid(501) is calling TIS/TSM in non-main thread environment, ERROR : This is NOT allowed. Please call TIS/TSM in main thread!!!

and the app never started.
It seems like the "core.Run()" is required to be called from the main thread on mac OS that is not required on Linux.

I cannot seem to get to the bottom of this so thought I would log this issue instead.
I suspect that there are some OS input handling baked into the core package that I did not find when extracting the last of the graphics code to the "driver" package.

It seems that macOS requires that the speaker run on the main thread. The proposed pull request fixes this and should resolve the issues for this gui driver. It unfortunately creates new problems for a Fyne based driver as the render thread blocks. I will try to learn how a speaker loop and a graphics loop could be interpolated...