| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2011 Google Inc. | 3 * Copyright 2011 Google Inc. |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 | 9 |
| 10 #include "GrContext.h" | 10 #include "GrContext.h" |
| (...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 197 delete fDrawBufferIBAllocPool; | 197 delete fDrawBufferIBAllocPool; |
| 198 fDrawBufferIBAllocPool = NULL; | 198 fDrawBufferIBAllocPool = NULL; |
| 199 | 199 |
| 200 fAARectRenderer->reset(); | 200 fAARectRenderer->reset(); |
| 201 | 201 |
| 202 fTextureCache->purgeAllUnlocked(); | 202 fTextureCache->purgeAllUnlocked(); |
| 203 fFontCache->freeAll(); | 203 fFontCache->freeAll(); |
| 204 fGpu->markContextDirty(); | 204 fGpu->markContextDirty(); |
| 205 } | 205 } |
| 206 | 206 |
| 207 void GrContext::resetContext() { | 207 void GrContext::resetContext(uint32_t state) { |
| 208 fGpu->markContextDirty(); | 208 fGpu->markContextDirty(state); |
| 209 } | 209 } |
| 210 | 210 |
| 211 void GrContext::freeGpuResources() { | 211 void GrContext::freeGpuResources() { |
| 212 this->flush(); | 212 this->flush(); |
| 213 | 213 |
| 214 fGpu->purgeResources(); | 214 fGpu->purgeResources(); |
| 215 | 215 |
| 216 fAARectRenderer->reset(); | 216 fAARectRenderer->reset(); |
| 217 | 217 |
| 218 fTextureCache->purgeAllUnlocked(); | 218 fTextureCache->purgeAllUnlocked(); |
| (...skipping 1629 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1848 return srcTexture; | 1848 return srcTexture; |
| 1849 } | 1849 } |
| 1850 } | 1850 } |
| 1851 | 1851 |
| 1852 /////////////////////////////////////////////////////////////////////////////// | 1852 /////////////////////////////////////////////////////////////////////////////// |
| 1853 #if GR_CACHE_STATS | 1853 #if GR_CACHE_STATS |
| 1854 void GrContext::printCacheStats() const { | 1854 void GrContext::printCacheStats() const { |
| 1855 fTextureCache->printStats(); | 1855 fTextureCache->printStats(); |
| 1856 } | 1856 } |
| 1857 #endif | 1857 #endif |
| OLD | NEW |