From 6d52efe452aa8469e0343da1c7d108f3f52ab651 Mon Sep 17 00:00:00 2001 From: Brad Kittenbrink Date: Wed, 27 Feb 2008 18:58:14 +0000 Subject: Merge of windlight into release (QAR-286). This includes all changes in windlight14 which have passed QA (up through r79932). svn merge -r 80831:80833 svn+ssh://svn.lindenlab.com/svn/linden/branches/merge_windlight14_r80620 --- indra/llwindow/llwindowmacosx.cpp | 29 ++++++++++++++++------------- 1 file changed, 16 insertions(+), 13 deletions(-) (limited to 'indra/llwindow/llwindowmacosx.cpp') diff --git a/indra/llwindow/llwindowmacosx.cpp b/indra/llwindow/llwindowmacosx.cpp index fe127b407e..5184a6caec 100644 --- a/indra/llwindow/llwindowmacosx.cpp +++ b/indra/llwindow/llwindowmacosx.cpp @@ -42,6 +42,7 @@ #include "llgl.h" #include "llstring.h" #include "lldir.h" +#include "llviewercontrol.h" #include "llglheaders.h" @@ -800,22 +801,24 @@ BOOL LLWindowMacOSX::createContext(int x, int y, int width, int height, int bits } aglSetInteger(mContext, AGL_SWAP_INTERVAL, &frames_per_swap); -#if 0 // SJB: Got a compile error. Plus I don't want to test this along with everything else ; save it for later //enable multi-threaded OpenGL - CGLError cgl_err; - CGLContextObj ctx = CGLGetCurrentContext(); - - cgl_err = CGLEnable( ctx, kCGLCEMPEngine); - - if (cgl_err != kCGLNoError ) - { - llinfos << "Multi-threaded OpenGL not available." << llendl; - } - else + if (gSavedSettings.getBOOL("RenderAppleUseMultGL")) { - llinfos << "Multi-threaded OpenGL enabled." << llendl; + CGLError cgl_err; + CGLContextObj ctx = CGLGetCurrentContext(); + + cgl_err = CGLEnable( ctx, kCGLCEMPEngine); + + if (cgl_err != kCGLNoError ) + { + llinfos << "Multi-threaded OpenGL not available." << llendl; + } + else + { + llinfos << "Multi-threaded OpenGL enabled." << llendl; + } } -#endif + // Don't need to get the current gamma, since there's a call that restores it to the system defaults. return TRUE; } -- cgit v1.2.3