aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkNx.h
diff options
context:
space:
mode:
authorGravatar mtklein <mtklein@chromium.org>2016-02-11 08:10:22 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2016-02-11 08:10:22 -0800
commitc1eb311f4e98934476f1b2ad5d6de772cf140d60 (patch)
tree7c569e5309ac6474cb38d7e5839c81d541571d58 /src/core/SkNx.h
parent49b9f8c93e76dcde465591346f4a4ff85c34e1a2 (diff)
SkNx refactoring
- add back Sk4i typedef - define SSE casts in terms of Sk4i * uint8 <-> float becomes uint8 <-> int <-> float * uint16 <-> float becomes uint16 <-> int <-> float This has the nice side effect of specializing uint8 <-> int and uint16 <-> int, which are useful in their own right. There are many cast specializations now, some of which call each other. I have tried to arrange them in some sort of sensible order, subject to the constraint that those called must precede those who call. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1690633003 CQ_EXTRA_TRYBOTS=client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot Review URL: https://codereview.chromium.org/1690633003
Diffstat (limited to 'src/core/SkNx.h')
-rw-r--r--src/core/SkNx.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/core/SkNx.h b/src/core/SkNx.h
index 986c133415..8722bf6dfa 100644
--- a/src/core/SkNx.h
+++ b/src/core/SkNx.h
@@ -199,6 +199,8 @@ typedef SkNx<16, uint8_t> Sk16b;
typedef SkNx<4, uint16_t> Sk4h;
typedef SkNx<16, uint16_t> Sk16h;
+typedef SkNx<4, int> Sk4i;
+
// Include platform specific specializations if available.
#if !defined(SKNX_NO_SIMD) && SK_CPU_SSE_LEVEL >= SK_CPU_SSE_LEVEL_SSE2
#include "../opts/SkNx_sse.h"