diff options
author | reed@google.com <reed@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-06-26 20:16:17 +0000 |
---|---|---|
committer | reed@google.com <reed@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-06-26 20:16:17 +0000 |
commit | fa35e3ddcc9d130ce87c927218bdf27879c38711 (patch) | |
tree | 5b15d2c18285d887e2b65fd824bb4afbeb758f71 /src/gpu/gl | |
parent | a23d04820955e2c459956a6610063545d3e8f1aa (diff) |
plumb SkInstCnt to all subclasses of GrRefCnt
git-svn-id: http://skia.googlecode.com/svn/trunk@4353 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src/gpu/gl')
-rw-r--r-- | src/gpu/gl/GrGLTexture.cpp | 4 | ||||
-rw-r--r-- | src/gpu/gl/GrGLTexture.h | 5 |
2 files changed, 6 insertions, 3 deletions
diff --git a/src/gpu/gl/GrGLTexture.cpp b/src/gpu/gl/GrGLTexture.cpp index 476d3e7e41..9c6743a3b8 100644 --- a/src/gpu/gl/GrGLTexture.cpp +++ b/src/gpu/gl/GrGLTexture.cpp @@ -5,11 +5,11 @@ * found in the LICENSE file. */ - #include "GrGLTexture.h" - #include "GrGpuGL.h" +SK_DEFINE_INST_COUNT(GrGLTexID) + #define GPUGL static_cast<GrGpuGL*>(getGpu()) #define GL_CALL(X) GR_GL_CALL(GPUGL->glInterface(), X) diff --git a/src/gpu/gl/GrGLTexture.h b/src/gpu/gl/GrGLTexture.h index e408e5db94..8e8c8c5da4 100644 --- a/src/gpu/gl/GrGLTexture.h +++ b/src/gpu/gl/GrGLTexture.h @@ -16,8 +16,9 @@ * A ref counted tex id that deletes the texture in its destructor. */ class GrGLTexID : public GrRefCnt { - public: + SK_DECLARE_INST_COUNT(GrGLTexID) + GrGLTexID(const GrGLInterface* gl, GrGLuint texID, bool ownsID) : fGL(gl) , fTexID(texID) @@ -37,6 +38,8 @@ private: const GrGLInterface* fGL; GrGLuint fTexID; bool fOwnsID; + + typedef GrRefCnt INHERITED; }; //////////////////////////////////////////////////////////////////////////////// |