Reputation: 8836
I understand that Cocoa requires that windows be created/managed on the main thread. So, I'd like to have two or three windows with unique contexts, but I'd really prefer to draw to each of them from separate threads. Plus, a little bit of Google searching seems to indicate that rapidly context-switching on one thread is pretty expensive/slow.
Upvotes: 3
Views: 401
Reputation: 22358
You might want to look at the CGL interface for fast context switching, specifically: CGLSetCurrentContext
. However, it may be more consistent to use the makeCurrentContext
method for NSOpenGLContext in a Cocoa application.
Upvotes: 1