20#include "gmock/gmock.h"
25#include "third_party/imgui/imgui.h"
41 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
43 std::vector<float> sigmas = {0.0, 0.01, 1.0};
46 for (uint32_t
i = 0;
i < sigmas.size(); ++
i) {
60 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
67 builder.
Scale(content_Scale.
x, content_Scale.
y);
70 background_paint.
setColor(
DlColor(1, 0.1, 0.1, 0.1, DlColorSpace::kSRGB));
74 std::vector<Scalar> stops = {0.0, 1.0};
79 {0, 0}, {200, 200}, 2, colors.data(), stops.data(), DlTileMode::kClamp);
100 return builder.
Build();
106 GetContentScale(), 10, DlBlurStyle::kNormal)));
111 GetContentScale(), 0, DlBlurStyle::kNormal)));
116 GetContentScale(), 10, DlBlurStyle::kOuter)));
121 GetContentScale(), 10, DlBlurStyle::kInner)));
126 GetContentScale(), 10, DlBlurStyle::kSolid)));
131 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
133 std::vector<float> sigmas = {0.0, 0.01, 1.0};
136 for (uint32_t
i = 0;
i < sigmas.size(); ++
i) {
150 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
162 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
181 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
192 DlColor::RGBA(128.0f / 255.0f, 128.0f / 255.0f, 128.0f / 255.0f, 1.0f));
202 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
206 auto callback = [&]() -> sk_sp<DisplayList> {
233 builder.
SaveLayer(std::nullopt, &save_paint, backdrop_filter.get());
236 return builder.
Build();
239 ASSERT_TRUE(OpenPlaygroundHere(
callback));
265 builder.
SaveLayer(std::nullopt, &save_paint, backdrop_filter.get());
268 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
278 DlImageSampling::kNearestNeighbor, &paint);
288 builder.
SaveLayer(std::nullopt, &save_paint, backdrop_filter.get(),
293 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
303 DlImageSampling::kNearestNeighbor, &paint);
305 for (
int i = 0;
i < 6;
i++) {
314 builder.
SaveLayer(std::nullopt, &save_paint, backdrop_filter.get(),
320 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
324 CanRenderMultipleBackdropBlurWithSingleBackdropIdAndDistinctFilters) {
331 DlImageSampling::kNearestNeighbor, &paint);
333 for (
int i = 0;
i < 6;
i++) {
341 auto backdrop_filter =
343 builder.
SaveLayer(std::nullopt, &save_paint, backdrop_filter.get(),
349 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
362 auto backdrop_filter =
364 builder.
SaveLayer(std::nullopt, &save_paint, backdrop_filter.get());
367 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
386 builder.
Scale(1.1, 1.2);
390 auto backdrop_filter1 =
392 builder.
SaveLayer(std::nullopt, &save_paint, backdrop_filter1.get());
399 builder.
Scale(1.1, 1.2);
403 auto backdrop_filter2 =
405 builder.
SaveLayer(std::nullopt, &save_paint, backdrop_filter2.get());
409 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
422 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
440 std::shared_ptr<DlImageFilter> color_filter =
442 std::shared_ptr<DlImageFilter> blur =
447 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
465 std::shared_ptr<DlImageFilter> color_filter =
467 std::shared_ptr<DlImageFilter> blur =
472 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
476 auto callback = [&]() -> sk_sp<DisplayList> {
494 return builder.
Build();
496 ASSERT_TRUE(OpenPlaygroundHere(
callback));
513 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
528 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
533 auto callback = [&]() -> sk_sp<DisplayList> {
535 ImGuiWindowFlags_AlwaysAutoResize)) {
536 ImGui::SliderFloat(
"Sigma", &sigma, 0, 50);
540 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
548 return builder.
Build();
551 ASSERT_TRUE(OpenPlaygroundHere(
callback));
564 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
570 if (!EnsureContextSupportsWideGamut()) {
571 GTEST_SKIP() <<
"This backend doesn't yet support wide gamut.";
575 EXPECT_EQ(GetContext()->GetCapabilities()->GetDefaultColorFormat(),
592 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
610 builder.
Scale(0.8f, 0.8f);
626 const Scalar radius = 20.0f;
627 const Scalar y_spacing = 100.0f;
633 radius, 60.0f - radius),
643 radius, 60.0f - radius),
667 path_builder.
Close();
682 return builder.
Build();
687 {
"NormalTranslucentZeroSigma",
688 {.style = DlBlurStyle::kNormal, .sigma = 0.0f, .alpha = 0.5f}},
690 {
"NormalTranslucent",
691 {.style = DlBlurStyle::kNormal, .sigma = 8.0f, .alpha = 0.5f}},
694 {.style = DlBlurStyle::kSolid, .sigma = 8.0f, .alpha = 0.5f}},
696 {
"SolidOpaque", {.style = DlBlurStyle::kSolid, .sigma = 8.0f}},
698 {
"SolidTranslucentWithFilters",
699 {.style = DlBlurStyle::kSolid,
703 .invert_colors =
true}},
705 {
"SolidTranslucentExclusionBlend",
706 {.style = DlBlurStyle::kSolid,
709 .blend_mode = DlBlendMode::kExclusion}},
712 {.style = DlBlurStyle::kInner, .sigma = 8.0f, .alpha = 0.5f}},
714 {
"InnerTranslucentWithBlurImageFilter",
715 {.style = DlBlurStyle::kInner,
721 {.style = DlBlurStyle::kOuter, .sigma = 8.0f, .alpha = 0.5f}},
723 {
"OuterOpaqueWithBlurImageFilter",
724 {.style = DlBlurStyle::kOuter,
728#define MASK_BLUR_VARIANT_TEST(config) \
729 TEST_P(AiksTest, MaskBlurVariantTest##config) { \
730 ASSERT_TRUE(OpenPlaygroundHere( \
731 MaskBlurVariantTest(*this, kPaintVariations.at(#config)))); \
745#undef MASK_BLUR_VARIANT_TEST
749 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
762 path_builder.
Close();
771 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
776 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
789 path_builder.
Close();
798 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
803 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
816 path_builder.
Close();
825 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
830 auto callback = [&]() -> sk_sp<DisplayList> {
832 ImGuiWindowFlags_AlwaysAutoResize)) {
833 ImGui::SliderFloat(
"Sigma", &sigma, 0, 500);
838 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
846 DlPoint(200, 200), DlImageSampling::kNearestNeighbor, &paint);
852 return builder.
Build();
854 ASSERT_TRUE(OpenPlaygroundHere(
callback));
859 auto callback = [&]() -> sk_sp<DisplayList> {
861 ImGuiWindowFlags_AlwaysAutoResize)) {
862 ImGui::SliderFloat(
"Sigma", &sigma, 0, 500);
867 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
873 std::shared_ptr<Texture> boston = CreateTextureForFixture(
"boston.jpg");
880 DlImageSampling::kMipmapLinear));
884 boston->GetSize().height),
887 return builder.
Build();
889 ASSERT_TRUE(OpenPlaygroundHere(
callback));
896 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
914 builder.
SaveLayer(std::nullopt, &save_paint, backdrop_filter.get());
917 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
923 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
924 std::shared_ptr<Texture> boston = CreateTextureForFixture(
"boston.jpg");
929 DlImageSampling::kNearestNeighbor);
943 builder.
SaveLayer(std::nullopt, &save_paint, backdrop_filter.get());
946 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
955 CreateTextureForFixture(
"boston.jpg",
true);
961 auto callback = [&]() -> sk_sp<DisplayList> {
963 ImGuiWindowFlags_AlwaysAutoResize)) {
964 ImGui::SliderFloat(
"Sigma", &sigma, 0, 200);
965 ImGui::SliderFloat(
"Frequency", &freq, 0.01, 2.0);
966 ImGui::SliderFloat(
"Amplitude", &, 1, 100);
971 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
972 Scalar y = amp * sin(freq * 2.0 * M_PI * count / 60);
974 DlPoint(1024 / 2 - boston->GetSize().width / 2,
975 (768 / 2 - boston->GetSize().height / 2) +
y),
976 DlImageSampling::kMipmapLinear);
988 auto backdrop_filter =
990 builder.
SaveLayer(std::nullopt, &paint, backdrop_filter.get());
992 return builder.
Build();
994 ASSERT_TRUE(OpenPlaygroundHere(
callback));
1000 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
1006 std::vector<DlColor> colors = {
DlColor::RGBA(0.9568, 0.2627, 0.2118, 1.0),
1008 std::vector<Scalar> stops = {0.0, 1.0};
1017 DlTileMode::kMirror));
1024 path_builder.
Close();
1032 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
1037 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
1043 std::vector<DlColor> colors = {
DlColor::RGBA(0.9568, 0.2627, 0.2118, 1.0),
1045 std::vector<Scalar> stops = {0.0, 1.0};
1054 DlTileMode::kMirror));
1061 path_builder.
Close();
1068 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
1073 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
1079 std::vector<DlColor> colors = {
DlColor::RGBA(0.9568, 0.2627, 0.2118, 1.0),
1081 std::vector<Scalar> stops = {0.0, 1.0};
1090 DlTileMode::kMirror));
1097 path_builder.
Close();
1104 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
1109 std::shared_ptr<Texture> boston = CreateTextureForFixture(
"boston.jpg");
1111 Rect::MakeXYWH(0, 0, boston->GetSize().width, boston->GetSize().height);
1117 Vector2 clip_size = {150, 75};
1119 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
1123 rect.GetRight(), rect.GetBottom()));
1125 builder.
Scale(0.6, 0.6);
1128 bounds.GetRight(), bounds.GetBottom());
1129 Rect dest = bounds.Shift(-image_center);
1131 dest.GetRight(), dest.GetBottom());
1133 sk_dst, DlImageSampling::kNearestNeighbor,
1136 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
1140 std::shared_ptr<Texture> boston = CreateTextureForFixture(
"boston.jpg");
1142 auto callback = [&]() -> sk_sp<DisplayList> {
1143 const char* tile_mode_names[] = {
"Clamp",
"Repeat",
"Mirror",
"Decal"};
1144 const DlTileMode tile_modes[] = {DlTileMode::kClamp, DlTileMode::kRepeat,
1145 DlTileMode::kMirror, DlTileMode::kDecal};
1147 static float rotation = 0;
1148 static float scale = 0.6;
1149 static int selected_tile_mode = 3;
1152 ImGuiWindowFlags_AlwaysAutoResize)) {
1153 ImGui::SliderFloat(
"Rotation (degrees)", &rotation, -180, 180);
1154 ImGui::SliderFloat(
"Scale", &scale, 0, 2.0);
1155 ImGui::Combo(
"Tile mode", &selected_tile_mode, tile_mode_names,
1156 sizeof(tile_mode_names) /
sizeof(
char*));
1162 Rect::MakeXYWH(0, 0, boston->GetSize().width, boston->GetSize().height);
1173 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
1177 builder.
Scale(scale, scale);
1178 builder.
Rotate(rotation);
1181 bounds.GetRight(), bounds.GetBottom());
1182 Rect dest = bounds.Shift(-image_center);
1184 dest.GetRight(), dest.GetBottom());
1186 sk_dst, DlImageSampling::kNearestNeighbor,
1188 return builder.
Build();
1191 ASSERT_TRUE(OpenPlaygroundHere(
callback));
1197 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
1198 builder.
Scale(0.5, 0.5);
1200 std::shared_ptr<Texture> boston = CreateTextureForFixture(
"boston.jpg");
1207 builder.
SaveLayer(std::nullopt, &paint, backdrop_filter.get());
1209 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
1219 std::shared_ptr<Texture> boston = CreateTextureForFixture(
"boston.jpg");
1221 Rect::MakeXYWH(0, 0, boston->GetSize().width, boston->GetSize().height);
1227 Vector2 clip_size = {150, 75};
1229 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
1233 clip_bounds.GetRight(),
1234 clip_bounds.GetBottom()));
1236 builder.
Scale(0.6, 0.6);
1239 auto dst_rect = bounds.Shift(-image_center);
1243 bounds.GetBottom()),
1246 dst_rect.GetRight(), dst_rect.GetBottom()),
1247 DlImageSampling::kMipmapLinear, &paint);
1249 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
1253 auto callback = [&]() -> sk_sp<DisplayList> {
1254 const char* tile_mode_names[] = {
"Clamp",
"Repeat",
"Mirror",
"Decal"};
1255 const DlTileMode tile_modes[] = {DlTileMode::kClamp, DlTileMode::kRepeat,
1256 DlTileMode::kMirror, DlTileMode::kDecal};
1258 static float rotation = 45;
1259 static float scale = 0.6;
1260 static int selected_tile_mode = 3;
1263 ImGuiWindowFlags_AlwaysAutoResize)) {
1264 ImGui::SliderFloat(
"Rotation (degrees)", &rotation, -180, 180);
1265 ImGui::SliderFloat(
"Scale", &scale, 0, 2.0);
1266 ImGui::Combo(
"Tile mode", &selected_tile_mode, tile_mode_names,
1267 sizeof(tile_mode_names) /
sizeof(
char*));
1279 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
1281 builder.
Scale(scale, scale);
1282 builder.
Rotate(rotation);
1287 return builder.
Build();
1290 ASSERT_TRUE(OpenPlaygroundHere(
callback));
1295 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
1302 paint.setStrokeWidth(5);
1303 paint.setDrawStyle(DlDrawStyle::kStroke);
1304 draw_line(
DlPoint(dx + 100, dy + 100),
DlPoint(dx + 200, dy + 200));
1305 draw_line(
DlPoint(dx + 100, dy + 200),
DlPoint(dx + 200, dy + 100));
1306 draw_line(
DlPoint(dx + 150, dy + 100),
DlPoint(dx + 200, dy + 150));
1307 draw_line(
DlPoint(dx + 100, dy + 150),
DlPoint(dx + 150, dy + 200));
1312 for (
int x = 0;
x < 5; ++
x) {
1313 for (
int y = 0;
y < 5; ++
y) {
1319 recorder_builder.
DrawRect(rect, paint);
1345 paint_lines(0, 300, paint);
1348 paint_lines(300, 300, paint);
1350 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
1359 for (int32_t
i = 1;
i < 5; ++
i) {
1374 EXPECT_TRUE(
image) <<
" length " <<
i;
1383 for (int32_t
i = 1;
i < 5; ++
i) {
1400 EXPECT_TRUE(
image) <<
" length " <<
i;
1405 CanRenderMultipleBackdropBlurWithSingleBackdropIdDifferentLayers) {
1412 DlImageSampling::kNearestNeighbor, &paint);
1414 for (
int i = 0;
i < 6;
i++) {
1418 builder.
SaveLayer(std::nullopt, &paint);
1428 builder.
SaveLayer(std::nullopt, &save_paint, backdrop_filter.get(),
1437 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
1442 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
1444 std::vector<DlColor> colors = {
DlColor(0xFFFF0000),
DlColor(0xFF00FF00)};
1445 std::vector<Scalar> stops = {0.0, 1.0};
1448 {0, 0}, {400, 400}, 2, colors.data(), stops.data(), DlTileMode::kClamp);
1452 builder.
SaveLayer(std::nullopt, &save_paint);
1461 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
1470 auto callback = [&]() -> sk_sp<DisplayList> {
1475 Scalar offset = amp * sin(freq * 2.0 * M_PI * count / 60.0);
1490 builder.
SaveLayer(std::nullopt,
nullptr, backdrop_filter1.get());
1499 auto backdrop_filter2 =
1503 builder.
SaveLayer(std::nullopt,
nullptr, backdrop_filter2.get());
1511 return builder.
Build();
1513 ASSERT_TRUE(OpenPlaygroundHere(
callback));
1518 builder.
Scale(GetContentScale().
x, GetContentScale().
y);
1524 builder.
Scale(-1, 1);
1533 ASSERT_TRUE(OpenPlaygroundHere(builder.
Build()));
#define MASK_BLUR_VARIANT_TEST(config)
void DrawOval(const DlRect &bounds, const DlPaint &paint) override
void ClipRect(const DlRect &rect, DlClipOp clip_op=DlClipOp::kIntersect, bool is_aa=false) override
void DrawImageRect(const sk_sp< DlImage > &image, const DlRect &src, const DlRect &dst, DlImageSampling sampling, const DlPaint *paint=nullptr, DlSrcRectConstraint constraint=DlSrcRectConstraint::kFast) override
void DrawRoundRect(const DlRoundRect &rrect, const DlPaint &paint) override
void DrawImage(const sk_sp< DlImage > &image, const DlPoint &point, DlImageSampling sampling, const DlPaint *paint=nullptr) override
void DrawColor(DlColor color, DlBlendMode mode) override
void DrawCircle(const DlPoint ¢er, DlScalar radius, const DlPaint &paint) override
void SaveLayer(const std::optional< DlRect > &bounds, const DlPaint *paint=nullptr, const DlImageFilter *backdrop=nullptr, std::optional< int64_t > backdrop_id=std::nullopt) override
void DrawLine(const DlPoint &p0, const DlPoint &p1, const DlPaint &paint) override
void ClipRoundRect(const DlRoundRect &rrect, DlClipOp clip_op=DlClipOp::kIntersect, bool is_aa=false) override
void Rotate(DlScalar degrees) override
void Scale(DlScalar sx, DlScalar sy) override
void Translate(DlScalar tx, DlScalar ty) override
void DrawPaint(const DlPaint &paint) override
sk_sp< DisplayList > Build()
void DrawPath(const DlPath &path, const DlPaint &paint) override
void Transform(const DlMatrix &matrix) override
void DrawRect(const DlRect &rect, const DlPaint &paint) override
static std::shared_ptr< DlImageFilter > Make(DlScalar sigma_x, DlScalar sigma_y, DlTileMode tile_mode, std::optional< DlRect > bounds=std::nullopt)
static std::shared_ptr< DlMaskFilter > Make(DlBlurStyle style, SkScalar sigma, bool respect_ctm=true)
static std::shared_ptr< const DlColorFilter > MakeBlend(DlColor color, DlBlendMode mode)
static std::shared_ptr< const DlColorFilter > MakeMatrix(const float matrix[20])
static std::shared_ptr< DlColorSource > MakeImage(const sk_sp< const DlImage > &image, DlTileMode horizontal_tile_mode, DlTileMode vertical_tile_mode, DlImageSampling sampling=DlImageSampling::kLinear, const DlMatrix *matrix=nullptr)
static std::shared_ptr< DlColorSource > MakeLinear(const DlPoint start_point, const DlPoint end_point, uint32_t stop_count, const DlColor *colors, const float *stops, DlTileMode tile_mode, const DlMatrix *matrix=nullptr)
static std::shared_ptr< DlImageFilter > MakeBlur(DlScalar sigma_x, DlScalar sigma_y, DlTileMode tile_mode)
static std::shared_ptr< DlImageFilter > MakeColorFilter(const std::shared_ptr< const DlColorFilter > &filter)
static std::shared_ptr< DlImageFilter > MakeCompose(const std::shared_ptr< DlImageFilter > &outer, const std::shared_ptr< DlImageFilter > &inner)
DlPaint & setColor(DlColor color)
DlPaint & setInvertColors(bool isInvertColors)
DlPaint & setStrokeWidth(float width)
DlPaint & setBlendMode(DlBlendMode mode)
DlPaint & setImageFilter(std::nullptr_t filter)
DlPaint & setMaskFilter(std::nullptr_t filter)
DlPaint & setDrawStyle(DlDrawStyle style)
DlPaint & setOpacity(DlScalar opacity)
DlPaint & setColorFilter(std::nullptr_t filter)
DlPaint & setColorSource(std::nullptr_t source)
DlPathBuilder & LineTo(DlPoint p2)
Draw a line from the current point to the indicated point p2.
DlPathBuilder & MoveTo(DlPoint p2)
Start a new contour that will originate at the indicated point p2.
const DlPath TakePath()
Returns the path constructed by this path builder and resets its internal state to the default state ...
DlPathBuilder & Close()
The path is closed back to the location of the most recent MoveTo call. Contours that are filled are ...
static DlPath MakeLine(const DlPoint a, const DlPoint b)
static DlPath MakeCircle(const DlPoint center, DlScalar radius)
static DlPath MakeArc(const DlRect &bounds, DlDegrees start, DlDegrees sweep, bool use_center)
static DlPath MakeRect(const DlRect &rect)
static bool ImGuiBegin(const char *name, bool *p_open, ImGuiWindowFlags flags)
static sk_sp< DlImageImpeller > Make(std::shared_ptr< Texture > texture, OwningContext owning_context=OwningContext::kIO)
Point GetContentScale() const
FlutterVulkanImage * image
FlutterDesktopBinaryReply callback
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir path
TEST_P(AiksTest, DrawAtlasNoColor)
static const std::map< std::string, MaskBlurTestConfig > kPaintVariations
sk_sp< flutter::DisplayList > DoGradientOvalStrokeMaskBlur(Vector2 content_Scale, Scalar sigma, DlBlurStyle style)
static sk_sp< DisplayList > MaskBlurVariantTest(const AiksTest &test_context, const MaskBlurTestConfig &config)
Point DrawPlaygroundPoint(PlaygroundPoint &point)
std::tuple< Point, Point > DrawPlaygroundLine(PlaygroundPoint &point_a, PlaygroundPoint &point_b)
std::shared_ptr< Texture > DisplayListToTexture(const sk_sp< flutter::DisplayList > &display_list, ISize size, AiksContext &context, bool reset_host_buffer, bool generate_mips, std::optional< PixelFormat > target_pixel_format)
Render the provided display list to a texture with the given size.
static constexpr DlColor kMagenta()
static constexpr DlColor kWhite()
static constexpr DlColor kBlue()
static constexpr DlColor kDarkMagenta()
static constexpr DlColor RGBA(DlScalar r, DlScalar g, DlScalar b, DlScalar a)
Construct a 32 bit color from floating point R, G, B, and A color channels.
static constexpr DlColor kCrimson()
static constexpr DlColor kMaroon()
static constexpr DlColor kYellow()
static constexpr DlColor kPurple()
static constexpr DlColor kChartreuse()
static constexpr DlColor kCornflowerBlue()
static constexpr DlColor kDarkGreen()
static constexpr DlColor kRed()
static constexpr DlColor kGreen()
static constexpr DlColor kOrange()
static constexpr DlColor kLimeGreen()
static constexpr DlColor kOrangeRed()
static constexpr DlColor kGreenYellow()
static constexpr Color White()
static constexpr Color Red()
static constexpr Color AntiqueWhite()
static constexpr Color Green()
static constexpr Matrix MakeTranslation(const Vector3 &t)
static constexpr Matrix MakeScale(const Vector3 &s)
For convolution filters, the "radius" is the size of the convolution kernel to use on the local space...
static RoundRect MakeRectXY(const Rect &rect, Scalar x_radius, Scalar y_radius)
In filters that use Gaussian distributions, "sigma" is a size of one standard deviation in terms of t...
static constexpr TRect MakeEllipseBounds(const TPoint< Type > ¢er, const TSize< Type > &radii)
static constexpr TRect MakeXYWH(Type x, Type y, Type width, Type height)
static constexpr TRect MakeCircleBounds(const TPoint< Type > ¢er, Type radius)
static constexpr TRect MakeLTRB(Type left, Type top, Type right, Type bottom)
std::shared_ptr< DlImageFilter > image_filter