| 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.4" reviewer="ED" author="CL" status="accepted" |
| 13 |
version="$Revision: 1.2 $" testname="$RCSfile: struct-image-15-f.svg,v $"> |
| 14 |
<d:testDescription xmlns="http://www.w3.org/1999/xhtml" href="http://www.w3.org/TR/SVG11/[chapter]#[section]"> |
| 15 |
<p> |
| 16 |
The first row tests that alpha PNG images are correctly displayed as part of an SVG image, |
| 17 |
ignoring the background colour in the image which is only used to display the |
| 18 |
PNG image stand-alone. |
| 19 |
</p> |
| 20 |
<p>The second row tests indexed PNG transparency (tRNs), again checking that |
| 21 |
the background color is ignored when displayed as part of an SVG image. |
| 22 |
</p> |
| 23 |
<p> |
| 24 |
This test uses the |
| 25 |
<a href="http://www.schaik.com/pngsuite/">PNG Group test suite</a> |
| 26 |
created by Willem van Schaik. |
| 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 test is passed if all the small PNG icons are displayed as in the reference image. |
| 37 |
</p> |
| 38 |
</d:passCriteria> |
| 39 |
</d:SVGTestCase> |
| 40 |
<title id="test-title">$RCSfile: struct-image-15-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 |
<g id="test-body-content" font-family="SVGFreeSansASCII,sans-serif" font-size="18"> |
| 51 |
|
| 52 |
<!-- something to show transparency --> |
| 53 |
<rect x="16" y="32" width="368" height="8" fill="#3C3"/> |
| 54 |
<rect x="16" y="48" width="368" height="8" fill="#9F9"/> |
| 55 |
|
| 56 |
<!-- 8 bit grayscale, alpha, no background chunk, interlaced --> |
| 57 |
<image xlink:href="../images/PngSuite/bgai4a08.png" x="16" y="32" width="32" height="32"/> |
| 58 |
|
| 59 |
<!-- 16 bit grayscale, alpha, no background chunk, interlaced --> |
| 60 |
<image xlink:href="../images/PngSuite/bgai4a16.png" x="64" y="32" width="32" height="32"/> |
| 61 |
|
| 62 |
<!-- 8 bits rgb color, alpha, no background chunk --> |
| 63 |
<image xlink:href="../images/PngSuite/bgan6a08.png" x="112" y="32" width="32" height="32"/> |
| 64 |
|
| 65 |
<!-- 16 bits rgb color, alpha, no background chunk --> |
| 66 |
<image xlink:href="../images/PngSuite/bgan6a16.png" x="160" y="32" width="32" height="32"/> |
| 67 |
|
| 68 |
<!-- 8 bit grayscale, alpha, black background chunk --> |
| 69 |
<image xlink:href="../images/PngSuite/bgbn4a08.png" x="208" y="32" width="32" height="32"/> |
| 70 |
|
| 71 |
<!-- 16 bit grayscale, alpha, gray background chunk --> |
| 72 |
<image xlink:href="../images/PngSuite/bggn4a16.png" x="256" y="32" width="32" height="32"/> |
| 73 |
|
| 74 |
<!-- 8 bits rgb color, alpha, white background chunk --> |
| 75 |
<image xlink:href="../images/PngSuite/bgwn6a08.png" x="304" y="32" width="32" height="32"/> |
| 76 |
|
| 77 |
<!-- 16 bits rgb color, alpha, yellow background chunk --> |
| 78 |
<image xlink:href="../images/PngSuite/bgyn6a16.png" x="352" y="32" width="32" height="32"/> |
| 79 |
|
| 80 |
<text x="16" y="100" font-size="16" fill="#3C3">Background color, with alpha</text> |
| 81 |
|
| 82 |
<!-- something to show transparency --> |
| 83 |
<rect x="16" y="132" width="464" height="8" fill="#9F9"/> |
| 84 |
<rect x="16" y="148" width="464" height="8" fill="#3C3"/> |
| 85 |
|
| 86 |
<!-- transparent, black background chunk --> |
| 87 |
<image xlink:href="../images/PngSuite/tbbn1g04.png" x="16" y="132" width="32" height="32"/> |
| 88 |
|
| 89 |
<!-- transparent, blue background chunk --> |
| 90 |
<image xlink:href="../images/PngSuite/tbbn2c16.png" x="64" y="132" width="32" height="32"/> |
| 91 |
|
| 92 |
<!-- transparent, black background chunk --> |
| 93 |
<image xlink:href="../images/PngSuite/tbbn3p08.png" x="112" y="132" width="32" height="32"/> |
| 94 |
|
| 95 |
<!-- transparent, green background chunk --> |
| 96 |
<image xlink:href="../images/PngSuite/tbgn2c16.png" x="160" y="132" width="32" height="32"/> |
| 97 |
|
| 98 |
<!-- transparent, light-gray background chunk --> |
| 99 |
<image xlink:href="../images/PngSuite/tbgn3p08.png" x="208" y="132" width="32" height="32"/> |
| 100 |
|
| 101 |
<!-- transparent, red background chunk --> |
| 102 |
<image xlink:href="../images/PngSuite/tbrn2c08.png" x="256" y="132" width="32" height="32"/> |
| 103 |
|
| 104 |
<!-- transparent, white background chunk --> |
| 105 |
<image xlink:href="../images/PngSuite/tbwn1g16.png" x="304" y="132" width="32" height="32"/> |
| 106 |
|
| 107 |
<!-- transparent, white background chunk --> |
| 108 |
<image xlink:href="../images/PngSuite/tbwn3p08.png" x="352" y="132" width="32" height="32"/> |
| 109 |
|
| 110 |
<!-- transparent, yellow background chunk --> |
| 111 |
<image xlink:href="../images/PngSuite/tbyn3p08.png" x="400" y="132" width="32" height="32"/> |
| 112 |
|
| 113 |
<!-- transparent, but no background chunk --> |
| 114 |
<image xlink:href="../images/PngSuite/tp1n3p08.png" x="448" y="132" width="32" height="32"/> |
| 115 |
|
| 116 |
<text x="16" y="200" font-size="16" fill="#3C3">Background color, with transparency</text> |
| 117 |
|
| 118 |
<text x="16" y="260" font-size="24" fill="#3C3">Handling bKGd and tRNs</text> |
| 119 |
|
| 120 |
<!-- |
| 121 |
<image xlink:href="../images/PngSuite/" x="" y="" width="32" height="32"/> |
| 122 |
--> |
| 123 |
|
| 124 |
</g> |
| 125 |
<g font-family="SVGFreeSansASCII,sans-serif" font-size="32"> |
| 126 |
<text id="revision" x="10" y="340" stroke="none" |
| 127 |
fill="black">$Revision: 1.2 $</text> |
| 128 |
</g> |
| 129 |
<rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000"/> |
| 130 |
<!-- comment out this watermark once the test is approved --> |
| 131 |
<!-- |
| 132 |
<g id="draft-watermark"> |
| 133 |
<rect x="1" y="1" width="478" height="20" fill="red" stroke="black" stroke-width="1"/> |
| 134 |
<text font-family="SVGFreeSansASCII,sans-serif" font-weight="bold" font-size="20" x="240" |
| 135 |
text-anchor="middle" y="18" stroke-width="0.5" stroke="black" fill="white">DRAFT</text> |
| 136 |
</g> |
| 137 |
--> |
| 138 |
</svg> |