From 1dcdf6651f07313586fc89bacedf7015ff1f3e29 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Wed, 31 Jul 2013 21:22:09 -0700 Subject: [PATCH] Documented why we have global and thread-local variables for the GL context. --- src/video/SDL_sysvideo.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/video/SDL_sysvideo.h b/src/video/SDL_sysvideo.h index 598782833..4973648c7 100644 --- a/src/video/SDL_sysvideo.h +++ b/src/video/SDL_sysvideo.h @@ -301,6 +301,9 @@ struct SDL_VideoDevice /* * * */ /* Cache current GL context; don't call the OS when it hasn't changed. */ + /* We have the global pointers here so Cocoa continues to work the way + it always has, and the thread-local storage for the general case. + */ SDL_Window *current_glwin; SDL_GLContext current_glctx; SDL_TLSID current_glwin_tls;