OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 | 8 |
9 #ifndef GrGLStencilBuffer_DEFINED | 9 #ifndef GrGLStencilBuffer_DEFINED |
10 #define GrGLStencilBuffer_DEFINED | 10 #define GrGLStencilBuffer_DEFINED |
(...skipping 25 matching lines...) Expand all Loading... |
36 } | 36 } |
37 | 37 |
38 GrGLuint renderbufferID() const { | 38 GrGLuint renderbufferID() const { |
39 return fRenderbufferID; | 39 return fRenderbufferID; |
40 } | 40 } |
41 | 41 |
42 const Format& format() const { return fFormat; } | 42 const Format& format() const { return fFormat; } |
43 | 43 |
44 protected: | 44 protected: |
45 // overrides of GrResource | 45 // overrides of GrResource |
46 virtual void onRelease() SK_OVERRIDE; | 46 void onRelease() SK_OVERRIDE; |
47 virtual void onAbandon() SK_OVERRIDE; | 47 void onAbandon() SK_OVERRIDE; |
48 | 48 |
49 private: | 49 private: |
50 virtual size_t onGpuMemorySize() const SK_OVERRIDE; | 50 size_t onGpuMemorySize() const SK_OVERRIDE; |
51 | 51 |
52 Format fFormat; | 52 Format fFormat; |
53 // may be zero for external SBs associated with external RTs | 53 // may be zero for external SBs associated with external RTs |
54 // (we don't require the client to give us the id, just tell | 54 // (we don't require the client to give us the id, just tell |
55 // us how many bits of stencil there are). | 55 // us how many bits of stencil there are). |
56 GrGLuint fRenderbufferID; | 56 GrGLuint fRenderbufferID; |
57 | 57 |
58 typedef GrStencilBuffer INHERITED; | 58 typedef GrStencilBuffer INHERITED; |
59 }; | 59 }; |
60 | 60 |
61 #endif | 61 #endif |
OLD | NEW |