blob: 0b93cfb1786f54d2e295d0b64a4ab1942f7eaee7 [file] [log] [blame]
Hal Canary27ecd862017-03-21 14:00:35 -07001/*
2 * Copyright 2017 Google Inc.
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
Mike Kleinc0bd9f92019-04-23 12:05:21 -05008#include "include/core/SkCanvas.h"
9#include "include/core/SkMaskFilter.h"
10#include "include/core/SkSurface.h"
Michael Ludwig55edb502019-08-05 10:41:10 -040011#include "include/effects/SkImageFilters.h"
Mike Kleinc0bd9f92019-04-23 12:05:21 -050012#include "tests/Test.h"
13#include "tools/Resources.h"
Hal Canary27ecd862017-03-21 14:00:35 -070014
15DEF_TEST(skbug_6389, r) {
16 auto s = SkSurface::MakeRasterN32Premul(100, 100);
17 SkPaint p;
Mike Reed1be1f8d2018-03-14 13:01:17 -040018 p.setMaskFilter(SkMaskFilter::MakeBlur(SkBlurStyle::kNormal_SkBlurStyle, 5));
Michael Ludwig55edb502019-08-05 10:41:10 -040019 p.setImageFilter(SkImageFilters::Image(GetResourceAsImage("images/mandrill_512.png"),
20 {0, 0, 0, 0}, {0, 0, 0, 0}, kNone_SkFilterQuality));
Hal Canary27ecd862017-03-21 14:00:35 -070021 s->getCanvas()->drawPaint(p);
22}