Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save quartzjer/76d9306a04ab5594cb932624c775044e to your computer and use it in GitHub Desktop.
Save quartzjer/76d9306a04ab5594cb932624c775044e to your computer and use it in GitHub Desktop.
GPT2 unicorn in SVG
Creating a richly detailed unicorn in SVG involves using paths, shapes, gradients, and filters to give it a distinctive look. Here's a complete SVG depiction of a unicorn:
```svg
<svg
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
viewBox="0 0 500 500"
width="500px"
height="500px"
>
<defs>
<!-- Gradient Definitions -->
<linearGradient id="unicornBodyGradient" x1="0%" y1="0%" x2="100%" y2="100%">
<stop offset="0%" style="stop-color:#f5d6f7;stop-opacity:1" />
<stop offset="100%" style="stop-color:#e8b5f3;stop-opacity:1" />
</linearGradient>
<linearGradient id="maneGradient" x1="0%" y1="0%" x2="100%" y2="100%">
<stop offset="0%" style="stop-color:#ff9a9e;stop-opacity:1" />
<stop offset="50%" style="stop-color:#fad0c4;stop-opacity:1" />
<stop offset="100%" style="stop-color:#fad0c4;stop-opacity:1" />
</linearGradient>
<linearGradient id="tailGradient" x1="0%" y1="0%" x2="100%" y2="100%">
<stop offset="0%" style="stop-color:#ff9a9e;stop-opacity:1" />
<stop offset="50%" style="stop-color:#fad0c4;stop-opacity:1" />
<stop offset="100%" style="stop-color:#fad0c4;stop-opacity:1" />
</linearGradient>
<radialGradient id="hornGradient" cx="50%" cy="50%" r="50%">
<stop offset="0%" style="stop-color:#fff5e1;stop-opacity:1" />
<stop offset="100%" style="stop-color:#f5d6f7;stop-opacity:1" />
</radialGradient>
</defs>
<!-- Unicorn Body -->
<path
d="M250,450 C150,450 100,350 100,300 C100,250 150,200 200,200 C250,200 300,250 350,250 C400,250 450,200 450,150 C450,100 400,50 350,50 C300,50 250,100 200,100 C150,100 100,50 50,100 C0,150 50,250 50,300 C50,350 0,400 50,450 C100,500 150,450 250,450"
fill="url(#unicornBodyGradient)"
/>
<!-- Unicorn Horn -->
<path
d="M250,50 L230,0 L270,0 Z"
fill="url(#hornGradient)"
/>
<!-- Unicorn Mane -->
<path
d="M350,100 C320,80 280,120 250,150 C220,180 180,160 150,140 C120,120 80,100 50,150 C20,200 50,250 100,300 C150,350 200,350 250,350 C300,350 350,300 400,250 C450,200 400,150 350,100"
fill="url(#maneGradient)"
/>
<!-- Unicorn Tail -->
<path
d="M100,400 C50,350 0,300 50,250 C100,200 150,250 200,300 C250,350 200,400 150,450 C100,500 50,450 100,400"
fill="url(#tailGradient)"
/>
<!-- Unicorn Eye -->
<circle cx="325" cy="100" r="10" fill="black" />
<!-- Unicorn Hooves -->
<rect x="180" y="420" width="20" height="30" fill="black" />
<rect x="280" y="420" width="20" height="30" fill="black" />
</svg>
```
You can copy this code and paste it into an HTML file or directly into an SVG editor like Illustrator or Inkscape to view the unicorn in all its glory.
Feel free to adjust the details or add more elements to enhance the unicorn further!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment