| Flutter Impeller |

Classes | Namespaces | Macros | Functions
aiks_blend_unittests.cc File Reference
`#include "flutter/impeller/aiks/aiks_unittests.h"`
`#include "flutter/testing/testing.h"`
`#include "impeller/aiks/canvas.h"`
`#include "impeller/aiks/color_filter.h"`
`#include "impeller/geometry/color.h"`
`#include "impeller/geometry/scalar.h"`

Go to the source code of this file.

## Classes
struct | impeller::testing::BlendModeSelection

## Namespaces
| impeller
| impeller::testing

## Macros
#define | BLEND_MODE_TUPLE(blend_mode) {#blend_mode, BlendMode::k##blend_mode},
#define | BLEND_MODE_TEST(blend_mode)
#define | BLEND_MODE_SRC_ALPHA_TEST(blend_mode)

## Functions
| impeller::testing::TEST_P (AiksTest, CanRenderAdvancedBlendColorFilterWithSaveLayer)
| impeller::testing::TEST_P (AiksTest, BlendModeShouldCoverWholeScreen)
| impeller::testing::TEST_P (AiksTest, CanDrawPaintWithAdvancedBlend)
| impeller::testing::TEST_P (AiksTest, DrawPaintWithAdvancedBlendOverFilter)
| impeller::testing::TEST_P (AiksTest, DrawAdvancedBlendPartlyOffscreen)
| impeller::testing::TEST_P (AiksTest, PaintBlendModeIsRespected)
| impeller::testing::TEST_P (AiksTest, BlendModePlusAlphaWideGamut)
| impeller::testing::TEST_P (AiksTest, BlendModePlusAlphaColorFilterWideGamut)
static BlendModeSelection | impeller::testing::GetBlendModeSelection ()
| impeller::testing::TEST_P (AiksTest, ColorWheel)
| impeller::testing::TEST_P (AiksTest, ForegroundBlendSubpassCollapseOptimization)
| impeller::testing::TEST_P (AiksTest, ClearBlend)
static Picture | impeller::testing::BlendModeTest (Vector2 content_scale, BlendMode blend_mode, const std::shared_ptr< Image > &src_image, const std::shared_ptr< Image > &dst_image, Scalar src_alpha)
| impeller::testing::TEST_P (AiksTest, CanDrawPaintMultipleTimesInteractive)
| impeller::testing::TEST_P (AiksTest, ForegroundPipelineBlendAppliesTransformCorrectly)
| impeller::testing::TEST_P (AiksTest, ForegroundAdvancedBlendAppliesTransformCorrectly)
| impeller::testing::TEST_P (AiksTest, FramebufferAdvancedBlendCoverage)

## Macro Definition Documentation

## ◆ BLEND_MODE_SRC_ALPHA_TEST

#define BLEND_MODE_SRC_ALPHA_TEST | ( |  | blend_mode | ) |

Value:
TEST_P(AiksTest, BlendModeSrcAlpha##blend_mode) { \
auto src_image = std::make_shared<Image>( \
CreateTextureForFixture("blend_mode_src.png")); \
auto dst_image = std::make_shared<Image>( \
CreateTextureForFixture("blend_mode_dst.png")); \
auto callback = [&](AiksContext& renderer) -> std::optional<Picture> { \
return BlendModeTest(GetContentScale(), BlendMode::k##blend_mode, \
src_image, dst_image, /*src_alpha=*/0.5); \
}; \
OpenPlaygroundHere(callback); \
}

Definition at line 510 of file aiks_blend_unittests.cc.

## ◆ BLEND_MODE_TEST

#define BLEND_MODE_TEST | ( |  | blend_mode | ) |

Value:
TEST_P(AiksTest, BlendMode##blend_mode) { \
auto src_image = std::make_shared<Image>( \
CreateTextureForFixture("blend_mode_src.png")); \
auto dst_image = std::make_shared<Image>( \
CreateTextureForFixture("blend_mode_dst.png")); \
auto callback = [&](AiksContext& renderer) -> std::optional<Picture> { \
return BlendModeTest(GetContentScale(), BlendMode::k##blend_mode, \
src_image, dst_image, /*src_alpha=*/1.0); \
}; \
OpenPlaygroundHere(callback); \
}

Definition at line 496 of file aiks_blend_unittests.cc.

## ◆ BLEND_MODE_TUPLE

#define BLEND_MODE_TUPLE | ( |  | blend_mode | ) | {#blend_mode, BlendMode::k##blend_mode},

Definition at line 181 of file aiks_blend_unittests.cc.

impeller::testing::AiksTest
AiksPlayground AiksTest
Definition: aiks_unittests.h:17
impeller::BlendMode
BlendMode
Definition: color.h:59
impeller::testing::TEST_P
TEST_P(AiksTest, FramebufferAdvancedBlendCoverage)
Definition: aiks_blend_unittests.cc:579
impeller::testing::BlendModeTest
static Picture BlendModeTest(Vector2 content_scale, BlendMode blend_mode, const std::shared_ptr< Image > &src_image, const std::shared_ptr< Image > &dst_image, Scalar src_alpha)
Definition: aiks_blend_unittests.cc:368