File:RGB cube example.svg

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search

Original file(SVG file, nominally 120 × 140 pixels, file size: 2 KB)

Captions

Captions

Add a one-line explanation of what this file represents

Summary[edit]

Description An example for a RGB color model cube; showing librsvg bugs.
Date
Source Own work based on: RGB krychle.svg
Author Sarang
SVG development
InfoField
 
The SVG code is valid.
 
This vector image was created with a text editor.
 
Please do not replace the simplified code of this file with a version created with Inkscape or any other vector graphics editor
Source code
InfoField

SVG code

<?xml version="1.0"?>
<svg xmlns="http://www.w3.org/2000/svg" width="120" height="140" stroke-linecap="round">
<linearGradient id="BR"><stop stop-color="#F0F" offset="0"/><stop stop-color="#00F" offset="1"/></linearGradient>
<linearGradient id="BV"><stop stop-color="#00F" offset="0"/><stop stop-color="#000" offset="1"/></linearGradient>
<linearGradient id="BG"><stop stop-color="#00F" offset="0"/><stop stop-color="#0FF" offset="1"/></linearGradient>
<linearGradient id="RB"><stop stop-color="#F00" offset="0"/><stop stop-color="#F0F" offset="1"/></linearGradient>
<linearGradient id="RV"><stop stop-color="#F00" offset="0"/><stop stop-color="#000" offset="1"/></linearGradient>
<linearGradient id="RY"><stop stop-color="#F00" offset="0"/><stop stop-color="#FF0" offset="1"/></linearGradient>
<linearGradient id="GY"><stop stop-color="#FF0" offset="0"/><stop stop-color="#0F0" offset="1"/></linearGradient>
<linearGradient id="GV"><stop stop-color="#000" offset="0"/><stop stop-color="#0F0" offset="1"/></linearGradient>
<linearGradient id="GB"><stop stop-color="#0F0" offset="0"/><stop stop-color="#0FF" offset="1"/></linearGradient>
<linearGradient id="WB"><stop stop-color="#FFF" offset="0"/><stop stop-color="#0FF" offset="1"/></linearGradient>
<linearGradient id="WY"><stop stop-color="#FFF" offset="0"/><stop stop-color="#FF0" offset="1"/></linearGradient>
<linearGradient id="WR"><stop stop-color="#F0F" offset="0"/><stop stop-color="#FFF" offset="1"/></linearGradient>

<path stroke="url(#WB)" d="m60,100 40-40"/>
<path stroke="url(#WR)" d="m20,60 40,40"/>
<path stroke="url(#WY)" d="m60,100 17,17" transform="rotate(45,60,100)"/>
<path stroke="url(#BR)" d="m20,60 40-40"/>
<path stroke="url(#BG)" d="m60,20 40,40"/>
<path stroke="url(#BV)" d="m60,20 17,17" transform="rotate(45,60,20)"/>
<path stroke="url(#RV)" d="m20,85 40-40"/>
<path stroke="url(#RY)" d="m20,85 40,40"/>
<path stroke="url(#RB)" d="m20,85 17,17" transform="rotate(225,20,85)"/>
<path stroke="url(#GY)" d="m100,85-40,40"/>
<path stroke="url(#GV)" d="m60,45 40,40"/>
<path stroke="url(#GB)" d="m100,85 17,17" transform="rotate(225,100,85)"/>
</svg>
Gradienting for horizontal or vertical pathes won't be drawn, as a workaround tranformation is used;

offline it looks fine, but librsvg has problems with gradienting of all lines not going ++ (down and right).

Licensing[edit]

Public domain This image of simple geometry is ineligible for copyright and therefore in the public domain, because it consists entirely of information that is common property and contains no original authorship.
Heptagon
Heptagon

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current08:16, 8 June 2021Thumbnail for version as of 08:16, 8 June 2021120 × 140 (2 KB)Sarang (talk | contribs){{Information |description=An example for a RGB color model cube |date=2021-06 |source={{Based|RGB,2.svg}} |author={{U|Sarang}} |other fields={{Igen|T|+|s=ex|S-|5=p|c1= <?xml version="1.0"?> <svg xmlns="http://www.w3.org/2000/svg" width="120" height="140" stroke-linecap="round"> <linearGradient id="BR"><stop stop-color="#F0F" offset="0"/><stop stop-color="#00F" offset="1"/></linearGradient> <linearGradient id="BV"><stop stop-color="#00F" offset="0"/><stop stop-color="#000" offset="1"/></linea...

The following page uses this file:

Metadata