OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2006 The Android Open Source Project | 2 * Copyright 2006 The Android Open Source Project |
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 #ifndef SkPostConfig_DEFINED | 8 #ifndef SkPostConfig_DEFINED |
9 #define SkPostConfig_DEFINED | 9 #define SkPostConfig_DEFINED |
10 | 10 |
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
295 // Clang defaults to C++03 and warns about using override. Squelch that. In
tentionally no | 295 // Clang defaults to C++03 and warns about using override. Squelch that. In
tentionally no |
296 // push/pop here so all users of SK_OVERRIDE ignore the warning too. This i
s like passing | 296 // push/pop here so all users of SK_OVERRIDE ignore the warning too. This i
s like passing |
297 // -Wno-c++11-extensions, except that GCC won't die (because it won't see t
his pragma). | 297 // -Wno-c++11-extensions, except that GCC won't die (because it won't see t
his pragma). |
298 # pragma clang diagnostic ignored "-Wc++11-extensions" | 298 # pragma clang diagnostic ignored "-Wc++11-extensions" |
299 # | 299 # |
300 # if __has_feature(cxx_override_control) | 300 # if __has_feature(cxx_override_control) |
301 # define SK_OVERRIDE override | 301 # define SK_OVERRIDE override |
302 # elif defined(__has_extension) && __has_extension(cxx_override_control) | 302 # elif defined(__has_extension) && __has_extension(cxx_override_control) |
303 # define SK_OVERRIDE override | 303 # define SK_OVERRIDE override |
304 # endif | 304 # endif |
| 305 // if GCC >= 4.7 |
| 306 # elif defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >
= 7)) |
| 307 # define SK_OVERRIDE override |
305 # endif | 308 # endif |
306 # ifndef SK_OVERRIDE | 309 # ifndef SK_OVERRIDE |
307 # define SK_OVERRIDE | 310 # define SK_OVERRIDE |
308 # endif | 311 # endif |
309 #endif | 312 #endif |
310 | 313 |
311 ////////////////////////////////////////////////////////////////////// | 314 ////////////////////////////////////////////////////////////////////// |
312 | 315 |
313 #if !defined(SK_UNUSED) | 316 #if !defined(SK_UNUSED) |
314 # define SK_UNUSED SK_ATTRIBUTE(unused) | 317 # define SK_UNUSED SK_ATTRIBUTE(unused) |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
391 | 394 |
392 #if defined(SK_GAMMA_EXPONENT) && defined(SK_GAMMA_SRGB) | 395 #if defined(SK_GAMMA_EXPONENT) && defined(SK_GAMMA_SRGB) |
393 # error "cannot define both SK_GAMMA_EXPONENT and SK_GAMMA_SRGB" | 396 # error "cannot define both SK_GAMMA_EXPONENT and SK_GAMMA_SRGB" |
394 #elif defined(SK_GAMMA_SRGB) | 397 #elif defined(SK_GAMMA_SRGB) |
395 # define SK_GAMMA_EXPONENT (0.0f) | 398 # define SK_GAMMA_EXPONENT (0.0f) |
396 #elif !defined(SK_GAMMA_EXPONENT) | 399 #elif !defined(SK_GAMMA_EXPONENT) |
397 # define SK_GAMMA_EXPONENT (2.2f) | 400 # define SK_GAMMA_EXPONENT (2.2f) |
398 #endif | 401 #endif |
399 | 402 |
400 #endif // SkPostConfig_DEFINED | 403 #endif // SkPostConfig_DEFINED |
OLD | NEW |