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 | 10 |
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
170 * | 170 * |
171 * The issue is tracked at: | 171 * The issue is tracked at: |
172 * http://code.google.com/p/chromium/issues/detail?id=114865 | 172 * http://code.google.com/p/chromium/issues/detail?id=114865 |
173 * | 173 * |
174 * When the workaround is enabled we will use the glBufferData / glBufferSubData | 174 * When the workaround is enabled we will use the glBufferData / glBufferSubData |
175 * trick every 128 array buffer uploads. | 175 * trick every 128 array buffer uploads. |
176 * | 176 * |
177 * Hopefully we will understand this better and have a cleaner fix or get a | 177 * Hopefully we will understand this better and have a cleaner fix or get a |
178 * OS/driver level fix. | 178 * OS/driver level fix. |
179 */ | 179 */ |
180 #define GR_GL_MAC_BUFFER_OBJECT_PERFOMANCE_WORKAROUND \ | 180 #if (defined(SK_BUILD_FOR_MAC) && !GR_GL_USE_BUFFER_DATA_NULL_HINT) |
181 (defined(SK_BUILD_FOR_MAC) && \ | 181 # define GR_GL_MAC_BUFFER_OBJECT_PERFOMANCE_WORKAROUND 1 |
182 !GR_GL_USE_BUFFER_DATA_NULL_HINT) | 182 #else |
| 183 # define GR_GL_MAC_BUFFER_OBJECT_PERFOMANCE_WORKAROUND 0 |
| 184 #endif |
183 | 185 |
184 #endif | 186 #endif |
OLD | NEW |