aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/gpu
diff options
context:
space:
mode:
authorGravatar robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2012-08-31 13:07:37 +0000
committerGravatar robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2012-08-31 13:07:37 +0000
commit5955202c805c7ef1448103cbf666972ea9d1ded1 (patch)
treea52138986487e576f4fef63652ec690d2a7e125d /include/gpu
parentdc1a3badc702dd47d903863208315ddda660dbb9 (diff)
Allow cache tracking to be enabled in release
Diffstat (limited to 'include/gpu')
-rw-r--r--include/gpu/GrConfig.h5
-rw-r--r--include/gpu/GrContext.h3
2 files changed, 7 insertions, 1 deletions
diff --git a/include/gpu/GrConfig.h b/include/gpu/GrConfig.h
index 327dbb44b1..c61c34e193 100644
--- a/include/gpu/GrConfig.h
+++ b/include/gpu/GrConfig.h
@@ -11,6 +11,8 @@
#ifndef GrConfig_DEFINED
#define GrConfig_DEFINED
+#include "SkTypes.h"
+
///////////////////////////////////////////////////////////////////////////////
// preconfig section:
//
@@ -48,6 +50,9 @@
#if !defined(GR_QNX_BUILD)
#define GR_QNX_BUILD 0
#endif
+#if !defined(GR_CACHE_STATS)
+ #define GR_CACHE_STATS 0
+#endif
/**
* If no build target has been defined, attempt to infer.
diff --git a/include/gpu/GrContext.h b/include/gpu/GrContext.h
index d4657a76e5..f456a81ad2 100644
--- a/include/gpu/GrContext.h
+++ b/include/gpu/GrContext.h
@@ -10,6 +10,7 @@
#ifndef GrContext_DEFINED
#define GrContext_DEFINED
+#include "GrConfig.h"
#include "GrPaint.h"
#include "GrAARectRenderer.h"
#include "GrClipData.h"
@@ -775,7 +776,7 @@ public:
bool antiAlias,
bool allowSW);
-#ifdef GR_DEBUG
+#if GR_CACHE_STATS
void printCacheStats() const;
#endif