/external/skia/src/shaders/gradients/ |
Sk4fGradientPriv.h | 30 static Sk4f apply(const Sk4f& c) { return c; } 35 static Sk4f apply(const Sk4f& c) { 38 return c * Sk4f(alpha, alpha, alpha, 1); 44 // - load() Load a SkPM4f value into Sk4f. Normally called once per interval 47 // - store() Store one Sk4f to dest. Optionally handles premul, color space 50 // - store(count) Store the Sk4f value repeatedly to dest, count times. 52 // - store4x() Store 4 Sk4f values to dest (opportunistic optimization). 62 static Sk4f load(const SkPM4f& c) [all...] |
Sk4fGradientBase.h | 21 Sk4fGradientInterval(const Sk4f& c0, SkScalar t0, 22 const Sk4f& c1, SkScalar t1); 77 const Sk4f& componentScale, bool reverse);
|
Sk4fGradientBase.cpp | 14 Sk4f pack_color(const SkColor4f& c4f, bool premul, const Sk4f& component_scale) { 15 const Sk4f pm4f = premul 17 : Sk4f{c4f.fR, c4f.fG, c4f.fB, c4f.fA}; 98 const Sk4f& componentScale, 118 Sk4fGradientInterval::Sk4fGradientInterval(const Sk4f& c0, SkScalar t0, 119 const Sk4f& c1, SkScalar t1) 131 const Sk4f dc = SkScalarIsFinite(dt) ? (c1 - c0) / dt : 0; 132 const Sk4f bias = c0 - (SkScalarIsFinite(t0) ? t0 * dc : 0); 188 const Sk4f componentScale = premulColor [all...] |
Sk4fLinearGradient.cpp | 17 void ramp(const Sk4f& c, const Sk4f& dc, dstType dst[], int n, 18 const Sk4f& bias0, const Sk4f& bias1) { 21 const Sk4f dc2 = dc + dc, 24 Sk4f c0 = c + DstTraits<dstType, premul>::pre_lerp_bias(bias0), 237 Sk4f bias4f0(bias0), 315 const Sk4f& currentColor() const { return fCc; } 316 const Sk4f& currentColorGrad() const { return fDcDx; } 327 fCc = fCc + fDcDx * Sk4f(advX) [all...] |
/external/skqp/src/shaders/gradients/ |
Sk4fGradientPriv.h | 30 static Sk4f apply(const Sk4f& c) { return c; } 35 static Sk4f apply(const Sk4f& c) { 38 return c * Sk4f(alpha, alpha, alpha, 1); 44 // - load() Load a SkPM4f value into Sk4f. Normally called once per interval 47 // - store() Store one Sk4f to dest. Optionally handles premul, color space 50 // - store(count) Store the Sk4f value repeatedly to dest, count times. 52 // - store4x() Store 4 Sk4f values to dest (opportunistic optimization). 62 static Sk4f load(const SkPM4f& c) [all...] |
Sk4fGradientBase.h | 21 Sk4fGradientInterval(const Sk4f& c0, SkScalar t0, 22 const Sk4f& c1, SkScalar t1); 77 const Sk4f& componentScale, bool reverse);
|
Sk4fGradientBase.cpp | 14 Sk4f pack_color(const SkColor4f& c4f, bool premul, const Sk4f& component_scale) { 15 const Sk4f pm4f = premul 17 : Sk4f{c4f.fR, c4f.fG, c4f.fB, c4f.fA}; 98 const Sk4f& componentScale, 118 Sk4fGradientInterval::Sk4fGradientInterval(const Sk4f& c0, SkScalar t0, 119 const Sk4f& c1, SkScalar t1) 131 const Sk4f dc = SkScalarIsFinite(dt) ? (c1 - c0) / dt : 0; 132 const Sk4f bias = c0 - (SkScalarIsFinite(t0) ? t0 * dc : 0); 188 const Sk4f componentScale = premulColor [all...] |
Sk4fLinearGradient.cpp | 17 void ramp(const Sk4f& c, const Sk4f& dc, dstType dst[], int n, 18 const Sk4f& bias0, const Sk4f& bias1) { 21 const Sk4f dc2 = dc + dc, 24 Sk4f c0 = c + DstTraits<dstType, premul>::pre_lerp_bias(bias0), 234 Sk4f bias4f0(bias0), 312 const Sk4f& currentColor() const { return fCc; } 313 const Sk4f& currentColorGrad() const { return fDcDx; } 324 fCc = fCc + fDcDx * Sk4f(advX) [all...] |
/external/skia/src/core/ |
SkSRGB.h | 28 static inline Sk4i sk_linear_to_srgb(const Sk4f& x) { 41 auto hi = SkNx_fma(Sk4f{+0.412999f * 255.0f}, ftrt, 42 SkNx_fma(Sk4f{+0.687999f * 255.0f}, sqrt, 43 Sk4f{-0.0974983f * 255.0f})); 49 return SkNx_cast<int>(Sk4f::Min(Sk4f::Max(s, 0.0f), 255.0f));
|
SkPM4f.h | 14 static inline Sk4f swizzle_rb(const Sk4f& x) { 18 static inline Sk4f swizzle_rb_if_bgra(const Sk4f& x) { 49 static SkPM4f From4f(const Sk4f& x) { 57 Sk4f to4f() const { return Sk4f::Load(fVec); } 58 Sk4f to4f_rgba() const { return this->to4f(); } 59 Sk4f to4f_bgra() const { return swizzle_rb(this->to4f()); } 60 Sk4f to4f_pmorder() const { return swizzle_rb_if_bgra(this->to4f()); [all...] |
Sk4x4f.h | 16 Sk4f r,g,b,a; 18 static Sk4x4f Transpose(const Sk4f&, const Sk4f&, const Sk4f&, const Sk4f&); 22 void transpose(Sk4f* x, Sk4f* y, Sk4f* z, Sk4f* w) const { 35 inline Sk4x4f Sk4x4f::Transpose(const Sk4f& x, const Sk4f& y, const Sk4f& z, const Sk4f& w) [all...] |
SkHalf.h | 31 static inline Sk4f SkHalfToFloat_finite_ftz(uint64_t); 32 static inline Sk4h SkFloatToHalf_finite_ftz(const Sk4f&); 41 static inline Sk4f SkHalfToFloat_finite_ftz(uint64_t rgba) { 60 return Sk4f::Load(&merged); 64 static inline Sk4h SkFloatToHalf_finite_ftz(const Sk4f& fs) {
|
SkColor.cpp | 147 auto c4 = Sk4f::Load(fVec); 148 SkASSERT((c4 >= Sk4f(0)).allTrue() && (c4 <= Sk4f(1)).allTrue()); 161 return Sk4f_toS32(swizzle_rb(Sk4f::Load(this->vec()))); 166 Sk4f::Min(Sk4f::Max(Sk4f(r, g, b, a), Sk4f(0)), Sk4f(1)).store(c4.vec()); 171 auto src = Sk4f::Load(this->pin().vec()) [all...] |
SkPM4fPriv.h | 19 static inline Sk4f set_alpha(const Sk4f& px, float alpha) { 23 static inline float get_alpha(const Sk4f& px) { 28 static inline Sk4f Sk4f_fromL32(uint32_t px) { 32 static inline Sk4f Sk4f_fromS32(uint32_t px) { 39 static inline uint32_t Sk4f_toL32(const Sk4f& px) { 45 static inline uint32_t Sk4f_toS32(const Sk4f& px) { 56 // SkColor has an ordering of (b, g, r, a) if cast to an Sk4f, so the code swizzles r and b to 58 static inline Sk4f Sk4f_from_SkColor(SkColor color) {
|
/external/skqp/src/core/ |
SkSRGB.h | 28 static inline Sk4i sk_linear_to_srgb(const Sk4f& x) { 41 auto hi = SkNx_fma(Sk4f{+0.412999f * 255.0f}, ftrt, 42 SkNx_fma(Sk4f{+0.687999f * 255.0f}, sqrt, 43 Sk4f{-0.0974983f * 255.0f})); 49 return SkNx_cast<int>(Sk4f::Min(Sk4f::Max(s, 0.0f), 255.0f));
|
SkPM4f.h | 14 static inline Sk4f swizzle_rb(const Sk4f& x) { 18 static inline Sk4f swizzle_rb_if_bgra(const Sk4f& x) { 49 static SkPM4f From4f(const Sk4f& x) { 57 Sk4f to4f() const { return Sk4f::Load(fVec); } 58 Sk4f to4f_rgba() const { return this->to4f(); } 59 Sk4f to4f_bgra() const { return swizzle_rb(this->to4f()); } 60 Sk4f to4f_pmorder() const { return swizzle_rb_if_bgra(this->to4f()); [all...] |
Sk4x4f.h | 16 Sk4f r,g,b,a; 18 static Sk4x4f Transpose(const Sk4f&, const Sk4f&, const Sk4f&, const Sk4f&); 22 void transpose(Sk4f* x, Sk4f* y, Sk4f* z, Sk4f* w) const { 35 inline Sk4x4f Sk4x4f::Transpose(const Sk4f& x, const Sk4f& y, const Sk4f& z, const Sk4f& w) [all...] |
SkHalf.h | 31 static inline Sk4f SkHalfToFloat_finite_ftz(uint64_t); 32 static inline Sk4h SkFloatToHalf_finite_ftz(const Sk4f&); 41 static inline Sk4f SkHalfToFloat_finite_ftz(uint64_t rgba) { 60 return Sk4f::Load(&merged); 64 static inline Sk4h SkFloatToHalf_finite_ftz(const Sk4f& fs) {
|
SkColor.cpp | 147 auto c4 = Sk4f::Load(fVec); 148 SkASSERT((c4 >= Sk4f(0)).allTrue() && (c4 <= Sk4f(1)).allTrue()); 161 return Sk4f_toS32(swizzle_rb(Sk4f::Load(this->vec()))); 166 Sk4f::Min(Sk4f::Max(Sk4f(r, g, b, a), Sk4f(0)), Sk4f(1)).store(c4.vec()); 171 auto src = Sk4f::Load(this->pin().vec()) [all...] |
SkPM4fPriv.h | 19 static inline Sk4f set_alpha(const Sk4f& px, float alpha) { 23 static inline float get_alpha(const Sk4f& px) { 28 static inline Sk4f Sk4f_fromL32(uint32_t px) { 32 static inline Sk4f Sk4f_fromS32(uint32_t px) { 39 static inline uint32_t Sk4f_toL32(const Sk4f& px) { 45 static inline uint32_t Sk4f_toS32(const Sk4f& px) { 56 // SkColor has an ordering of (b, g, r, a) if cast to an Sk4f, so the code swizzles r and b to 58 static inline Sk4f Sk4f_from_SkColor(SkColor color) {
|
/external/skia/src/opts/ |
SkXfermode_opts.h | 117 struct Xfermode { Sk4f operator()(const Sk4f&, const Sk4f&) const; }; \ 118 inline Sk4f Xfermode::operator()(const Sk4f& d, const Sk4f& s) const 120 static inline Sk4f a_rgb(const Sk4f& a, const Sk4f& rgb) { 122 return a * Sk4f(0,0,0,1) + rgb * Sk4f(1,1,1,0) [all...] |
/external/skqp/src/opts/ |
SkXfermode_opts.h | 117 struct Xfermode { Sk4f operator()(const Sk4f&, const Sk4f&) const; }; \ 118 inline Sk4f Xfermode::operator()(const Sk4f& d, const Sk4f& s) const 120 static inline Sk4f a_rgb(const Sk4f& a, const Sk4f& rgb) { 122 return a * Sk4f(0,0,0,1) + rgb * Sk4f(1,1,1,0) [all...] |
/external/skia/bench/ |
Sk4fBench.cpp | 32 Sk4f fs(1,2,3,4); 50 Sk4f fs(1,2,3,4); 65 Sk4f c0(0,0,255,255), 74 Sk4f a = c0 + dc*fx + Sk4f(0.5f), // add an extra 0.5f to get rounding for free.
|
/external/skqp/bench/ |
Sk4fBench.cpp | 32 Sk4f fs(1,2,3,4); 50 Sk4f fs(1,2,3,4); 65 Sk4f c0(0,0,255,255), 74 Sk4f a = c0 + dc*fx + Sk4f(0.5f), // add an extra 0.5f to get rounding for free.
|
/external/skia/samplecode/ |
SamplePathText.cpp | 390 const Sk4f amplitudes = Sk4f::Load(fAmplitudes); 391 const Sk4f frequencies = Sk4f::Load(fFrequencies); 392 const Sk4f dirsX = Sk4f::Load(fDirsX); 393 const Sk4f dirsY = Sk4f::Load(fDirsY); 394 const Sk4f speeds = Sk4f::Load(fSpeeds) [all...] |