| 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="Tim Thompson" status="accepted" |
| 15 |
version="$Revision: 1.7 $" testname="$RCSfile: painting-render-01-b.svg,v $"> |
| 16 |
<d:testDescription xmlns="http://www.w3.org/1999/xhtml" href="http://www.w3.org/TR/SVG11/painting.html#RenderingProperties"> |
| 17 |
<p> |
| 18 |
This tests shows the same linear gradient used with different values for the |
| 19 |
color-interpolation rendering property. The top bar is painted using the |
| 20 |
default color-interpolation value, which should produce the same result as |
| 21 |
sRGB. The middle bar is painted using the 'sRGB' color-interpolation and |
| 22 |
should be the same as the top bar. Finally, the bottom bar is painted using |
| 23 |
the linearRGB interpolation, which produces a result visibly different from |
| 24 |
the top two bars: the white to blue ramp is whiter, the blue to red ramp |
| 25 |
goes through a pinkish color and the red to yellow ramp turns orange before |
| 26 |
the similar sRGB rampl. |
| 27 |
</p> |
| 28 |
</d:testDescription> |
| 29 |
<d:operatorScript xmlns="http://www.w3.org/1999/xhtml"> |
| 30 |
<p> |
| 31 |
Run the test. No interaction required. |
| 32 |
</p> |
| 33 |
</d:operatorScript> |
| 34 |
<d:passCriteria xmlns="http://www.w3.org/1999/xhtml"> |
| 35 |
<p> |
| 36 |
The top two gradients must look the same, and the bottom gradient must look |
| 37 |
different to the top two. The rendered picture should match the reference image, except for possible |
| 38 |
variations in the labelling text (per CSS2 rules). |
| 39 |
</p> |
| 40 |
</d:passCriteria> |
| 41 |
</d:SVGTestCase> |
| 42 |
<title id="test-title">$RCSfile: painting-render-01-b.svg,v $</title> |
| 43 |
<defs> |
| 44 |
<font-face font-family="SVGFreeSansASCII" unicode-range="U+0-7F"> |
| 45 |
<font-face-src> |
| 46 |
<font-face-uri xlink:href="../resources/SVGFreeSans.svg#ascii"/> |
| 47 |
</font-face-src> |
| 48 |
</font-face> |
| 49 |
</defs> |
| 50 |
<g id="test-body-content" font-family="SVGFreeSansASCII,sans-serif" font-size="18"> |
| 51 |
<defs> |
| 52 |
<linearGradient id="gradientDefault" gradientUnits="objectBoundingBox"> |
| 53 |
<stop offset="0" stop-color="white"/> |
| 54 |
<stop offset=".33" stop-color="blue"/> |
| 55 |
<stop offset=".66" stop-color="red"/> |
| 56 |
<stop offset="1" stop-color="yellow"/> |
| 57 |
</linearGradient> |
| 58 |
<linearGradient id="gradientSRGB" gradientUnits="objectBoundingBox" color-interpolation="sRGB"> |
| 59 |
<stop offset="0" stop-color="white"/> |
| 60 |
<stop offset=".33" stop-color="blue"/> |
| 61 |
<stop offset=".66" stop-color="red"/> |
| 62 |
<stop offset="1" stop-color="yellow"/> |
| 63 |
</linearGradient> |
| 64 |
<linearGradient id="gradientLinearRGB" gradientUnits="objectBoundingBox" color-interpolation="linearRGB"> |
| 65 |
<stop offset="0" stop-color="white"/> |
| 66 |
<stop offset=".33" stop-color="blue"/> |
| 67 |
<stop offset=".66" stop-color="red"/> |
| 68 |
<stop offset="1" stop-color="yellow"/> |
| 69 |
</linearGradient> |
| 70 |
</defs> |
| 71 |
<text font-size="22" text-anchor="middle" x="225" y="30">Basic test of color-interpolation property.</text> |
| 72 |
<!-- ====================================== --> |
| 73 |
<!-- Default color-interpolation (sRGB) --> |
| 74 |
<!-- ====================================== --> |
| 75 |
<g transform="translate(40, 80)"> |
| 76 |
<rect x="0" y="0" width="300" height="40" fill="url(#gradientDefault)" stroke="black"/> |
| 77 |
<circle cx="0" cy="-10" r="3" fill="white" stroke="black"/> |
| 78 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black"/> |
| 79 |
<rect x="48" y="18" width="4" height="4" fill="rgb(128, 128, 255)" stroke="black"/> |
| 80 |
<line x1="50" y1="15" x2="50" y2="25" stroke="rgb(128, 128, 255)"/> |
| 81 |
<circle cx="100" cy="-10" r="3" fill="blue" stroke="black"/> |
| 82 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black" transform="translate(100, 0)"/> |
| 83 |
<rect x="148" y="18" width="4" height="4" fill="rgb(128, 0, 128)" stroke="black"/> |
| 84 |
<line x1="150" y1="15" x2="150" y2="25" stroke="rgb(128, 0, 128)"/> |
| 85 |
<circle cx="200" cy="-10" r="3" fill="red" stroke="black"/> |
| 86 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black" transform="translate(200, 0)"/> |
| 87 |
<rect x="248" y="18" width="4" height="4" fill="rgb(255, 128, 0)" stroke="black"/> |
| 88 |
<line x1="250" y1="15" x2="250" y2="25" stroke="rgb(255, 128, 0)"/> |
| 89 |
<circle cx="300" cy="-10" r="3" fill="yellow" stroke="black"/> |
| 90 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black" transform="translate(300, 0)"/> |
| 91 |
<text x="310" y="20" font-size="16">default (sRGB)</text> |
| 92 |
</g> |
| 93 |
<!-- ====================================== --> |
| 94 |
<!-- sRGB color-interpolation --> |
| 95 |
<!-- ====================================== --> |
| 96 |
<g transform="translate(40, 160)"> |
| 97 |
<rect x="0" y="0" width="300" height="40" fill="url(#gradientSRGB)" stroke="black"/> |
| 98 |
<circle cx="0" cy="-10" r="3" fill="white" stroke="black"/> |
| 99 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black"/> |
| 100 |
<rect x="48" y="18" width="4" height="4" fill="rgb(128, 128, 255)" stroke="black"/> |
| 101 |
<line x1="50" y1="15" x2="50" y2="25" stroke="rgb(128, 128, 255)"/> |
| 102 |
<circle cx="100" cy="-10" r="3" fill="blue" stroke="black"/> |
| 103 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black" transform="translate(100, 0)"/> |
| 104 |
<rect x="148" y="18" width="4" height="4" fill="rgb(128, 0, 128)" stroke="black"/> |
| 105 |
<line x1="150" y1="15" x2="150" y2="25" stroke="rgb(128, 0, 128)"/> |
| 106 |
<circle cx="200" cy="-10" r="3" fill="red" stroke="black"/> |
| 107 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black" transform="translate(200, 0)"/> |
| 108 |
<rect x="248" y="18" width="4" height="4" fill="rgb(255, 128, 0)" stroke="black"/> |
| 109 |
<line x1="250" y1="15" x2="250" y2="25" stroke="rgb(255, 128, 0)"/> |
| 110 |
<circle cx="300" cy="-10" r="3" fill="yellow" stroke="black"/> |
| 111 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black" transform="translate(300, 0)"/> |
| 112 |
<text x="310" y="20" font-size="16">sRGB</text> |
| 113 |
</g> |
| 114 |
<!-- ====================================== --> |
| 115 |
<!-- linearRGB color-interpolation --> |
| 116 |
<!-- ====================================== --> |
| 117 |
<g transform="translate(40, 240)"> |
| 118 |
<rect x="0" y="0" width="300" height="40" fill="url(#gradientLinearRGB)" stroke="black"/> |
| 119 |
<circle cx="0" cy="-10" r="3" fill="white" stroke="black"/> |
| 120 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black"/> |
| 121 |
<rect x="48" y="18" width="4" height="4" fill="rgb(128, 128, 255)" stroke="black"/> |
| 122 |
<line x1="50" y1="15" x2="50" y2="25" stroke="rgb(128, 128, 255)"/> |
| 123 |
<circle cx="100" cy="-10" r="3" fill="blue" stroke="black"/> |
| 124 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black" transform="translate(100, 0)"/> |
| 125 |
<rect x="148" y="18" width="4" height="4" fill="rgb(128, 0, 128)" stroke="black"/> |
| 126 |
<line x1="150" y1="15" x2="150" y2="25" stroke="rgb(128, 0, 128)"/> |
| 127 |
<circle cx="200" cy="-10" r="3" fill="red" stroke="black"/> |
| 128 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black" transform="translate(200, 0)"/> |
| 129 |
<rect x="248" y="18" width="4" height="4" fill="rgb(255, 128, 0)" stroke="black"/> |
| 130 |
<line x1="250" y1="15" x2="250" y2="25" stroke="rgb(255, 128, 0)"/> |
| 131 |
<circle cx="300" cy="-10" r="3" fill="yellow" stroke="black"/> |
| 132 |
<line x1="0" y1="-7" x2="0" y2="40" stroke="black" transform="translate(300, 0)"/> |
| 133 |
<text x="310" y="20" font-size="16">linearRGB</text> |
| 134 |
</g> |
| 135 |
</g> |
| 136 |
<g font-family="SVGFreeSansASCII,sans-serif" font-size="32"> |
| 137 |
<text id="revision" x="10" y="340" stroke="none" fill="black">$Revision: 1.7 $</text> |
| 138 |
</g> |
| 139 |
<rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000000"/> |
| 140 |
<!-- comment out this watermark once the test is approved --> |
| 141 |
<!--<g id="draft-watermark"> |
| 142 |
<rect x="1" y="1" width="478" height="20" fill="red" stroke="black" stroke-width="1"/> |
| 143 |
<text font-family="SVGFreeSansASCII,sans-serif" font-weight="bold" font-size="20" x="240" |
| 144 |
text-anchor="middle" y="18" stroke-width="0.5" stroke="black" fill="white">DRAFT</text> |
| 145 |
</g>--> |
| 146 |
</svg> |