| 1 |
<?xml version="1.0" standalone="no"?> |
| 2 |
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" |
| 3 |
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd"> |
| 4 |
|
| 5 |
<!-- |
| 6 |
|
| 7 |
Licensed to the Apache Software Foundation (ASF) under one or more |
| 8 |
contributor license agreements. See the NOTICE file distributed with |
| 9 |
this work for additional information regarding copyright ownership. |
| 10 |
The ASF licenses this file to You under the Apache License, Version 2.0 |
| 11 |
(the "License"); you may not use this file except in compliance with |
| 12 |
the License. You may obtain a copy of the License at |
| 13 |
|
| 14 |
http://www.apache.org/licenses/LICENSE-2.0 |
| 15 |
|
| 16 |
Unless required by applicable law or agreed to in writing, software |
| 17 |
distributed under the License is distributed on an "AS IS" BASIS, |
| 18 |
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 19 |
See the License for the specific language governing permissions and |
| 20 |
limitations under the License. |
| 21 |
|
| 22 |
--> |
| 23 |
<!-- ========================================================================= --> |
| 24 |
<!-- Test description here --> |
| 25 |
<!-- --> |
| 26 |
<!-- @author [email protected] --> |
| 27 |
<!-- @version $Id $ --> |
| 28 |
<!-- ========================================================================= --> |
| 29 |
<?xml-stylesheet type="text/css" href="../../resources/style/test.css" ?> |
| 30 |
|
| 31 |
<svg xmlns="http://www.w3.org/2000/svg" |
| 32 |
xmlns:xlink="http://www.w3.org/1999/xlink" |
| 33 |
id="body" width="450" height="500" viewBox="0 0 450 500"> |
| 34 |
|
| 35 |
<title>feComposite Test</title> |
| 36 |
|
| 37 |
<!-- ============================================================= --> |
| 38 |
<!-- Test content --> |
| 39 |
<!-- ============================================================= --> |
| 40 |
<g id="testContent"> |
| 41 |
|
| 42 |
<text x="225" y="40" class="title"> |
| 43 |
feComposite Test |
| 44 |
</text> |
| 45 |
|
| 46 |
<defs> |
| 47 |
|
| 48 |
<circle id="Circle1" cx="40" cy="60" r="30" style="fill:orange" /> |
| 49 |
|
| 50 |
<circle id="Circle2" cx="80" cy="60" r="30" style="fill:blue" /> |
| 51 |
|
| 52 |
<filter id="feImage1" x="0" y="0" width="1" height="1"> |
| 53 |
<feImage xlink:href="#Circle1"/> |
| 54 |
</filter> |
| 55 |
|
| 56 |
<filter id="feImage2" x="0" y="0" width="1" height="1"> |
| 57 |
<feImage xlink:href="#Circle2"/> |
| 58 |
</filter> |
| 59 |
|
| 60 |
<filter id="feComposite1_2" x="0" y="0" width="1" height="1"> |
| 61 |
<feImage xlink:href="#Circle1" result="c1" /> |
| 62 |
<feImage xlink:href="#Circle2" result="c2" /> |
| 63 |
<feComposite in="c1" in2="c2" operator="over" /> |
| 64 |
</filter> |
| 65 |
|
| 66 |
|
| 67 |
<filter id="feComposite1_3" x="0" y="0" width="1" height="1"> |
| 68 |
<feImage xlink:href="#Circle1" result="c1" /> |
| 69 |
<feImage xlink:href="#Circle2" result="c2" /> |
| 70 |
<feComposite in="c1" in2="c2" operator="in" /> |
| 71 |
</filter> |
| 72 |
|
| 73 |
<filter id="feComposite2_1" x="0" y="0" width="1" height="1"> |
| 74 |
<feImage xlink:href="#Circle1" result="c1" /> |
| 75 |
<feImage xlink:href="#Circle2" result="c2" /> |
| 76 |
<feComposite in="c1" in2="c2" operator="out" /> |
| 77 |
</filter> |
| 78 |
|
| 79 |
<filter id="feComposite2_2" x="0" y="0" width="1" height="1"> |
| 80 |
<feImage xlink:href="#Circle1" result="c1" /> |
| 81 |
<feImage xlink:href="#Circle2" result="c2" /> |
| 82 |
<feComposite in="c1" in2="c2" operator="atop" /> |
| 83 |
</filter> |
| 84 |
|
| 85 |
<filter id="feComposite2_3" x="0" y="0" width="1" height="1"> |
| 86 |
<feImage xlink:href="#Circle1" result="c1" /> |
| 87 |
<feImage xlink:href="#Circle2" result="c2" /> |
| 88 |
<feComposite in="c1" in2="c2" operator="xor" /> |
| 89 |
</filter> |
| 90 |
|
| 91 |
<filter id="feComposite3_1" x="0" y="0" width="1" height="1"> |
| 92 |
<feImage xlink:href="#Circle1" result="c1" /> |
| 93 |
<feImage xlink:href="#Circle2" result="c2" /> |
| 94 |
<feComposite in="c1" in2="c2" operator="arithmetic" |
| 95 |
k2="0.5" k3="0.5" /> |
| 96 |
</filter> |
| 97 |
|
| 98 |
<filter id="feComposite3_2" x="0" y="0" width="1" height="1"> |
| 99 |
<feImage xlink:href="#Circle1" result="c1" /> |
| 100 |
<feImage xlink:href="#Circle2" result="c2" /> |
| 101 |
<feComposite in="c1" in2="c2" operator="arithmetic" |
| 102 |
k2="0.75" k3="0.25" /> |
| 103 |
</filter> |
| 104 |
|
| 105 |
<filter id="feComposite3_3" x="0" y="0" width="1" height="1"> |
| 106 |
<feImage xlink:href="#Circle1" result="c1" /> |
| 107 |
<feImage xlink:href="#Circle2" result="c2" /> |
| 108 |
<feComposite in="c1" in2="c2" operator="arithmetic" |
| 109 |
k1="1" k2="0.5" k3="0.5" k4="0.2" /> |
| 110 |
</filter> |
| 111 |
|
| 112 |
</defs> |
| 113 |
|
| 114 |
<g transform="translate(0 40)" class="legend"> |
| 115 |
|
| 116 |
<!-- ============================================== --> |
| 117 |
<!-- Composite_1_* --> |
| 118 |
<!-- ============================================== --> |
| 119 |
<g transform="translate(0 20)" class="row1" > |
| 120 |
<g transform="translate(20 0)"> |
| 121 |
<rect x="0" y="0" width="120" height="120" style="fill:Beige"/> |
| 122 |
<rect x="0" y="0" width="120" height="120" |
| 123 |
style="fill:FireBrick; filter:url(#feImage1)"/> |
| 124 |
|
| 125 |
<rect x="0" y="0" width="120" height="120" |
| 126 |
style="fill:PaleVioletRed; filter:url(#feImage2); "/> |
| 127 |
|
| 128 |
<g transform="translate(60, 130)"> |
| 129 |
<text x="0" y="0" style="text-anchor:middle"> |
| 130 |
1.1 Check FeImage |
| 131 |
</text> |
| 132 |
</g> |
| 133 |
</g> |
| 134 |
|
| 135 |
<g transform="translate(160 0)"> |
| 136 |
<rect x="0" y="0" width="120" height="120" style="fill:Beige"/> |
| 137 |
<rect x="0" y="0" width="120" height="120" |
| 138 |
style="fill:FireBrick; filter:url(#feComposite1_2)" /> |
| 139 |
<g transform="translate(60, 130)"> |
| 140 |
<text x="0" y="0" style="text-anchor:middle"> |
| 141 |
1.2 Orange over blue |
| 142 |
</text> |
| 143 |
</g> |
| 144 |
</g> |
| 145 |
|
| 146 |
|
| 147 |
<g transform="translate(300 0)"> |
| 148 |
<rect x="0" y="0" width="120" height="120" style="fill:Beige"/> |
| 149 |
<rect x="0" y="0" width="120" height="120" |
| 150 |
style="fill:FireBrick; filter:url(#feComposite1_3)" /> |
| 151 |
<g transform="translate(60, 130)"> |
| 152 |
<text x="0" y="0" style="text-anchor:middle"> |
| 153 |
1.3 Orange in blue |
| 154 |
</text> |
| 155 |
</g> |
| 156 |
</g> |
| 157 |
</g> |
| 158 |
|
| 159 |
<!-- ============================================== --> |
| 160 |
<!-- Composite_2_* --> |
| 161 |
<!-- ============================================== --> |
| 162 |
<g transform="translate(0 160)" class="row2" > |
| 163 |
<g transform="translate(20 0)"> |
| 164 |
<rect x="0" y="0" width="120" height="120" style="fill:Beige"/> |
| 165 |
<rect x="0" y="0" width="120" height="120" |
| 166 |
style="fill:FireBrick; filter:url(#feComposite2_1)"/> |
| 167 |
<g transform="translate(60, 130)"> |
| 168 |
<text x="0" y="0" style="text-anchor:middle"> |
| 169 |
2.1 Orange out blue |
| 170 |
</text> |
| 171 |
</g> |
| 172 |
</g> |
| 173 |
|
| 174 |
<g transform="translate(160 0)"> |
| 175 |
<rect x="0" y="0" width="120" height="120" style="fill:Beige"/> |
| 176 |
<rect x="0" y="0" width="120" height="120" |
| 177 |
style="fill:FireBrick; filter:url(#feComposite2_2)" /> |
| 178 |
<g transform="translate(60, 130)"> |
| 179 |
<text x="0" y="0" style="text-anchor:middle"> |
| 180 |
2.2 Orange atop blue |
| 181 |
</text> |
| 182 |
</g> |
| 183 |
</g> |
| 184 |
|
| 185 |
|
| 186 |
<g transform="translate(300 0)"> |
| 187 |
<rect x="0" y="0" width="120" height="120" style="fill:Beige"/> |
| 188 |
<rect x="0" y="0" width="120" height="120" |
| 189 |
style="fill:FireBrick; filter:url(#feComposite2_3)" /> |
| 190 |
<g transform="translate(60, 130)"> |
| 191 |
<text x="0" y="0" style="text-anchor:middle"> |
| 192 |
2.3 Orange xor blue |
| 193 |
</text> |
| 194 |
</g> |
| 195 |
</g> |
| 196 |
</g> |
| 197 |
|
| 198 |
<!-- ============================================== --> |
| 199 |
<!-- Composite_3_* --> |
| 200 |
<!-- ============================================== --> |
| 201 |
<g transform="translate(0 300)" class="row3" > |
| 202 |
<g transform="translate(20 0)"> |
| 203 |
<rect x="0" y="0" width="120" height="120" style="fill:Beige"/> |
| 204 |
<rect x="0" y="0" width="120" height="120" |
| 205 |
style="fill:FireBrick; filter:url(#feComposite3_1)"/> |
| 206 |
<text x="60" y="130" style="text-anchor:middle"> |
| 207 |
3.1 Orange arithmetic blue |
| 208 |
</text> |
| 209 |
<text x="60" y="140" style="text-anchor:middle"> |
| 210 |
k1=0 k2=0.5 k3=0.5 k4=0 |
| 211 |
</text> |
| 212 |
</g> |
| 213 |
|
| 214 |
<g transform="translate(160 0)"> |
| 215 |
<rect x="0" y="0" width="120" height="120" style="fill:Beige"/> |
| 216 |
<rect x="0" y="0" width="120" height="120" |
| 217 |
style="fill:FireBrick; filter:url(#feComposite3_2)" /> |
| 218 |
<text x="60" y="130" style="text-anchor:middle"> |
| 219 |
3.2 Orange arithmetic blue |
| 220 |
</text> |
| 221 |
<text x="60" y="140" style="text-anchor:middle"> |
| 222 |
k1=0 k2=0.75 k3=0.25 k4=0 |
| 223 |
</text> |
| 224 |
</g> |
| 225 |
|
| 226 |
|
| 227 |
<g transform="translate(300 0)"> |
| 228 |
<rect x="0" y="0" width="120" height="120" style="fill:Beige"/> |
| 229 |
<rect x="0" y="0" width="120" height="120" |
| 230 |
style="fill:FireBrick; filter:url(#feComposite3_3)" /> |
| 231 |
<text x="60" y="130" style="text-anchor:middle"> |
| 232 |
3.3 Orange arithmetic blue |
| 233 |
</text> |
| 234 |
<text x="60" y="140" style="text-anchor:middle"> |
| 235 |
k1=1 k2=0.5 k3=0.5 k4=0.2 |
| 236 |
</text> |
| 237 |
</g> |
| 238 |
</g> |
| 239 |
|
| 240 |
</g> |
| 241 |
</g> |
| 242 |
|
| 243 |
<!-- ============================================================= --> |
| 244 |
<!-- Batik sample mark --> |
| 245 |
<!-- ============================================================= --> |
| 246 |
<use xlink:href="../../../batikLogo.svg#Batik_Tag_Box" /> |
| 247 |
|
| 248 |
</svg> |