cl-opengl icon indicating copy to clipboard operation
cl-opengl copied to clipboard

OSX threading stuff needs work

Open 3b opened this issue 16 years ago • 8 comments

OSX requires GL/GLUT stuff to be done from initial thread.

CCL uses first thread internally by default, so need to rearrange threads there.

SBCL should work if cl-opengl is loaded before slime, or slime isn't using :spawn communication style

not sure about other lisps...

3b avatar Nov 30 '09 04:11 3b

FYI, I've started working on this issue. Feedback would be welcome, particularly regarding the general feasibility of the approach of interrupting the initial thread to run the main loop.

luismbo avatar May 26 '11 02:05 luismbo

080d001199adae17056a takes your feedback into account and adds a few more cleanups. Next step is to port this to bordeaux-threads which might require augmenting it with some interface to get the initial-thread. Any objections to depending on bordeaux-threads on darwin?

luismbo avatar May 27 '11 00:05 luismbo

Has there been any progress on this?

davorb avatar Mar 17 '13 16:03 davorb

For what it's worth, I could run all the examples fine on OSX (with SBCL) using this: https://github.com/Shinmera/trivial-main-thread to ensure I call display-window from the main thread.

epeld avatar Apr 01 '16 20:04 epeld

@epeld Nice. Want to submit a pull request using that on OS X?

luismbo avatar Apr 02 '16 21:04 luismbo

@luismbo Sure, I will give it a shot but it might take a while. I'm new to lisp and haven't even been able to figure out how to load the project from its .asd-files yet..

epeld avatar Apr 03 '16 12:04 epeld

@epeld heh, that's OK. How are you loading it now?

luismbo avatar Apr 03 '16 15:04 luismbo

@luismbo I was using quicklisp and just editing the source that emacs brought me to after M-.. But I figured that wouldn't work once I forked the repo..

This is what I did anyway: https://github.com/epeld/cl-opengl/commit/1532421c34f777bc830e4c6dd97ac41a24adbdaf

epeld avatar Apr 05 '16 20:04 epeld