| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2014 Google Inc. | 2 * Copyright 2014 Google Inc. |
| 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 #include "SkColor.h" | 8 #include "SkColor.h" |
| 9 #include "SkColorPriv.h" | 9 #include "SkColorPriv.h" |
| 10 #include "SkBlitMask.h" | 10 #include "SkBlitMask.h" |
| 11 #include "SkUtilsArm.h" | 11 #include "SkUtilsArm.h" |
| 12 #include "SkBlitMask_opts_arm_neon.h" | 12 #include "SkBlitMask_opts_arm_neon.h" |
| 13 | 13 |
| 14 SkBlitMask::ColorProc SkBlitMask::PlatformColorProcs(SkColorType dstCT, | 14 SkBlitMask::ColorProc SkBlitMask::PlatformColorProcs(SkColorType dstCT, |
| 15 SkMask::Format maskFormat, | 15 SkMask::Format maskFormat, |
| 16 SkColor color) { | 16 SkColor color) { |
| 17 #if SK_ARM_NEON_IS_NONE | 17 #if SK_ARM_NEON_IS_NONE |
| 18 return NULL; | 18 return NULL; |
| 19 #else | 19 #else |
| 20 /* ** This has been disabled until we can diagnose and fix the SIGILL generated | 20 /* ** This has been disabled until we can diagnose and fix the SIGILL generated |
| 21 ** in the NEON code. See http://skbug.com/2067 for details. | 21 ** in the NEON code. See http://skbug.com/2067 for details. |
| 22 #if SK_ARM_NEON_IS_DYNAMIC | 22 #if SK_ARM_NEON_IS_DYNAMIC |
| 23 if (!sk_cpu_arm_has_neon()) { | 23 if (!sk_cpu_arm_has_neon()) { |
| 24 return NULL; | 24 return NULL; |
| 25 } | 25 } |
| 26 #endif | 26 #endif |
| 27 if ((SkBitmap::kARGB_8888_Config == dstConfig) && | 27 if ((kN32_SkColorType == dstCT) && |
| 28 (SkMask::kA8_Format == maskFormat)) { | 28 (SkMask::kA8_Format == maskFormat)) { |
| 29 return D32_A8_Factory_neon(color); | 29 return D32_A8_Factory_neon(color); |
| 30 } | 30 } |
| 31 */ | 31 */ |
| 32 #endif | 32 #endif |
| 33 | 33 |
| 34 // We don't need to handle the SkMask::kLCD16_Format case as the default | 34 // We don't need to handle the SkMask::kLCD16_Format case as the default |
| 35 // LCD16 will call us through SkBlitMask::PlatformBlitRowProcs16() | 35 // LCD16 will call us through SkBlitMask::PlatformBlitRowProcs16() |
| 36 | 36 |
| 37 return NULL; | 37 return NULL; |
| 38 } | 38 } |
| 39 | 39 |
| 40 SkBlitMask::BlitLCD16RowProc SkBlitMask::PlatformBlitRowProcs16(bool isOpaque) { | 40 SkBlitMask::BlitLCD16RowProc SkBlitMask::PlatformBlitRowProcs16(bool isOpaque) { |
| 41 if (isOpaque) { | 41 if (isOpaque) { |
| 42 return SK_ARM_NEON_WRAP(SkBlitLCD16OpaqueRow); | 42 return SK_ARM_NEON_WRAP(SkBlitLCD16OpaqueRow); |
| 43 } else { | 43 } else { |
| 44 return SK_ARM_NEON_WRAP(SkBlitLCD16Row); | 44 return SK_ARM_NEON_WRAP(SkBlitLCD16Row); |
| 45 } | 45 } |
| 46 } | 46 } |
| 47 | 47 |
| 48 SkBlitMask::RowProc SkBlitMask::PlatformRowProcs(SkColorType dstCT, | 48 SkBlitMask::RowProc SkBlitMask::PlatformRowProcs(SkColorType dstCT, |
| 49 SkMask::Format maskFormat, | 49 SkMask::Format maskFormat, |
| 50 RowFlags flags) { | 50 RowFlags flags) { |
| 51 return NULL; | 51 return NULL; |
| 52 } | 52 } |
| OLD | NEW |