summaryrefslogtreecommitdiff
path: root/indra/llrender/llgl.h
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llrender/llgl.h')
-rw-r--r--indra/llrender/llgl.h26
1 files changed, 14 insertions, 12 deletions
diff --git a/indra/llrender/llgl.h b/indra/llrender/llgl.h
index d19825d9ca..a7dced3753 100644
--- a/indra/llrender/llgl.h
+++ b/indra/llrender/llgl.h
@@ -31,7 +31,7 @@
#include <functional>
#include <string>
-#include <boost/unordered_map.hpp>
+#include <unordered_map>
#include <list>
#include "llerror.h"
@@ -155,24 +155,26 @@ void rotate_quat(LLQuaternion& rotation);
void flush_glerror(); // Flush GL errors when we know we're handling them correctly.
-void log_glerror();
+void log_glerror(std::string comment);
void assert_glerror();
void clear_glerror();
-# define stop_glerror() assert_glerror()
-# define llglassertok() assert_glerror()
-
-// stop_glerror is still needed on OS X but has performance implications
-// use macro below to conditionally add stop_glerror to non-release builds
-// on OS X
-#if LL_DARWIN && !LL_RELEASE_FOR_DOWNLOAD
-#define STOP_GLERROR stop_glerror()
+//#if !LL_RELEASE_FOR_DOWNLOAD
+#if 1
+# define LOG_GLERROR(COMMENT) log_glerror(COMMENT)
+# define stop_glerror() log_glerror("stop")
+# define llglassertok() log_glerror("ASSERTOK")
+# define STOP_GLERROR log_glerror("STOP")
#else
-#define STOP_GLERROR
+# define LOG_GLERROR(COMMENT)
+# define stop_glerror()
+# define llglassertok()
+# define STOP_GLERROR
#endif
+
#define llglassertok_always() assert_glerror()
////////////////////////
@@ -246,7 +248,7 @@ public:
static void checkStates(GLboolean writeAlpha = GL_TRUE);
protected:
- static boost::unordered_map<LLGLenum, LLGLboolean> sStateMap;
+ static std::unordered_map<LLGLenum, LLGLboolean> sStateMap;
public:
enum { CURRENT_STATE = -2, DISABLED_STATE = 0, ENABLED_STATE = 1 };