Skip to content

Commit 62f7cf7

Browse files
committed
Enable shadow in demo
1 parent e51e738 commit 62f7cf7

1 file changed

Lines changed: 7 additions & 6 deletions

File tree

demo/common/app.cpp

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,13 @@ App::App(const std::shared_ptr<Device> &device,
3434
canvas_->clip_path(path, FillRule::Winding);
3535
}
3636

37+
// Test: shadow/blur.
38+
if (true) {
39+
canvas_->set_shadow_color(ColorU::white());
40+
canvas_->set_shadow_blur(16);
41+
canvas_->set_shadow_offset({0, 0});
42+
}
43+
3744
// Test: draw image.
3845
if (true) {
3946
auto image_buffer = ImageBuffer::from_memory(img_input, false);
@@ -53,12 +60,6 @@ App::App(const std::shared_ptr<Device> &device,
5360
path.line_to(260.0, 460.0);
5461
path.close_path();
5562

56-
// Test: shadow/blur.
57-
if (false) {
58-
canvas_->set_shadow_color(ColorU::white());
59-
canvas_->set_shadow_blur(16);
60-
}
61-
6263
// Set brush.
6364
canvas_->set_line_width(10.0);
6465
canvas_->set_stroke_paint(Paint::from_color(ColorU::red()));

0 commit comments

Comments
 (0)