blob: 15b31b182e780eedd24fb7ae3a4324b0b2c454b9 [file] [log] [blame]
* Copyright 2021 Google Inc.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
#include <string>
#include "include/core/SkStream.h"
#include "include/utils/SkNoDrawCanvas.h"
#include "modules/svg/include/SkSVGDOM.h"
#include "tests/Test.h"
DEF_TEST(Svg_Filters_NonePaintInputs, r) {
const std::string svgText = R"EOF(
<svg width="500" height="500" xmlns=""
<filter id="f" x="0" y="0" width="1" height="1">
<feComposite operator="arithmetic" in="FillPaint" in2="StrokePaint"
k1="0" k2="10" k3="20" k4="0"/>
<rect fill="none" stroke="none" filter="url(#f)" x="10" y="10" width="100" height="1,0"/>
auto str = SkMemoryStream::MakeDirect(svgText.c_str(), svgText.size());
auto svg_dom = SkSVGDOM::Builder().make(*str);
SkNoDrawCanvas canvas(500, 500);