add image fill to svg

to show that just plopping image won't fit
Preview SVG with Finder
This commit is contained in:
Paul Zabelin
2018-01-28 19:53:59 -08:00
parent 28d42b4422
commit c51f2b9bff
2 changed files with 6 additions and 2 deletions

View File

@@ -1 +0,0 @@
../PerspectiveTransform/Visual.playground/Resources/sky.jpg

Before

Width:  |  Height:  |  Size: 59 B

After

Width:  |  Height:  |  Size: 30 KiB

BIN
Example/Tests/sky.jpg Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 59 B

After

Width:  |  Height:  |  Size: 30 KiB

View File

@@ -3,11 +3,15 @@
<!-- Generator: Sketch 3.5.2 (25235) - http://www.bohemiancoding.com/sketch -->
<title>Group</title>
<desc>Created with Sketch.</desc>
<defs></defs>
<defs>
<pattern id="sky" patternUnits="userSpaceOnUse" width="320" height="240">
<image xlink:href="sky.jpg" x="0" y="0" width="320" height="240" />
</pattern>
</defs>
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
<g id="Group" sketch:type="MSLayerGroup">
<image id="container" sketch:type="MSBitmapLayer" x="0" y="0" width="555" height="370" xlink:href="container.jpg"></image>
<polygon id="placeholder" stroke="#979797" fill="#7ED321" sketch:type="MSShapeGroup" points="377.282671 41.4352201 459.781253 251.836131 193.321418 330.023027 108.315837 80.1687782 "></polygon>
<polygon id="placeholder" stroke="#979797" fill="url(#sky)" sketch:type="MSShapeGroup" points="377.282671 41.4352201 459.781253 251.836131 193.321418 330.023027 108.315837 80.1687782 "></polygon>
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 947 B

After

Width:  |  Height:  |  Size: 1.1 KiB