Debian Codegraph @

test_non_regression/fail/filter/filters-comptran-01-b.svg

raw
1 <svg version="1.1" baseProfile="basic" id="svg-root"
2 width="100%" height="100%" viewBox="0 0 480 360"
3 xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
4 <!--======================================================================-->
5 <!--= SVG 1.1 2nd Edition Test Case =-->
6 <!--======================================================================-->
7 <!--= Copyright 2009 World Wide Web Consortium, (Massachusetts =-->
8 <!--= Institute of Technology, European Research Consortium for =-->
9 <!--= Informatics and Mathematics (ERCIM), Keio University). =-->
10 <!--= All Rights Reserved. =-->
11 <!--= See http://www.w3.org/Consortium/Legal/. =-->
12 <!--======================================================================-->
13 <d:SVGTestCase xmlns:d="http://www.w3.org/2000/02/svg/testsuite/description/"
14 template-version="1.4" reviewer="SVGWG" author="Jon Ferraiolo" status="accepted"
15 version="$Revision: 1.6 $" testname="$RCSfile: filters-comptran-01-b.svg,v $">
16 <d:testDescription xmlns="http://www.w3.org/1999/xhtml" href="http://www.w3.org/TR/SVG11/filters.html#feComponentTransferElement">
17 <p>
18 Test which verifies the basic facilities of
19 feComponentTransfer.
20 </p>
21 <p>
22 This test uses the following elements : a nested &lt;svg&gt;
23 with a viewBox attribute, &lt;linearGradient&gt;, &lt;filter&gt;,
24 &lt;feComponentTransfer&gt;.
25 </p>
26 <p>
27 The test case shows four rectangles filled with a
28 gradient showing the effects of feComponentTransfer: an
29 identity function acting as a reference, use of the
30 feComponentTransfer table option, use of the
31 feComponentTransfer linear option, and use of the
32 feComponentTransfer gamma option.
33 </p>
34 <p>
35 The test is somewhat self-explanatory as the strings
36 document the type of feComponentTransfer operation that
37 is being used.
38 </p>
39 </d:testDescription>
40 <d:operatorScript xmlns="http://www.w3.org/1999/xhtml">
41 <p>
42 Run the test. No interaction required.
43 </p>
44 </d:operatorScript>
45 <d:passCriteria xmlns="http://www.w3.org/1999/xhtml">
46 <p>
47 The rendered picture should match the reference image
48 exactly, except for possible variations in the
49 labelling text (per CSS2 rules).
50 </p>
51 </d:passCriteria>
52 </d:SVGTestCase>
53 <title id="test-title">$RCSfile: filters-comptran-01-b.svg,v $</title>
54 <defs>
55 <font-face font-family="SVGFreeSansASCII" unicode-range="U+0-7F">
56 <font-face-src>
57 <font-face-uri xlink:href="../resources/SVGFreeSans.svg#ascii"/>
58 </font-face-src>
59 </font-face>
60 </defs>
61 <g id="test-body-content" font-family="SVGFreeSansASCII,sans-serif" font-size="18">
62 <svg xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" x="15" y="5" width="450" height="300" viewBox="0 0 630 420">
63 <title>Example feComponentTransfer - Examples of feComponentTransfer operations</title>
64 <desc>Four rectangles filled with a gradient showing the effects of feComponentTransfer: an identity function acting as a reference, use of the feComponentTransfer table option, use of the feComponentTransfer linear option, and use of the feComponentTransfer gamma option.</desc>
65 <defs>
66 <linearGradient id="MyGradient" gradientUnits="userSpaceOnUse" x1="10" y1="0" x2="590" y2="0">
67 <stop offset="0" stop-color="#ff0000"/>
68 <stop offset=".33" stop-color="#00ff00"/>
69 <stop offset=".67" stop-color="#0000ff"/>
70 <stop offset="1" stop-color="#000000"/>
71 </linearGradient>
72 <filter id="Identity" filterUnits="objectBoundingBox" x="0%" y="0%" width="100%" height="100%">
73 <feComponentTransfer>
74 <feFuncR type="identity"/>
75 <feFuncG type="identity"/>
76 <feFuncB type="identity"/>
77 <feFuncA type="identity"/>
78 </feComponentTransfer>
79 </filter>
80 <filter id="Table" filterUnits="objectBoundingBox" x="0%" y="0%" width="100%" height="100%">
81 <feComponentTransfer>
82 <feFuncR type="table" tableValues="0 0 1 1"/>
83 <feFuncG type="table" tableValues="1 1 0 0"/>
84 <feFuncB type="table" tableValues="0 1 1 0"/>
85 </feComponentTransfer>
86 </filter>
87 <filter id="Linear" filterUnits="objectBoundingBox" x="0%" y="0%" width="100%" height="100%">
88 <feComponentTransfer>
89 <feFuncR type="linear" slope=".5" intercept=".25"/>
90 <feFuncG type="linear" slope=".5" intercept="0"/>
91 <feFuncB type="linear" slope=".5" intercept=".5"/>
92 </feComponentTransfer>
93 </filter>
94 <filter id="Gamma" filterUnits="objectBoundingBox" x="0%" y="0%" width="100%" height="100%">
95 <feComponentTransfer>
96 <feFuncR type="gamma" amplitude="2" exponent="5" offset="0"/>
97 <feFuncG type="gamma" amplitude="2" exponent="3" offset="0"/>
98 <feFuncB type="gamma" amplitude="2" exponent="1" offset="0"/>
99 </feComponentTransfer>
100 </filter>
101 </defs>
102 <rect fill="none" stroke="blue" x="1" y="1" width="628" height="418"/>
103 <g font-size="30" font-family="Verdana">
104 <rect fill="none" stroke="blue" x="1" y="1" width="628" height="418"/>
105 <rect x="10" y="10" width="580" height="40" fill="url(#MyGradient)" filter="url(#Identity)"/>
106 <text x="10" y="80">type: identity</text>
107 <rect x="10" y="110" width="580" height="40" fill="url(#MyGradient)" filter="url(#Table)"/>
108 <text x="10" y="180">type: table</text>
109 <rect x="10" y="210" width="580" height="40" fill="url(#MyGradient)" filter="url(#Linear)"/>
110 <text x="10" y="280">type:linear slope:.5 intercepts:.25/0/.5</text>
111 <rect x="10" y="310" width="580" height="40" fill="url(#MyGradient)" filter="url(#Gamma)"/>
112 <text x="10" y="380">type: gamma ampl:2 exponents:5/3/1</text>
113 </g>
114 </svg>
115 </g>
116 <g font-family="SVGFreeSansASCII,sans-serif" font-size="32">
117 <text id="revision" x="10" y="340" stroke="none" fill="black">$Revision: 1.6 $</text>
118 </g>
119 <rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000"/>
120 <!-- comment out this watermark once the test is approved -->
121 <!--<g id="draft-watermark">
122 <rect x="1" y="1" width="478" height="20" fill="red" stroke="black" stroke-width="1"/>
123 <text font-family="SVGFreeSansASCII,sans-serif" font-weight="bold" font-size="20" x="240"
124 text-anchor="middle" y="18" stroke-width="0.5" stroke="black" fill="white">DRAFT</text>
125 </g>-->
126 </svg>