| Summary: | OpenGL contexts in threads | ||
|---|---|---|---|
| Product: | SDL | Reporter: | Alex Szpakowski <amaranth72> |
| Component: | video | Assignee: | Sam Lantinga <slouken> |
| Status: | RESOLVED FIXED | QA Contact: | Sam Lantinga <slouken> |
| Severity: | normal | ||
| Priority: | P2 | ||
| Version: | HG 2.0 | ||
| Hardware: | All | ||
| OS: | All | ||
|
Description
Alex Szpakowski
2013-07-08 18:14:23 UTC
Part of this has been addressed, where SDL_GL_MakeCurrent only early exits if it's called on the same thread: http://hg.libsdl.org/SDL/rev/e4b98404baa4 There is obviously more work to do to properly handle threads. This is fixed with changeset: http://hg.libsdl.org/SDL/rev/50211a1fd557 The SDL OpenGL context code is now properly thread aware. There are two new functions which return the current OpenGL window and context for the current thread. There are still places in the cocoa driver where the OpenGL context needs to be updated when the view changes. These will need a different solution and still use the last globally set context to avoid changing behavior. Thanks! |