Skip to content
This repository has been archived by the owner on Feb 11, 2021. It is now read-only.

Commit

Permalink
Added code to enable multi-threaded OpenGL on Mac OS X, pending Ryan'…
Browse files Browse the repository at this point in the history
…s PBO/VBO

changes.
  • Loading branch information
slouken committed Aug 15, 2007
1 parent e9f192a commit 04bc3fc
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/video/SDL_renderer_gl.c
Expand Up @@ -30,6 +30,10 @@
#include "SDL_rect_c.h"
#include "SDL_yuv_sw_c.h"

#ifdef __MACOSX__
#include <OpenGL/OpenGL.h>
#endif

/* OpenGL renderer implementation */

/* Details on optimizing the texture path on Mac OS X:
Expand Down Expand Up @@ -292,6 +296,13 @@ GL_CreateRenderer(SDL_Window * window, Uint32 flags)
return NULL;
}

#ifdef __MACOSX__
/* Enable multi-threaded rendering */
/* Disabled until Ryan finishes his VBO/PBO code...
CGLEnable(CGLGetCurrentContext(), kCGLCEMPEngine);
*/
#endif

if (flags & SDL_RENDERER_PRESENTVSYNC) {
SDL_GL_SetSwapInterval(1);
} else {
Expand Down

0 comments on commit 04bc3fc

Please sign in to comment.