| 1 |
<svg id="svg-root" width="100%" height="100%" |
| 2 |
viewBox="0 0 480 360" xmlns="http://www.w3.org/2000/svg" |
| 3 |
xmlns:xlink="http://www.w3.org/1999/xlink"> |
| 4 |
<!--======================================================================--> |
| 5 |
<!--= Copyright 2008 World Wide Web Consortium, (Massachusetts =--> |
| 6 |
<!--= Institute of Technology, European Research Consortium for =--> |
| 7 |
<!--= Informatics and Mathematics (ERCIM), Keio University). =--> |
| 8 |
<!--= All Rights Reserved. =--> |
| 9 |
<!--= See http://www.w3.org/Consortium/Legal/. =--> |
| 10 |
<!--======================================================================--> |
| 11 |
<d:SVGTestCase xmlns:d="http://www.w3.org/2000/02/svg/testsuite/description/" |
| 12 |
template-version="1.3" reviewer="CL" author="ED" status="accepted" |
| 13 |
version="$Revision: 1.10 $" testname="$RCSfile: filters-light-03-f.svg,v $"> |
| 14 |
<d:testDescription xmlns="http://www.w3.org/1999/xhtml" href="http://www.w3.org/TR/SVG11/filters.html#feDisplacementMap"> |
| 15 |
<p> |
| 16 |
Test resolving of 'primitiveUnits' on the 'z' attribute of 'fePointLight'. |
| 17 |
You should see some shapes that have a black border, three circles and three rectangles. |
| 18 |
The fill of these shapes should look the same. |
| 19 |
</p> |
| 20 |
</d:testDescription> |
| 21 |
<d:operatorScript xmlns="http://www.w3.org/1999/xhtml"> |
| 22 |
<p> |
| 23 |
Run the test. No interaction required. |
| 24 |
</p> |
| 25 |
</d:operatorScript> |
| 26 |
<d:passCriteria xmlns="http://www.w3.org/1999/xhtml"> |
| 27 |
<p> |
| 28 |
The test has passed if: |
| 29 |
</p> |
| 30 |
<ul> |
| 31 |
<li>All of the circles look identical</li> |
| 32 |
<li>The shapes all look like they have been filled with a gradient</li> |
| 33 |
<li>No parts of the fill extend outside the black borders</li> |
| 34 |
<li>All of the rects look identical</li> |
| 35 |
<li>The circles must be fully filled by the filter output, which should resemble a radial gradient with a white focal point in the lower right position (about four o'clock, as shown by the small white circles)</li> |
| 36 |
<li>The rects must be fully filled by the filter output, which should resemble a radial gradient with a white focal point in the lower right corner.</li> |
| 37 |
</ul> |
| 38 |
</d:passCriteria> |
| 39 |
</d:SVGTestCase> |
| 40 |
<title id="test-title">$RCSfile: filters-light-03-f.svg,v $</title> |
| 41 |
<defs> |
| 42 |
<font-face |
| 43 |
font-family="SVGFreeSansASCII" |
| 44 |
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 |
|
| 51 |
<g id="test-body-content" font-family="SVGFreeSansASCII,sans-serif" font-size="18"> |
| 52 |
<defs> |
| 53 |
<filter id="light-primobjbbox" primitiveUnits="objectBoundingBox"> |
| 54 |
<feSpecularLighting lighting-color="blue" surfaceScale="5" specularConstant="10" specularExponent="6"> |
| 55 |
<!-- Note: for z this assumes that the scalefactor is |
| 56 |
sqrt(bbox.width*bbox.width + bbox.height*bbox.height)/sqrt(2) --> |
| 57 |
<fePointLight x="0.875" y="0.875" z="-0.0625"/> |
| 58 |
</feSpecularLighting> |
| 59 |
<feComposite operator="in" in2="SourceGraphic"/> |
| 60 |
</filter> |
| 61 |
<filter id="light-primobjbbox-rect" primitiveUnits="objectBoundingBox"> |
| 62 |
<feSpecularLighting lighting-color="blue" surfaceScale="5" specularConstant="10" specularExponent="6"> |
| 63 |
<!-- Note: for z the scalefactor is 31,622776601683793319988935444327 |
| 64 |
sqrt(bbox.width*bbox.width + bbox.height*bbox.height)/sqrt(2) --> |
| 65 |
<fePointLight x="0.75" y="1.5" z="-0.15811388300841896659994467722167"/> |
| 66 |
</feSpecularLighting> |
| 67 |
<feComposite operator="in" in2="SourceGraphic"/> |
| 68 |
</filter> |
| 69 |
<filter id="light-primusou" primitiveUnits="userSpaceOnUse"> |
| 70 |
<feSpecularLighting lighting-color="blue" surfaceScale="5" specularConstant="10" specularExponent="6"> |
| 71 |
<fePointLight x="30" y="30" z="-5"/> |
| 72 |
</feSpecularLighting> |
| 73 |
<feComposite operator="in" in2="SourceGraphic"/> |
| 74 |
</filter> |
| 75 |
<filter id="light-primdefault"> |
| 76 |
<feSpecularLighting lighting-color="blue" surfaceScale="5" specularConstant="10" specularExponent="6"> |
| 77 |
<fePointLight x="30" y="30" z="-5"/> |
| 78 |
</feSpecularLighting> |
| 79 |
<feComposite operator="in" in2="SourceGraphic"/> |
| 80 |
</filter> |
| 81 |
</defs> |
| 82 |
|
| 83 |
<g stroke="black" transform="translate(80 100)"> |
| 84 |
<circle r="40" stroke-width="10" filter="url(#light-primobjbbox)" fill="black"/> |
| 85 |
<circle r="44" stroke-width="1" fill="none"/> |
| 86 |
<rect width="40" height="20" filter="url(#light-primobjbbox-rect)" fill="black" transform="translate(-20 60)"/> |
| 87 |
<rect width="40" height="20" fill="none" transform="translate(-20 60)"/> |
| 88 |
<text y="100" font-size="8" stroke="none" text-anchor="middle">primitiveUnits="objectBoundingBox"</text> |
| 89 |
<circle cx="30" cy="30" r="5" fill="white"/> |
| 90 |
</g> |
| 91 |
|
| 92 |
<g stroke="black" transform="translate(245 100)"> |
| 93 |
<circle r="40" stroke-width="10" filter="url(#light-primusou)" fill="black"/> |
| 94 |
<circle r="44" stroke-width="1" fill="none"/> |
| 95 |
<rect width="40" height="20" filter="url(#light-primusou)" fill="black" transform="translate(-20 60)"/> |
| 96 |
<rect width="40" height="20" fill="none" transform="translate(-20 60)"/> |
| 97 |
<text y="100" font-size="8" stroke="none" text-anchor="middle">primitiveUnits="userSpaceOnUse"</text> |
| 98 |
<circle cx="30" cy="30" r="5" fill="white"/> |
| 99 |
</g> |
| 100 |
|
| 101 |
<g stroke="black" transform="translate(400 100)"> |
| 102 |
<circle r="40" stroke-width="10" filter="url(#light-primdefault)" fill="black"/> |
| 103 |
<circle r="44" stroke-width="1" fill="none"/> |
| 104 |
<rect width="40" height="20" filter="url(#light-primdefault)" fill="black" transform="translate(-20 60)"/> |
| 105 |
<rect width="40" height="20" fill="none" transform="translate(-20 60)"/> |
| 106 |
<text y="100" font-size="8" stroke="none" text-anchor="middle">primitiveUnits unspecified</text> |
| 107 |
<circle cx="30" cy="30" r="5" fill="white"/> |
| 108 |
</g> |
| 109 |
</g> |
| 110 |
|
| 111 |
<g font-family="SVGFreeSansASCII,sans-serif" font-size="32"> |
| 112 |
<text id="revision" x="10" y="340" stroke="none" |
| 113 |
fill="black">$Revision: 1.10 $</text> |
| 114 |
</g> |
| 115 |
|
| 116 |
<rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000"/> |
| 117 |
<!-- comment out this watermark once the test is approved --><!-- |
| 118 |
<g id="draft-watermark"> |
| 119 |
<rect x="1" y="1" width="478" height="20" fill="red" stroke="black" stroke-width="1"/> |
| 120 |
<text font-family="SVGFreeSansASCII,sans-serif" font-weight="bold" font-size="20" x="240" |
| 121 |
text-anchor="middle" y="18" stroke-width="0.5" stroke="black" fill="white">DRAFT</text> |
| 122 |
</g>--> |
| 123 |
</svg> |
| 124 |
|