blob: d44ebe229bf63c99e18771381d8a2e3c3e0d63e1 [file] [log] [blame]
Brian Salomon908bb232018-11-19 10:05:08 -05001/*
2 * Copyright 2018 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 "gm/gm.h"
Ben Wagner7fde8e12019-05-01 17:28:53 -04009#include "include/core/SkBlendMode.h"
10#include "include/core/SkBlurTypes.h"
Mike Kleinc0bd9f92019-04-23 12:05:21 -050011#include "include/core/SkCanvas.h"
Ben Wagner7fde8e12019-05-01 17:28:53 -040012#include "include/core/SkColor.h"
Mike Kleinc0bd9f92019-04-23 12:05:21 -050013#include "include/core/SkColorFilter.h"
Ben Wagner7fde8e12019-05-01 17:28:53 -040014#include "include/core/SkMaskFilter.h"
15#include "include/core/SkMatrix.h"
16#include "include/core/SkPaint.h"
17#include "include/core/SkRect.h"
Brian Salomon908bb232018-11-19 10:05:08 -050018
19DEF_SIMPLE_GM(crbug_899512, canvas, 520, 520) {
20 // comment this line below to solve the problem
21 SkMatrix matrix;
22 matrix.setAll(-1, 0, 220, 0, 1, 0, 0, 0, 1);
23 canvas->concat(matrix);
24 SkPaint paint;
25 paint.setMaskFilter(SkMaskFilter::MakeBlur(kNormal_SkBlurStyle, 6.2735f, false));
Mike Reedb286bc22019-04-08 16:23:20 -040026 paint.setColorFilter(SkColorFilters::Blend(SK_ColorBLACK, SkBlendMode::kSrcIn));
Brian Salomon908bb232018-11-19 10:05:08 -050027 canvas->drawRect(SkRect::MakeXYWH(0, 10, 200, 200), paint);
28}