*
* Permission to use, copy, modify, distribute, and sell this software and its
* documentation for any purpose is hereby granted without fee, provided that
*
* Permission to use, copy, modify, distribute, and sell this software and its
* documentation for any purpose is hereby granted without fee, provided that
// Enable multi-threading, if possible. This runs most OpenGL commands
// and GPU management on a second CPU.
{
// Enable multi-threading, if possible. This runs most OpenGL commands
// and GPU management on a second CPU.
{
CGLError err = CGLEnable (cctx, kCGLCEMPEngine);
if (err != kCGLNoError) {
NSLog (@"enabling multi-threaded OpenGL failed: %d", err);
CGLError err = CGLEnable (cctx, kCGLCEMPEngine);
if (err != kCGLNoError) {
NSLog (@"enabling multi-threaded OpenGL failed: %d", err);