bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 1 | /* |
epoger@google.com | ec3ed6a | 2011-07-28 14:26:00 +0000 | [diff] [blame] | 2 | * Copyright 2010 Google Inc. |
| 3 | * |
| 4 | * Use of this source code is governed by a BSD-style license that can be |
| 5 | * found in the LICENSE file. |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 6 | */ |
| 7 | |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 8 | #ifndef GrBufferAllocPool_DEFINED |
| 9 | #define GrBufferAllocPool_DEFINED |
| 10 | |
Mike Klein | c0bd9f9 | 2019-04-23 12:05:21 -0500 | [diff] [blame] | 11 | #include "include/core/SkTypes.h" |
| 12 | #include "include/private/GrTypesPriv.h" |
| 13 | #include "include/private/SkNoncopyable.h" |
| 14 | #include "include/private/SkTArray.h" |
| 15 | #include "include/private/SkTDArray.h" |
| 16 | #include "src/gpu/GrCpuBuffer.h" |
| 17 | #include "src/gpu/GrNonAtomicRef.h" |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 18 | |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 19 | class GrGpu; |
| 20 | |
| 21 | /** |
| 22 | * A pool of geometry buffers tied to a GrGpu. |
| 23 | * |
| 24 | * The pool allows a client to make space for geometry and then put back excess |
| 25 | * space if it over allocated. When a client is ready to draw from the pool |
commit-bot@chromium.org | 8341eb7 | 2014-05-07 20:51:05 +0000 | [diff] [blame] | 26 | * it calls unmap on the pool ensure buffers are ready for drawing. The pool |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 27 | * can be reset after drawing is completed to recycle space. |
| 28 | * |
| 29 | * At creation time a minimum per-buffer size can be specified. Additionally, |
| 30 | * a number of buffers to preallocate can be specified. These will |
| 31 | * be allocated at the min size and kept around until the pool is destroyed. |
| 32 | */ |
commit-bot@chromium.org | e3beb6b | 2014-04-07 19:34:38 +0000 | [diff] [blame] | 33 | class GrBufferAllocPool : SkNoncopyable { |
bsalomon@google.com | 11f0b51 | 2011-03-29 20:52:23 +0000 | [diff] [blame] | 34 | public: |
Brian Salomon | 58f153c | 2018-10-18 21:51:15 -0400 | [diff] [blame] | 35 | static constexpr size_t kDefaultBufferSize = 1 << 15; |
| 36 | |
bsalomon@google.com | 11f0b51 | 2011-03-29 20:52:23 +0000 | [diff] [blame] | 37 | /** |
Brian Salomon | 601ac80 | 2019-02-07 13:37:16 -0500 | [diff] [blame] | 38 | * A cache object that can be shared by multiple GrBufferAllocPool instances. It caches |
| 39 | * cpu buffer allocations to avoid reallocating them. |
| 40 | */ |
| 41 | class CpuBufferCache : public GrNonAtomicRef<CpuBufferCache> { |
| 42 | public: |
| 43 | static sk_sp<CpuBufferCache> Make(int maxBuffersToCache); |
| 44 | |
| 45 | sk_sp<GrCpuBuffer> makeBuffer(size_t size, bool mustBeInitialized); |
| 46 | void releaseAll(); |
| 47 | |
| 48 | private: |
| 49 | CpuBufferCache(int maxBuffersToCache); |
| 50 | |
| 51 | struct Buffer { |
| 52 | sk_sp<GrCpuBuffer> fBuffer; |
| 53 | bool fCleared = false; |
| 54 | }; |
| 55 | std::unique_ptr<Buffer[]> fBuffers; |
| 56 | int fMaxBuffersToCache = 0; |
| 57 | }; |
| 58 | |
| 59 | /** |
commit-bot@chromium.org | 8341eb7 | 2014-05-07 20:51:05 +0000 | [diff] [blame] | 60 | * Ensures all buffers are unmapped and have all data written to them. |
bsalomon@google.com | 11f0b51 | 2011-03-29 20:52:23 +0000 | [diff] [blame] | 61 | * Call before drawing using buffers from the pool. |
| 62 | */ |
commit-bot@chromium.org | 8341eb7 | 2014-05-07 20:51:05 +0000 | [diff] [blame] | 63 | void unmap(); |
bsalomon@google.com | 11f0b51 | 2011-03-29 20:52:23 +0000 | [diff] [blame] | 64 | |
| 65 | /** |
| 66 | * Invalidates all the data in the pool, unrefs non-preallocated buffers. |
| 67 | */ |
| 68 | void reset(); |
| 69 | |
| 70 | /** |
bsalomon@google.com | 11f0b51 | 2011-03-29 20:52:23 +0000 | [diff] [blame] | 71 | * Frees data from makeSpaces in LIFO order. |
| 72 | */ |
| 73 | void putBack(size_t bytes); |
| 74 | |
bsalomon@google.com | 11f0b51 | 2011-03-29 20:52:23 +0000 | [diff] [blame] | 75 | protected: |
| 76 | /** |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 77 | * Constructor |
| 78 | * |
| 79 | * @param gpu The GrGpu used to create the buffers. |
| 80 | * @param bufferType The type of buffers to create. |
Brian Salomon | 601ac80 | 2019-02-07 13:37:16 -0500 | [diff] [blame] | 81 | * @param cpuBufferCache If non-null a cache for client side array buffers |
| 82 | * or staging buffers used before data is uploaded to |
| 83 | * GPU buffer objects. |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 84 | */ |
Brian Salomon | 601ac80 | 2019-02-07 13:37:16 -0500 | [diff] [blame] | 85 | GrBufferAllocPool(GrGpu* gpu, GrGpuBufferType bufferType, sk_sp<CpuBufferCache> cpuBufferCache); |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 86 | |
Brian Salomon | 58f153c | 2018-10-18 21:51:15 -0400 | [diff] [blame] | 87 | virtual ~GrBufferAllocPool(); |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 88 | |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 89 | /** |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 90 | * Returns a block of memory to hold data. A buffer designated to hold the |
| 91 | * data is given to the caller. The buffer may or may not be locked. The |
| 92 | * returned ptr remains valid until any of the following: |
| 93 | * *makeSpace is called again. |
commit-bot@chromium.org | 8341eb7 | 2014-05-07 20:51:05 +0000 | [diff] [blame] | 94 | * *unmap is called. |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 95 | * *reset is called. |
| 96 | * *this object is destroyed. |
| 97 | * |
commit-bot@chromium.org | 8341eb7 | 2014-05-07 20:51:05 +0000 | [diff] [blame] | 98 | * Once unmap on the pool is called the data is guaranteed to be in the |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 99 | * buffer at the offset indicated by offset. Until that time it may be |
| 100 | * in temporary storage and/or the buffer may be locked. |
| 101 | * |
| 102 | * @param size the amount of data to make space for |
| 103 | * @param alignment alignment constraint from start of buffer |
| 104 | * @param buffer returns the buffer that will hold the data. |
| 105 | * @param offset returns the offset into buffer of the data. |
| 106 | * @return pointer to where the client should write the data. |
| 107 | */ |
Brian Salomon | 12d2264 | 2019-01-29 14:38:50 -0500 | [diff] [blame] | 108 | void* makeSpace(size_t size, size_t alignment, sk_sp<const GrBuffer>* buffer, size_t* offset); |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 109 | |
Brian Osman | 49b7b6f | 2017-06-20 14:43:58 -0400 | [diff] [blame] | 110 | /** |
| 111 | * Returns a block of memory to hold data. A buffer designated to hold the |
| 112 | * data is given to the caller. The buffer may or may not be locked. The |
| 113 | * returned ptr remains valid until any of the following: |
| 114 | * *makeSpace is called again. |
| 115 | * *unmap is called. |
| 116 | * *reset is called. |
| 117 | * *this object is destroyed. |
| 118 | * |
| 119 | * Once unmap on the pool is called the data is guaranteed to be in the |
| 120 | * buffer at the offset indicated by offset. Until that time it may be |
| 121 | * in temporary storage and/or the buffer may be locked. |
| 122 | * |
| 123 | * The caller requests a minimum number of bytes, but the block may be (much) |
| 124 | * larger. Assuming that a new block must be allocated, it will be fallbackSize bytes. |
| 125 | * The actual block size is returned in actualSize. |
| 126 | * |
| 127 | * @param minSize the minimum amount of data to make space for |
| 128 | * @param fallbackSize the amount of data to make space for if a new block is needed |
| 129 | * @param alignment alignment constraint from start of buffer |
| 130 | * @param buffer returns the buffer that will hold the data. |
| 131 | * @param offset returns the offset into buffer of the data. |
| 132 | * @param actualSize returns the capacity of the block |
| 133 | * @return pointer to where the client should write the data. |
| 134 | */ |
| 135 | void* makeSpaceAtLeast(size_t minSize, |
| 136 | size_t fallbackSize, |
| 137 | size_t alignment, |
Brian Salomon | 12d2264 | 2019-01-29 14:38:50 -0500 | [diff] [blame] | 138 | sk_sp<const GrBuffer>* buffer, |
Brian Osman | 49b7b6f | 2017-06-20 14:43:58 -0400 | [diff] [blame] | 139 | size_t* offset, |
| 140 | size_t* actualSize); |
| 141 | |
Brian Salomon | 12d2264 | 2019-01-29 14:38:50 -0500 | [diff] [blame] | 142 | sk_sp<GrBuffer> getBuffer(size_t size); |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 143 | |
| 144 | private: |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 145 | struct BufferBlock { |
Brian Salomon | 12d2264 | 2019-01-29 14:38:50 -0500 | [diff] [blame] | 146 | size_t fBytesFree; |
| 147 | sk_sp<GrBuffer> fBuffer; |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 148 | }; |
| 149 | |
| 150 | bool createBlock(size_t requestSize); |
| 151 | void destroyBlock(); |
robertphillips | 1b8e1b5 | 2015-06-24 06:54:10 -0700 | [diff] [blame] | 152 | void deleteBlocks(); |
bsalomon | 3512eda | 2014-06-26 12:56:22 -0700 | [diff] [blame] | 153 | void flushCpuData(const BufferBlock& block, size_t flushSize); |
Brian Salomon | 601ac80 | 2019-02-07 13:37:16 -0500 | [diff] [blame] | 154 | void resetCpuData(size_t newSize); |
commit-bot@chromium.org | 515dcd3 | 2013-08-28 14:17:03 +0000 | [diff] [blame] | 155 | #ifdef SK_DEBUG |
bsalomon@google.com | 25fb21f | 2011-06-21 18:17:25 +0000 | [diff] [blame] | 156 | void validate(bool unusedBlockAllowed = false) const; |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 157 | #endif |
Brian Salomon | 58f153c | 2018-10-18 21:51:15 -0400 | [diff] [blame] | 158 | size_t fBytesInUse = 0; |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 159 | |
Brian Salomon | 58f153c | 2018-10-18 21:51:15 -0400 | [diff] [blame] | 160 | SkTArray<BufferBlock> fBlocks; |
Brian Salomon | 601ac80 | 2019-02-07 13:37:16 -0500 | [diff] [blame] | 161 | sk_sp<CpuBufferCache> fCpuBufferCache; |
| 162 | sk_sp<GrCpuBuffer> fCpuStagingBuffer; |
Brian Salomon | 58f153c | 2018-10-18 21:51:15 -0400 | [diff] [blame] | 163 | GrGpu* fGpu; |
Brian Salomon | ae64c19 | 2019-02-05 09:41:37 -0500 | [diff] [blame] | 164 | GrGpuBufferType fBufferType; |
Brian Salomon | 58f153c | 2018-10-18 21:51:15 -0400 | [diff] [blame] | 165 | void* fBufferPtr = nullptr; |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 166 | }; |
| 167 | |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 168 | /** |
| 169 | * A GrBufferAllocPool of vertex buffers |
| 170 | */ |
| 171 | class GrVertexBufferAllocPool : public GrBufferAllocPool { |
| 172 | public: |
| 173 | /** |
| 174 | * Constructor |
| 175 | * |
| 176 | * @param gpu The GrGpu used to create the vertex buffers. |
Brian Salomon | 601ac80 | 2019-02-07 13:37:16 -0500 | [diff] [blame] | 177 | * @param cpuBufferCache If non-null a cache for client side array buffers |
| 178 | * or staging buffers used before data is uploaded to |
| 179 | * GPU buffer objects. |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 180 | */ |
Brian Salomon | 601ac80 | 2019-02-07 13:37:16 -0500 | [diff] [blame] | 181 | GrVertexBufferAllocPool(GrGpu* gpu, sk_sp<CpuBufferCache> cpuBufferCache); |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 182 | |
| 183 | /** |
| 184 | * Returns a block of memory to hold vertices. A buffer designated to hold |
| 185 | * the vertices given to the caller. The buffer may or may not be locked. |
| 186 | * The returned ptr remains valid until any of the following: |
| 187 | * *makeSpace is called again. |
commit-bot@chromium.org | 8341eb7 | 2014-05-07 20:51:05 +0000 | [diff] [blame] | 188 | * *unmap is called. |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 189 | * *reset is called. |
| 190 | * *this object is destroyed. |
| 191 | * |
commit-bot@chromium.org | 8341eb7 | 2014-05-07 20:51:05 +0000 | [diff] [blame] | 192 | * Once unmap on the pool is called the vertices are guaranteed to be in |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 193 | * the buffer at the offset indicated by startVertex. Until that time they |
| 194 | * may be in temporary storage and/or the buffer may be locked. |
| 195 | * |
jvanverth@google.com | a633898 | 2013-01-31 21:34:25 +0000 | [diff] [blame] | 196 | * @param vertexSize specifies size of a vertex to allocate space for |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 197 | * @param vertexCount number of vertices to allocate space for |
| 198 | * @param buffer returns the vertex buffer that will hold the |
| 199 | * vertices. |
| 200 | * @param startVertex returns the offset into buffer of the first vertex. |
| 201 | * In units of the size of a vertex from layout param. |
| 202 | * @return pointer to first vertex. |
| 203 | */ |
jvanverth@google.com | a633898 | 2013-01-31 21:34:25 +0000 | [diff] [blame] | 204 | void* makeSpace(size_t vertexSize, |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 205 | int vertexCount, |
Brian Salomon | 12d2264 | 2019-01-29 14:38:50 -0500 | [diff] [blame] | 206 | sk_sp<const GrBuffer>* buffer, |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 207 | int* startVertex); |
| 208 | |
Brian Osman | 49b7b6f | 2017-06-20 14:43:58 -0400 | [diff] [blame] | 209 | /** |
| 210 | * Returns a block of memory to hold vertices. A buffer designated to hold |
| 211 | * the vertices given to the caller. The buffer may or may not be locked. |
| 212 | * The returned ptr remains valid until any of the following: |
| 213 | * *makeSpace is called again. |
| 214 | * *unmap is called. |
| 215 | * *reset is called. |
| 216 | * *this object is destroyed. |
| 217 | * |
| 218 | * Once unmap on the pool is called the vertices are guaranteed to be in |
| 219 | * the buffer at the offset indicated by startVertex. Until that time they |
| 220 | * may be in temporary storage and/or the buffer may be locked. |
| 221 | * |
| 222 | * The caller requests a minimum number of vertices, but the block may be (much) |
| 223 | * larger. Assuming that a new block must be allocated, it will be sized to hold |
| 224 | * fallbackVertexCount vertices. The actual block size (in vertices) is returned in |
| 225 | * actualVertexCount. |
| 226 | * |
| 227 | * @param vertexSize specifies size of a vertex to allocate space for |
| 228 | * @param minVertexCount minimum number of vertices to allocate space for |
| 229 | * @param fallbackVertexCount number of vertices to allocate space for if a new block is needed |
| 230 | * @param buffer returns the vertex buffer that will hold the vertices. |
| 231 | * @param startVertex returns the offset into buffer of the first vertex. |
| 232 | * In units of the size of a vertex from layout param. |
| 233 | * @param actualVertexCount returns the capacity of the block (in vertices) |
| 234 | * @return pointer to first vertex. |
| 235 | */ |
| 236 | void* makeSpaceAtLeast(size_t vertexSize, |
| 237 | int minVertexCount, |
| 238 | int fallbackVertexCount, |
Brian Salomon | 12d2264 | 2019-01-29 14:38:50 -0500 | [diff] [blame] | 239 | sk_sp<const GrBuffer>* buffer, |
Brian Osman | 49b7b6f | 2017-06-20 14:43:58 -0400 | [diff] [blame] | 240 | int* startVertex, |
| 241 | int* actualVertexCount); |
| 242 | |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 243 | private: |
| 244 | typedef GrBufferAllocPool INHERITED; |
| 245 | }; |
| 246 | |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 247 | /** |
| 248 | * A GrBufferAllocPool of index buffers |
| 249 | */ |
| 250 | class GrIndexBufferAllocPool : public GrBufferAllocPool { |
| 251 | public: |
| 252 | /** |
| 253 | * Constructor |
| 254 | * |
| 255 | * @param gpu The GrGpu used to create the index buffers. |
Brian Salomon | 601ac80 | 2019-02-07 13:37:16 -0500 | [diff] [blame] | 256 | * @param cpuBufferCache If non-null a cache for client side array buffers |
| 257 | * or staging buffers used before data is uploaded to |
| 258 | * GPU buffer objects. |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 259 | */ |
Brian Salomon | 601ac80 | 2019-02-07 13:37:16 -0500 | [diff] [blame] | 260 | GrIndexBufferAllocPool(GrGpu* gpu, sk_sp<CpuBufferCache> cpuBufferCache); |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 261 | |
| 262 | /** |
| 263 | * Returns a block of memory to hold indices. A buffer designated to hold |
| 264 | * the indices is given to the caller. The buffer may or may not be locked. |
| 265 | * The returned ptr remains valid until any of the following: |
| 266 | * *makeSpace is called again. |
commit-bot@chromium.org | 8341eb7 | 2014-05-07 20:51:05 +0000 | [diff] [blame] | 267 | * *unmap is called. |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 268 | * *reset is called. |
| 269 | * *this object is destroyed. |
| 270 | * |
commit-bot@chromium.org | 8341eb7 | 2014-05-07 20:51:05 +0000 | [diff] [blame] | 271 | * Once unmap on the pool is called the indices are guaranteed to be in the |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 272 | * buffer at the offset indicated by startIndex. Until that time they may be |
| 273 | * in temporary storage and/or the buffer may be locked. |
| 274 | * |
| 275 | * @param indexCount number of indices to allocate space for |
| 276 | * @param buffer returns the index buffer that will hold the indices. |
| 277 | * @param startIndex returns the offset into buffer of the first index. |
| 278 | * @return pointer to first index. |
| 279 | */ |
Brian Salomon | 12d2264 | 2019-01-29 14:38:50 -0500 | [diff] [blame] | 280 | void* makeSpace(int indexCount, sk_sp<const GrBuffer>* buffer, int* startIndex); |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 281 | |
Brian Osman | 49b7b6f | 2017-06-20 14:43:58 -0400 | [diff] [blame] | 282 | /** |
| 283 | * Returns a block of memory to hold indices. A buffer designated to hold |
| 284 | * the indices is given to the caller. The buffer may or may not be locked. |
| 285 | * The returned ptr remains valid until any of the following: |
| 286 | * *makeSpace is called again. |
| 287 | * *unmap is called. |
| 288 | * *reset is called. |
| 289 | * *this object is destroyed. |
| 290 | * |
| 291 | * Once unmap on the pool is called the indices are guaranteed to be in the |
| 292 | * buffer at the offset indicated by startIndex. Until that time they may be |
| 293 | * in temporary storage and/or the buffer may be locked. |
| 294 | * |
| 295 | * The caller requests a minimum number of indices, but the block may be (much) |
| 296 | * larger. Assuming that a new block must be allocated, it will be sized to hold |
| 297 | * fallbackIndexCount indices. The actual block size (in indices) is returned in |
| 298 | * actualIndexCount. |
| 299 | * |
| 300 | * @param minIndexCount minimum number of indices to allocate space for |
| 301 | * @param fallbackIndexCount number of indices to allocate space for if a new block is needed |
| 302 | * @param buffer returns the index buffer that will hold the indices. |
| 303 | * @param startIndex returns the offset into buffer of the first index. |
| 304 | * @param actualIndexCount returns the capacity of the block (in indices) |
| 305 | * @return pointer to first index. |
| 306 | */ |
| 307 | void* makeSpaceAtLeast(int minIndexCount, |
| 308 | int fallbackIndexCount, |
Brian Salomon | 12d2264 | 2019-01-29 14:38:50 -0500 | [diff] [blame] | 309 | sk_sp<const GrBuffer>* buffer, |
Brian Osman | 49b7b6f | 2017-06-20 14:43:58 -0400 | [diff] [blame] | 310 | int* startIndex, |
| 311 | int* actualIndexCount); |
| 312 | |
bsalomon@google.com | 1c13c96 | 2011-02-14 16:51:21 +0000 | [diff] [blame] | 313 | private: |
| 314 | typedef GrBufferAllocPool INHERITED; |
| 315 | }; |
| 316 | |
| 317 | #endif |