| Index: src/opts/Sk4px_none.h
|
| diff --git a/src/opts/Sk4px_none.h b/src/opts/Sk4px_none.h
|
| index b43ee875b2577eacb8a0f52b1debd66727040519..10c3dedd0f1b34f1d44712000e62eba282864d7c 100644
|
| --- a/src/opts/Sk4px_none.h
|
| +++ b/src/opts/Sk4px_none.h
|
| @@ -40,10 +40,10 @@ inline void Sk4px::store2(SkPMColor px[2]) const { memcpy(px, this, 8); }
|
| inline void Sk4px::store1(SkPMColor px[1]) const { memcpy(px, this, 4); }
|
|
|
| inline Sk4px::Wide Sk4px::widenLo() const {
|
| - return Sk16h(this->kth< 0>(), this->kth< 1>(), this->kth< 2>(), this->kth< 3>(),
|
| - this->kth< 4>(), this->kth< 5>(), this->kth< 6>(), this->kth< 7>(),
|
| - this->kth< 8>(), this->kth< 9>(), this->kth<10>(), this->kth<11>(),
|
| - this->kth<12>(), this->kth<13>(), this->kth<14>(), this->kth<15>());
|
| + return Sk16h((*this)[ 0], (*this)[ 1], (*this)[ 2], (*this)[ 3],
|
| + (*this)[ 4], (*this)[ 5], (*this)[ 6], (*this)[ 7],
|
| + (*this)[ 8], (*this)[ 9], (*this)[10], (*this)[11],
|
| + (*this)[12], (*this)[13], (*this)[14], (*this)[15]);
|
| }
|
|
|
| inline Sk4px::Wide Sk4px::widenHi() const { return this->widenLo() << 8; }
|
| @@ -56,10 +56,10 @@ inline Sk4px::Wide Sk4px::mulWiden(const Sk16b& other) const {
|
|
|
| inline Sk4px Sk4px::Wide::addNarrowHi(const Sk16h& other) const {
|
| Sk4px::Wide r = (*this + other) >> 8;
|
| - return Sk16b(r.kth< 0>(), r.kth< 1>(), r.kth< 2>(), r.kth< 3>(),
|
| - r.kth< 4>(), r.kth< 5>(), r.kth< 6>(), r.kth< 7>(),
|
| - r.kth< 8>(), r.kth< 9>(), r.kth<10>(), r.kth<11>(),
|
| - r.kth<12>(), r.kth<13>(), r.kth<14>(), r.kth<15>());
|
| + return Sk16b(r[ 0], r[ 1], r[ 2], r[ 3],
|
| + r[ 4], r[ 5], r[ 6], r[ 7],
|
| + r[ 8], r[ 9], r[10], r[11],
|
| + r[12], r[13], r[14], r[15]);
|
| }
|
|
|
| inline Sk4px Sk4px::Wide::div255() const {
|
| @@ -70,10 +70,10 @@ inline Sk4px Sk4px::Wide::div255() const {
|
|
|
| inline Sk4px Sk4px::alphas() const {
|
| static_assert(SK_A32_SHIFT == 24, "This method assumes little-endian.");
|
| - return Sk16b(this->kth< 3>(), this->kth< 3>(), this->kth< 3>(), this->kth< 3>(),
|
| - this->kth< 7>(), this->kth< 7>(), this->kth< 7>(), this->kth< 7>(),
|
| - this->kth<11>(), this->kth<11>(), this->kth<11>(), this->kth<11>(),
|
| - this->kth<15>(), this->kth<15>(), this->kth<15>(), this->kth<15>());
|
| + return Sk16b((*this)[ 3], (*this)[ 3], (*this)[ 3], (*this)[ 3],
|
| + (*this)[ 7], (*this)[ 7], (*this)[ 7], (*this)[ 7],
|
| + (*this)[11], (*this)[11], (*this)[11], (*this)[11],
|
| + (*this)[15], (*this)[15], (*this)[15], (*this)[15]);
|
| }
|
|
|
| inline Sk4px Sk4px::Load4Alphas(const SkAlpha a[4]) {
|
| @@ -92,18 +92,18 @@ inline Sk4px Sk4px::Load2Alphas(const SkAlpha a[2]) {
|
|
|
| inline Sk4px Sk4px::zeroAlphas() const {
|
| static_assert(SK_A32_SHIFT == 24, "This method assumes little-endian.");
|
| - return Sk16b(this->kth< 0>(), this->kth< 1>(), this->kth< 2>(), 0,
|
| - this->kth< 4>(), this->kth< 5>(), this->kth< 6>(), 0,
|
| - this->kth< 8>(), this->kth< 9>(), this->kth<10>(), 0,
|
| - this->kth<12>(), this->kth<13>(), this->kth<14>(), 0);
|
| + return Sk16b((*this)[ 0], (*this)[ 1], (*this)[ 2], 0,
|
| + (*this)[ 4], (*this)[ 5], (*this)[ 6], 0,
|
| + (*this)[ 8], (*this)[ 9], (*this)[10], 0,
|
| + (*this)[12], (*this)[13], (*this)[14], 0);
|
| }
|
|
|
| inline Sk4px Sk4px::zeroColors() const {
|
| static_assert(SK_A32_SHIFT == 24, "This method assumes little-endian.");
|
| - return Sk16b(0,0,0, this->kth< 3>(),
|
| - 0,0,0, this->kth< 7>(),
|
| - 0,0,0, this->kth<11>(),
|
| - 0,0,0, this->kth<15>());
|
| + return Sk16b(0,0,0, (*this)[ 3],
|
| + 0,0,0, (*this)[ 7],
|
| + 0,0,0, (*this)[11],
|
| + 0,0,0, (*this)[15]);
|
| }
|
|
|
| } // namespace
|
|
|