| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2006 The Android Open Source Project | 3 * Copyright 2006 The Android Open Source Project |
| 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 #ifndef SkGraphics_DEFINED | 10 #ifndef SkGraphics_DEFINED |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 */ | 53 */ |
| 54 static size_t GetFontCacheUsed(); | 54 static size_t GetFontCacheUsed(); |
| 55 | 55 |
| 56 /** | 56 /** |
| 57 * For debugging purposes, this will attempt to purge the font cache. It | 57 * For debugging purposes, this will attempt to purge the font cache. It |
| 58 * does not change the limit, but will cause subsequent font measures and | 58 * does not change the limit, but will cause subsequent font measures and |
| 59 * draws to be recreated, since they will no longer be in the cache. | 59 * draws to be recreated, since they will no longer be in the cache. |
| 60 */ | 60 */ |
| 61 static void PurgeFontCache(); | 61 static void PurgeFontCache(); |
| 62 | 62 |
| 63 static size_t GetImageCacheBytesUsed(); |
| 64 static size_t GetImageCacheByteLimit(); |
| 65 static size_t SetImageCacheByteLimit(size_t newLimit); |
| 66 |
| 63 /** | 67 /** |
| 64 * Applications with command line options may pass optional state, such | 68 * Applications with command line options may pass optional state, such |
| 65 * as cache sizes, here, for instance: | 69 * as cache sizes, here, for instance: |
| 66 * font-cache-limit=12345678 | 70 * font-cache-limit=12345678 |
| 67 * | 71 * |
| 68 * The flags format is name=value[;name=value...] with no spaces. | 72 * The flags format is name=value[;name=value...] with no spaces. |
| 69 * This format is subject to change. | 73 * This format is subject to change. |
| 70 */ | 74 */ |
| 71 static void SetFlags(const char* flags); | 75 static void SetFlags(const char* flags); |
| 72 | 76 |
| (...skipping 29 matching lines...) Expand all Loading... |
| 102 public: | 106 public: |
| 103 SkAutoGraphics() { | 107 SkAutoGraphics() { |
| 104 SkGraphics::Init(); | 108 SkGraphics::Init(); |
| 105 } | 109 } |
| 106 ~SkAutoGraphics() { | 110 ~SkAutoGraphics() { |
| 107 SkGraphics::Term(); | 111 SkGraphics::Term(); |
| 108 } | 112 } |
| 109 }; | 113 }; |
| 110 | 114 |
| 111 #endif | 115 #endif |
| OLD | NEW |