The industrial revolution in extracting images

Kyriakos

Creator
Joined
Oct 15, 2003
Messages
78,218
Location
The Dream
I was not pleased with my previous method taking 2-3 min of boring work to do this, so i found a new one.

The following is a tutorial using Gimp (greek version) but i guess other programs also have this option or something similar.

Step 1.

Load up your image, complete with its background as it was generated by the 3d program, or as you found it on the web.

TI0LV.png


Step 2.

Same as in the old method, use the lasso tool to extract a reasonably sized area (most importantly it should have at least 90-95% of all the colors, do that by eye you don't have to calculate anything otherwise). Then use the color selection tool to extract the main tones of the background (i usually extract just 3, but that is workable in the specific bryce background i always have, you may need more)

rp5Yj.png


Step 3.

Same again as in the old method, paste your part of the model/image, along with the extracted few colours of the background into Gimp, and save it as a 256 color image.

EETHe.png


Step 4.

Paste your old (complete and unaltered) image onto the new file that has 256 colors. You notice that the background now has less complication, because it conformed to the limited palette.

sfljU.png


Step 5.

Now the good part begins :) Select the tool of Gimp used for selecting a continuous area of color/texture.

5GTNJ.png


Step 6.

Click on the background, and watch it nicely being collected alltogether by the tool. Now hit ctrl+x to delete it. You now have the image with very few dots of the remaining background :)

t4cig.png


Step 7.

Copy/paste the image onto your regular image editing program (i use MS paint). You can now erase the last iotas of background color. All is done! :)

zs6Aa.png


Thank you for reading. Original model not included. Visit us at facebook as well ;)
 
I've been using a similar method for your city sets already :D Good tutorial; thorough!
 
I don't understand why you don't just render the buildings over a white background and decrease the number of colors from there.

Edit:

If it's because you want the building shadows to be greenish, you probably can change the refraction settings of the ground, in order to have a green hue on it only where there are shadows.

2nd edit:

If it's due to lack of (real) transparency with PCX and the time it takes to clean up all the dots around the source if the source background isn't close to whatever terrains the PCX would be on in-game..
Perhaps you could render the model over a uniform green hue, unique to the ground, and replace it when your favorite invisible indexed color (1) before saving the final pcx. All the transition pixels from the original green ground colors to the model itself would be left untouched and shouldn't be really perceived in-game.

(1) Either by modifying the color in the indexed palette, then moving in to the last place, or by selecting the color in the RGB image with the GIMP "Select by color tool" with a threshold of 0 and replacing it (big brush) with the chosen color.

Anyway, all this should even faster than your method, taking less than one minute and less brain-power.
 
Back
Top Bottom