Gimp users and mercator projections

Tips for creating and manipulating planet textures for Celestia.
Topic author
Beeblebrox ate my hamster
Posts: 20
Joined: 04.12.2003
With us: 20 years 11 months

Gimp users and mercator projections

Post #1by Beeblebrox ate my hamster » 23.09.2004, 17:18

I've been using the wonderful image editor Gimp to create some nice surface textures. But around the polar regions I'm getting a nasty distortion , as shown here..........

Image

Can anyone help with getting the proper projection so I don't get the "pinched" effect?

Avatar
selden
Developer
Posts: 10192
Joined: 04.09.2002
With us: 22 years 2 months
Location: NY, USA

Post #2by selden » 23.09.2004, 20:03

Celestia uses "simple cylindrical projection" also known as "Plate Caree" (with various spellings). It does not use Mercator.

There are at least two free packages that can translate images between various map projections.

Iris: http://astrosurf.com/buil/us/iris/iris.htm
by Christian Buil

and

MMPS: Matthew's Map Projection Software
http://www.users.globalnet.co.uk/~arcus/mmps/mmps.html
by Matthew Acrus

Even so, you won't be able to completely eliminate the "pinch" effect. Some distortions will still be visible because of the way 3D surface textures are mapped onto 3D objects. Consumer 3D hardware does not even try to smooth out the coloration of pieces of an image when it squeezes them between the vertices of a model. You can think of it as being similar to someone cutting out triangular and trapezoidal pieces from your picture and pasting them onto the sphere. Some parts get left out and the edges don't quite match. (Of course, this is an oversimplified description.)

Sorry.
Selden

maxim
Posts: 1036
Joined: 13.11.2003
With us: 21 years
Location: N?rnberg, Germany

Post #3by maxim » 23.09.2004, 21:10

Hm, some tool had a polar coordinate to rectangular coordinate conversion filter and produced quite good results. Was it photoshop? I don't really remember.

maxim

Guest

Re: Gimp users and mercator projections

Post #4by Guest » 23.09.2004, 22:47

Beeblebrox ate my hamster wrote:I've been using the wonderful image editor Gimp to create some nice surface textures. But around the polar regions I'm getting a nasty distortion , as shown here..........

Image

Can anyone help with getting the proper projection so I don't get the "pinched" effect?


Thanks Seldon, as always. Now I've downloaded both, what on earth do I do with them 8O

Avatar
selden
Developer
Posts: 10192
Joined: 04.09.2002
With us: 22 years 2 months
Location: NY, USA

Post #5by selden » 24.09.2004, 10:20

Unfortunately, I really have to recommend that you read their documentation carefully.

I've only used Iris a few times, and MMPS is new to me. I'm sure their authors' documentation is better than what I could write. Sorry.

Both programs can read in an image and distort its dimensions so that it is a better shape for projecting onto a sphere and then write out the new version of the image.

If you need a refresher on map projections, you might want to take a look at the Web page http://erg.usgs.gov/isb/pubs/MapProjections/projections.html
Selden

maxim
Posts: 1036
Joined: 13.11.2003
With us: 21 years
Location: N?rnberg, Germany

Post #6by maxim » 24.09.2004, 12:30

Yes, it was photoshop. You can find it even in older versions in the group of distortion filters. The 'polarcoordinate' filter transforms a picture from rectangular to polar coordinates and vice versa. Using Iris is a little bit tricky, and the result is (IMHO) only moderate. It took me quite some time to get behind the functionality. The Manual asumes a lot of pre-knowledge.

Roughly:
Write two transformation definition files, one for the ingoing and one for the outgoing transformation. Finding the right size conversion factor is cruical for a correct result. Split your pic into the three color channels and transform everyone independently. Remerge after splitting. Test the whole procedure with a simple grit first.

How to apply to textures:
Paint your polar region as if you where standing exactly over the axis (Pole in center of pic).
Transform from polar to rectangular coordinates.
Merge the polar part (top part of result) with the undistorted rest of the texture.
Make corrections.
Test result.

maxim

ajtribick
Developer
Posts: 1855
Joined: 11.08.2003
With us: 21 years 3 months

Post #7by ajtribick » 24.09.2004, 14:01

GIMP has a polar-to-rectangular conversion filter but its really fussy about input resolutions.

Rassilon
Posts: 1887
Joined: 29.01.2002
With us: 22 years 9 months
Location: Altair

Post #8by Rassilon » 24.09.2004, 22:53

You can also use flexify from flaming pear...I dont think it will work with the gimp but I know it does with photoshop...

http://www.flamingpear.com
I'm trying to teach the cavemen how to play scrabble, its uphill work. The only word they know is Uhh and they dont know how to spell it!

Avatar
John Van Vliet
Posts: 2944
Joined: 28.08.2002
With us: 22 years 2 months

re

Post #9by John Van Vliet » 26.09.2004, 17:59

one way to solve the pinch distorstion is to use virtual tex
even a level two will remove most of the pinch

hear are some examples
Image
Image
Image

and a link to the fullsize
http://johnscelestiapage.no-ip.com/ScreenShots/spole1.png
http://johnscelestiapage.no-ip.com/ScreenShots/spole2.png
http://johnscelestiapage.no-ip.com/ScreenShots/spole3.png
http://johnscelestiapage.no-ip.com/ScreenShots/spole4.png

Topic author
Beeblebrox ate my hamster
Posts: 20
Joined: 04.12.2003
With us: 20 years 11 months

Post #10by Beeblebrox ate my hamster » 27.09.2004, 23:27

cheers guys, I'll put my thinking cap on!


Return to “Textures”