Home
last modified time | relevance | path

Searched refs:SkPM4f (Results 1 – 25 of 37) sorted by relevance

12

/external/skia/tests/
DSkColor4fTest.cpp25 static bool nearly_equal(const SkPM4f a, const SkPM4f& b, float tol = kTolerance) { in nearly_equal()
62 SkPM4f pm4 = c4.premul(); in DEF_TEST()
127 static void compare_spans(const SkPM4f span4f[], const SkPMColor span4b[], int count, in compare_spans()
130 SkPM4f c0 = SkPM4f::FromPMColor(span4b[i]); in compare_spans()
131 SkPM4f c1 = span4f[i]; in compare_spans()
162 SkPM4f buffer4f[N]; in DEF_TEST()
185 SkPM4f src4f[N]; in DEF_TEST()
189 src4f[i] = SkPM4f::FromPMColor(src4b[i]); in DEF_TEST()
198 SkPM4f dst4f[N]; in DEF_TEST()
206 typedef SkPM4f (*SkXfermodeProc4f)(const SkPM4f& src, const SkPM4f& dst);
[all …]
DFloat16Test.cpp26 static bool eq_within_half_float(const SkPM4f& a, const SkPM4f& b) { in eq_within_half_float()
48 SkPM4f origpm4 = c4.premul(); in DEF_TEST()
51 SkPM4f pm4 = SkPM4f::FromF16(pm.addrF16(x, y)); in DEF_TEST()
DSkLinearBitmapPipelineTest.cpp25 SkPM4f* FPbuffer = new SkPM4f[width * height]; in DEF_TEST()
/external/skia/src/core/
DSkPM4f.h16 struct SkPM4f { struct
29 static SkPM4f FromPMColor(SkPMColor); argument
34 static SkPM4f FromF16(const uint16_t[4]);
43 typedef SkPM4f (*SkXfermodeProc4f)(const SkPM4f& src, const SkPM4f& dst); argument
DSkColor.cpp109 SkPM4f SkPM4f::FromPMColor(SkPMColor c) { in FromPMColor()
111 SkPM4f c4; in FromPMColor()
116 SkColor4f SkPM4f::unpremul() const { in unpremul()
126 void SkPM4f::toF16(uint16_t half[4]) const { in toF16()
132 uint64_t SkPM4f::toF16() const { in toF16()
138 SkPM4f SkPM4f::FromF16(const uint16_t half[4]) { in FromF16()
148 void SkPM4f::assertIsUnit() const { in assertIsUnit()
169 SkPM4f SkColor4f::premul() const { in premul()
182 SkPM4f pm4; in premul()
DSkColorSpace.cpp179 void SkApply3x3ToPM4f(const SkFloat3x3& m, const SkPM4f src[], SkPM4f dst[], int count) { in SkApply3x3ToPM4f()
180 SkASSERT(1 == SkPM4f::G); in SkApply3x3ToPM4f()
181 SkASSERT(3 == SkPM4f::A); in SkApply3x3ToPM4f()
185 if (0 == SkPM4f::R) { in SkApply3x3ToPM4f()
186 SkASSERT(2 == SkPM4f::B); in SkApply3x3ToPM4f()
190 SkASSERT(0 == SkPM4f::B); in SkApply3x3ToPM4f()
191 SkASSERT(2 == SkPM4f::R); in SkApply3x3ToPM4f()
200 Sk4f r = Sk4f(src[i].fVec[SkPM4f::R]); in SkApply3x3ToPM4f()
201 Sk4f g = Sk4f(src[i].fVec[SkPM4f::G]); in SkApply3x3ToPM4f()
202 Sk4f b = Sk4f(src[i].fVec[SkPM4f::B]); in SkApply3x3ToPM4f()
[all …]
DSkSpanProcs.cpp19 static void load_l32(const SkPixmap& src, int x, int y, SkPM4f span[], int count) { in load_l32()
29 static void load_s32(const SkPixmap& src, int x, int y, SkPM4f span[], int count) { in load_s32()
39 static void load_f16(const SkPixmap& src, int x, int y, SkPM4f span[], int count) { in load_f16()
62 static void noop_filterspan(const SkPaint& paint, SkPM4f[], int) { in noop_filterspan() argument
67 static void alpha_filterspan(const SkPaint& paint, SkPM4f span[], int count) { in alpha_filterspan()
76 static void colorfilter_filterspan(const SkPaint& paint, SkPM4f span[], int count) { in colorfilter_filterspan()
82 static void colorfilter_alpha_filterspan(const SkPaint& paint, SkPM4f span[], int count) { in colorfilter_alpha_filterspan()
DSkXfermodeU64.cpp60 if (SkPM4f::R == 0) { in pm_to_rgba_order()
71 const SkPM4f* src, int count, const SkAlpha aa[]) { in xfer_u64_1()
73 SkPM4f d; in xfer_u64_1()
91 const SkPM4f src[], int count, const SkAlpha aa[]) { in xfer_u64_n()
93 SkPM4f d; in xfer_u64_n()
120 const SkPM4f*, int count, const SkAlpha aa[]) { in clear() argument
143 const SkPM4f* src, int count, const SkAlpha aa[]) { in src_1()
156 const SkPM4f src[], int count, const SkAlpha aa[]) { in src_n()
180 static void dst(const SkXfermode*, uint64_t*, const SkPM4f*, int count, const SkAlpha[]) {} in dst() argument
189 const SkPM4f* src, int count, const SkAlpha aa[]) { in srcover_1()
[all …]
DSkColorFilter.cpp34 void SkColorFilter::filterSpan4f(const SkPM4f[], int count, SkPM4f span[]) const { in filterSpan4f() argument
44 span[i] = SkPM4f::FromPMColor(tmp[i]); in filterSpan4f()
58 SkPM4f dst, src = c.premul(); in filterColor4f()
87 void filterSpan4f(const SkPM4f shader[], int count, SkPM4f result[]) const override { in filterSpan4f()
DSkSpanProcs.h16 struct SkPM4f;
18 typedef void (*SkLoadSpanProc)(const SkPixmap&, int x, int y, SkPM4f span[], int count);
19 typedef void (*SkFilterSpanProc)(const SkPaint& paint, SkPM4f span[], int count);
DSkXfermode.cpp65 if (0 == SkPM4f::R) { in set_argb()
267 float sa = s[SkPM4f::A]; in hue_4f()
268 float sr = s[SkPM4f::R]; in hue_4f()
269 float sg = s[SkPM4f::G]; in hue_4f()
270 float sb = s[SkPM4f::B]; in hue_4f()
272 float da = d[SkPM4f::A]; in hue_4f()
273 float dr = d[SkPM4f::R]; in hue_4f()
274 float dg = d[SkPM4f::G]; in hue_4f()
275 float db = d[SkPM4f::B]; in hue_4f()
288 float sa = s[SkPM4f::A]; in saturation_4f()
[all …]
DSkXfermode4f.cpp44 const SkPM4f* src, int count, const SkAlpha aa[]) { in general_1()
46 SkPM4f d; in general_1()
64 const SkPM4f src[], int count, const SkAlpha aa[]) { in general_n()
66 SkPM4f d; in general_n()
92 static void clear_linear(const SkXfermode*, uint32_t dst[], const SkPM4f[], in clear_linear() argument
111 static void clear_srgb(const SkXfermode*, uint32_t dst[], const SkPM4f[], in clear_srgb() argument
135 const SkPM4f src[], int count, const SkAlpha aa[]) { in src_n()
158 const SkPM4f* src, int count, const SkAlpha aa[]) { in src_1()
219 static void dst(const SkXfermode*, uint32_t dst[], const SkPM4f[], int count, const SkAlpha aa[]) {} in dst() argument
228 const SkPM4f src[], int count, const SkAlpha aa[]) { in srcover_n()
[all …]
DSkColorSpace.h38 struct SkPM4f;
39 void SkApply3x3ToPM4f(const SkFloat3x3&, const SkPM4f src[], SkPM4f dst[], int count);
DSkColorMatrixFilterRowMajor255.cpp64 static_assert(SkPM4f::A == 3, "Alpha is lane 3"); in scale_rgb()
69 return x * scale_rgb(x[SkPM4f::A]); in premul()
73 return x * scale_rgb(1 / x[SkPM4f::A]); // TODO: fast/approx invert? in unpremul()
101 float srcA = srcf[SkPM4f::A]; in filter_span()
136 static SkPM4f From4f(const Sk4f& c4) { in From4f()
137 SkPM4f c; in From4f()
141 static Sk4f To4f(const SkPM4f& c) { in To4f()
145 void SkColorMatrixFilterRowMajor255::filterSpan4f(const SkPM4f src[], int count, SkPM4f dst[]) cons… in filterSpan4f()
DSkModeColorFilter.cpp61 void SkModeColorFilter::filterSpan4f(const SkPM4f shader[], int count, SkPM4f result[]) const { in filterSpan4f()
62 SkPM4f color = SkPM4f::FromPMColor(fPMColor); in filterSpan4f()
DSkColorMatrixFilterRowMajor255.h21 void filterSpan4f(const SkPM4f src[], int count, SkPM4f[]) const override;
DSkPM4fPriv.h13 return f4[SkPM4f::A]; in get_alpha()
17 static_assert(3 == SkPM4f::A, ""); in set_alpha()
DSkModeColorFilter.h27 void filterSpan4f(const SkPM4f shader[], int count, SkPM4f result[]) const override;
DSkColorShader.h40 void shadeSpan4f(int x, int y, SkPM4f[], int count) override;
43 SkPM4f fPM4f;
DSkShader.cpp120 void SkShader::Context::shadeSpan4f(int x, int y, SkPM4f dst[], int count) { in shadeSpan4f()
127 dst[i] = SkPM4f::FromPMColor(tmp[i]); in shadeSpan4f()
315 void SkColorShader::ColorShaderContext::shadeSpan4f(int x, int y, SkPM4f span[], int count) { in shadeSpan4f()
DSkLinearBitmapPipeline.cpp67 virtual void setDestination(SkPM4f* dst) = 0;
636 SkPM4f* dst = fDst; in place4Pixels()
644 void setDestination(SkPM4f* dst) override { in setDestination()
649 static void VECTORCALL PlacePixel(SkPM4f* dst, Sk4f pixel, int index) { in PlacePixel()
661 SkPM4f* fDst;
697 void SkLinearBitmapPipeline::shadeSpan4f(int x, int y, SkPM4f* dst, int count) { in shadeSpan4f()
/external/skia/src/effects/gradients/
DSk4fLinearGradient.cpp13 const float alpha = c[SkPM4f::A]; in premul_4f()
33 void fill<SkPM4f, false>(const Sk4f& c, SkPM4f* dst, int n) { in fill()
41 void fill<SkPM4f, true>(const Sk4f& c, SkPM4f* dst, int n) { in fill()
42 fill<SkPM4f, false>(premul_4f(c), dst, n); in fill()
59 void store<SkPM4f, false>(const Sk4f& c, SkPM4f* dst) { in store()
64 void store<SkPM4f, true>(const Sk4f& c, SkPM4f* dst) { in store()
65 store<SkPM4f, false>(premul_4f(c), dst); in store()
155 float dst_component_scale<SkPM4f>() { in dst_component_scale()
183 LinearGradient4fContext::shadeSpan4f(int x, int y, SkPM4f dst[], int count) { in shadeSpan4f()
187 this->shadePremulSpan<SkPM4f, false>(x, y, dst, count); in shadeSpan4f()
[all …]
/external/skia/include/core/
DSkXfermode.h21 struct SkPM4f;
22 typedef SkPM4f (*SkXfermodeProc4f)(const SkPM4f& src, const SkPM4f& dst);
228 typedef void (*D32Proc)(const SkXfermode*, uint32_t dst[], const SkPM4f src[],
237 typedef void (*D64Proc)(const SkXfermode*, uint64_t dst[], const SkPM4f src[], int count,
246 typedef void (*LCD32Proc)(uint32_t* dst, const SkPM4f* src, int count, const uint16_t lcd[]);
247 typedef void (*LCD64Proc)(uint64_t* dst, const SkPM4f* src, int count, const uint16_t lcd[]);
DSkColorFilter.h70 virtual void filterSpan4f(const SkPM4f src[], int count, SkPM4f result[]) const;
DSkColor.h163 struct SkPM4f;
191 SkPM4f premul() const;

12