Lade...
 

Beiträge zu sv_GraphicsCutting (gegenwärtige Version)

Prozess



Optionen




Version
Version Datum Nutzer
Frank
Frank
Frank
Frank
Frank
Frank
Seite anzeigen

Statistiken

Autor Wörter Leerraum Zeichen Druckbare Zeichen
Benutzt Gelöscht Benutzt Gelöscht Benutzt Gelöscht Benutzt Gelöscht
FrankP 749 (100.0%) 0 (0.0%) 566 (100.0%) 0 (0.0%) 11400 (100.0%) 0 (0.0%) 7601 (100.0%) 0 (0.0%)
Gesamt 749 (100.0%) 0 (100.0%) 566 (100.0%) 0 (100.0%) 11400 (100.0%) 0 (100.0%) 7601 (100.0%) 0 (100 %)

Seitenänderungen

Inhaltsverzeichnis

  • <a href='#Why_do_graphics_need_to_be_cut_' class='link'> Why do graphics need to be cut?</a>
  • <a href='#Position_of_the_image_and_its_tiles' class='link'> Position of the image and its tiles</a>
  • <a href='#How_to_do_it' class='link'> How to do it</a>


Why do graphics need to be&nbsp;cut?<a href="#Why_do_graphics_need_to_be_cut_" class="heading-link"><span class="icon icon-link link" ><img src="img/icons/link.png" alt="link"></span></a>




The graphics system in Simutrans is based on tiles, in order for an image to be displayed correctly in-game, the source image needs to be divided into tiles depending on their intended position. Each tile is a square area with the following dimensions:

Pakset size Width in pixel Height in pixel
32  32 32
64  64  64
96  96  96
128  128  128
192  192  192



A building consists of ground-level tiles (blue) and up to 3 height-level tiles for each ground-level tile (red - 1 height).

The parts of the ground-level tile shown in green in the image to the right will not be visible in-game.

A building which only consists of a single ground-level tile does not need to be cut. Only when a building is made up from several ground-level tile is it necessary to cut the graphics.
<a href="alt=" class="internal" title="1x1"> <img src="show_image.php?id=307" loading="lazy" height="128" width="64" alt="1x1" class="regImage pluginImg img-fluid" data-src="show_image.php?id=307" title="1x1" /> </a>
1x1




<a href="sv_GraphicsCutting#tiki_top">{TRAFD(fields=>22,filtervalue=>1)}{TRAFD}</a>

Position of the image and its&nbsp;tiles<a href="#Position_of_the_image_and_its_tiles" class="heading-link"><span class="icon icon-link link" ><img src="img/icons/link.png" alt="link"></span></a>




The information in the graphics file correspond to the values of B C D of the
<a href="en_BackImage" title="BackImage" class="wiki wiki_page">BackImage</a> parameter. Their relative ordering from top to bottom is given vertically.

<a href="alt=" class="internal" title="1x2"> <img src="show_image.php?id=361" loading="lazy" height="176" width="96" alt="1x2" class="regImage pluginImg img-fluid" data-src="show_image.php?id=361" title="1x2" /> </a>
1x2

<a href="alt=" class="internal" title="2x1"> <img src="show_image.php?id=362" loading="lazy" height="176" width="96" alt="2x1" class="regImage pluginImg img-fluid" data-src="show_image.php?id=362" title="2x1" /> </a>
2x1

<a href="alt=" class="internal" title="2x2"> <img src="show_image.php?id=363" loading="lazy" height="192" width="128" alt="2x2" class="regImage pluginImg img-fluid" data-src="show_image.php?id=363" title="2x2" /> </a>
2x2

<a href="alt=" class="internal" title="2x3"> <img src="show_image.php?id=364" loading="lazy" height="192" width="160" alt="2x3" class="regImage pluginImg img-fluid" data-src="show_image.php?id=364" title="2x3" /> </a>
2x3


<a href="alt=" class="internal" title="3x2"> <img src="show_image.php?id=365" loading="lazy" height="192" width="160" alt="3x2" class="regImage pluginImg img-fluid" data-src="show_image.php?id=365" title="3x2" /> </a>
3x2

<a href="alt=" class="internal" title="3x3"> <img src="show_image.php?id=366" loading="lazy" height="192" width="192" alt="3x3" class="regImage pluginImg img-fluid" data-src="show_image.php?id=366" title="3x3" /> </a>
3x3


other sizes can be found
<a class="wiki" href="tiki-browse_gallery.php?galleryId=17" rel="">here</a>


<a href="sv_GraphicsCutting#tiki_top">{TRAFD(fields=>22,filtervalue=>1)}{TRAFD}</a>

How to do&nbsp;it<a href="#How_to_do_it" class="heading-link"><span class="icon icon-link link" ><img src="img/icons/link.png" alt="link"></span></a>



To help cut up an image according to these specifications, there is a Windows-program called
<a href="de_tilecutter" title="de_tilecutter" class="wiki wiki_page">TileCutter (German description only</a>); under Linux TileCutter works well with Wine.

It will take 2x the original graphics, a target file and the appropriate interface mask.

<a href="alt=" class="internal" title="Output file"> <img src="show_image.php?id=314" loading="lazy" height="192" width="349" alt="Output file" class="regImage pluginImg img-fluid" data-src="show_image.php?id=314" title="Output file" /> </a>
Output file

<a href="alt=" class="internal" title="Interface mask"> <img src="show_image.php?id=372" loading="lazy" height="192" width="128" alt="Interface mask" class="regImage pluginImg img-fluid" data-src="show_image.php?id=372" title="Interface mask" /> </a>
Interface mask


<a href="alt=" class="internal" title="Target file"> <img src="show_image.php?id=371" loading="lazy" height="192" width="448" alt="Target file" class="regImage pluginImg img-fluid" data-src="show_image.php?id=371" title="Target file" /> </a>
Target file


The next step is to mask the intersection of the two original images; with red and blue respectively being used as transparent.
<a href="alt=" class="internal" title="cut output file"> <img src="show_image.php?id=312" loading="lazy" height="192" width="349" alt="cut output file" class="regImage pluginImg img-fluid" data-src="show_image.php?id=312" title="cut output file" /> </a>
cut output file


Then the partial images are copied into the target file.
<a href="alt=" class="internal" title="raw target file"> <img src="show_image.php?id=310" loading="lazy" height="192" width="448" alt="raw target file" class="regImage pluginImg img-fluid" data-src="show_image.php?id=310" title="raw target file" /> </a>
raw target file


Finally, the red and blue of the mask as well as the tile backgrounds of the target file are filled with transparent color. The original image is also copied into the target file.

It is a very good idea to add a copyright notice to the target file. Then everyone knows by whom the picture is, even if the file name changes.
<a href="alt=" class="internal" title="Target file ready"> <img src="show_image.php?id=308" loading="lazy" height="192" width="448" alt="Target file ready" class="regImage pluginImg img-fluid" data-src="show_image.php?id=308" title="Target file ready" /> </a>
Target file ready


<a href="sv_GraphicsCutting#tiki_top">{TRAFD(fields=>22,filtervalue=>1)}{TRAFD}</a>



Online Benutzer

96 Benutzer (alle) online

Neueste Forenbeiträge