Planettool 0.4.2 released
Moderators: winston, another_commander
- Cmd. Cheyd
- ---- E L I T E ----
- Posts: 934
- Joined: Tue Dec 16, 2008 2:52 pm
- Location: Deep Horizon Industries Manufacturing & Research Site somewhere in G8...
Cmd. Cheyd quietly waits and prays for the Windows version... Or a Photoshop script... Or Plug-in... Or...
Find my OXP's at:
Deep Horizon Industries - Your Planet Our Design
Deep Horizon Industries - Your Planet Our Design
- JensAyton
- Grand Admiral Emeritus
- Posts: 6657
- Joined: Sat Apr 02, 2005 2:43 pm
- Location: Sweden
- Contact:
What I said above is absolutely true: I wrote the graphical version because it was easier than writing a comprehensible guide to installing and using command a line tool. It took a few hours of coding on Sunday evening, and another hour or so of polishing spread out over several days. The Windows and Linux programmers in the audience are welcome to take this as a challenge. I’ve already made it easier for them by refactoring the core code (which is vanilla C) to be more embeddable. ;-)Cmd. Cheyd wrote:Cmd. Cheyd quietly waits and prays for the Windows version... Or a Photoshop script... Or Plug-in... Or...
In the mean time, here’s some slightly better documentation.
E-mail: [email protected]
-
- Quite Grand Sub-Admiral
- Posts: 6683
- Joined: Wed Feb 28, 2007 7:54 am
Planettool 0.4.2 for Windows (command-line interface only) is now available from GURPO.
- Getafix
- Quite Grand Sub-Admiral
- Posts: 979
- Joined: Tue Apr 01, 2008 12:55 pm
- Location: A small ice asteroid, orbiting Oresrati in Galaxy 8 (a.k.a. northwest Armorica).
- Contact:
Planettool 0.4.2 released
Planettool 0.4.2 for Linux x86 and x86_64 (command-line interface only) is now available from GURPO.
"Any sufficiently advanced information is indistinguishable from noise." [Newman, Lachmann, Moore]
- Griff
- Oolite 2 Art Director
- Posts: 2483
- Joined: Fri Jul 14, 2006 12:29 pm
- Location: Probably hugging his Air Fryer
Re: Planettool 0.4.2 released
does the texture size power of two rule apply to cube maps? i've used this program to convert some 1024x512 'latlong' maps and the resulting cube map comes out as 512 x 3072. Do i need to resize this now to 512x2048 or will Oolite/openGl deal with this map as 6 512x512 tiles?
Wiki homepage for my OXP: http://wiki.alioth.net/index.php/Griff_Industries
- JensAyton
- Grand Admiral Emeritus
- Posts: 6657
- Joined: Sat Apr 02, 2005 2:43 pm
- Location: Sweden
- Contact:
Re: Planettool 0.4.2 released
Each face of the cube must be a power-of-two square, so the height will always be 1.5 times a power of two.Griff wrote:does the texture size power of two rule apply to cube maps? i've used this program to convert some 1024x512 'latlong' maps and the resulting cube map comes out as 512 x 3072. Do i need to resize this now to 512x2048 or will Oolite/openGl deal with this map as 6 512x512 tiles?
E-mail: [email protected]
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: Planettool 0.4.2 released
<chortles>London sits in a steamy jungle straddling the equator, with a climate generally resembling Manila's. The food is still bland, the Thames is full of piranha, and it's the only place on Earth where tigers apologize as they attack you.
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!
- submersible
- Commodore
- Posts: 264
- Joined: Thu Nov 10, 2011 7:49 am
Re: Planettool 0.4.2 released
I've been meaning to look at the source for planettool to see if I can devise a normal map generator for cube maps. I noticed that the Oolite planet texture generator builds a normal map by sampling a noise map (lat-long) . For me - building a useful normal map for use on a spherical object from latlong or cube maps has been devilishly hard with current tools. The GIMP normal map extension is OK - but it is planar centric.
Povray Planets - Planet textures for your galaxy
- JensAyton
- Grand Admiral Emeritus
- Posts: 6657
- Joined: Sat Apr 02, 2005 2:43 pm
- Location: Sweden
- Contact:
Re: Planettool 0.4.2 released
The architecture isn’t very well suited to that. You could quite easily make a filter (a “source”, in planettool terms, that reads from another source, like MatrixTransformer does), but the renderers (“sinks”) perform Gaussian weighted filtering that doesn’t necessarily make sense for normals.submersible wrote:I've been meaning to look at the source for planettool to see if I can devise a normal map generator for cube maps. I noticed that the Oolite planet texture generator builds a normal map by sampling a noise map (lat-long) . For me - building a useful normal map for use on a spherical object from latlong or cube maps has been devilishly hard with current tools. The GIMP normal map extension is OK - but it is planar centric.
That said, here’s what you need to know to try it:
- All rendering is done in linear floating-point RGB, and written as (slightly fake) sRGB. The gamma remapping isn’t desirable for normal maps, so you’d want to change the driver (main.c) such that normal-mapping modes produce linear output. This involves passing
kFPMGammaLinear
instead ofkFPMGammaSRGB
toFPMWritePNG
. - The basic operation of the tool works by connecting a pixel “source” to a pixel “sink”. Two of the existing sources, MatrixTransformer and CosineBlurFilter, wrap other sources and apply effects. This should be the template for your normal mapper.
- To read a gradient, you’ll want to sample from some offset in each direction, which will look something like this:
Code: Select all
FPMColor HeightMapToNormalMapFilter(Coordinates where, RenderFlags flags, void *context)
{
HeightMapToNormalMapFilterContext *cx = context;
// Read input coordinates, possibly converting from vector to latitude/longitude.
float lat, lon;
CoordsGetLatLongRad(where, &lat, &lon);
// Offset coordinates northward by some angle, presumably specified at command
// line and defaulted to something sensible based on size.
Coordinates northOffsetCoords = MakeCoordsLatLongRad(lat + cx->offset, lon);
FPColor northSample = cx->source(northOffsetCoords, flags, cx->sourceContext);
// Three more samples here...
// ...Then calculate normal from gradients.
}
E-mail: [email protected]
- Cmd. Cheyd
- ---- E L I T E ----
- Posts: 934
- Joined: Tue Dec 16, 2008 2:52 pm
- Location: Deep Horizon Industries Manufacturing & Research Site somewhere in G8...
Re: Planettool 0.4.2 released
Any chance of getting the bug I reported last year (or was it the year before that?) fixed?
Find my OXP's at:
Deep Horizon Industries - Your Planet Our Design
Deep Horizon Industries - Your Planet Our Design
- JensAyton
- Grand Admiral Emeritus
- Posts: 6657
- Joined: Sat Apr 02, 2005 2:43 pm
- Location: Sweden
- Contact:
Re: Planettool 0.4.2 released
Which one would that be? There aren’t any tickets for planettool in the bug tracker.Cmd. Cheyd wrote:Any chance of getting the bug I reported last year (or was it the year before that?) fixed?
E-mail: [email protected]
- Cmd. Cheyd
- ---- E L I T E ----
- Posts: 934
- Joined: Tue Dec 16, 2008 2:52 pm
- Location: Deep Horizon Industries Manufacturing & Research Site somewhere in G8...
Re: Planettool 0.4.2 released
https://bb.oolite.space/viewtopic.php?f=3&t=8361
And as the post said, I did submit it via Berlios...
And as the post said, I did submit it via Berlios...
Find my OXP's at:
Deep Horizon Industries - Your Planet Our Design
Deep Horizon Industries - Your Planet Our Design
- JensAyton
- Grand Admiral Emeritus
- Posts: 6657
- Joined: Sat Apr 02, 2005 2:43 pm
- Location: Sweden
- Contact:
Re: Planettool 0.4.2 released
Ah, I didn’t find it in the tracker because it was fixed over a year ago. :-) We should probably post a new release soon, but I have some other things to fix first.
E-mail: [email protected]
- submersible
- Commodore
- Posts: 264
- Joined: Thu Nov 10, 2011 7:49 am
Re: Planettool 0.4.2 released
Just while I think of it - is there any hope for fixing this known issue...
I'm noticing this going from a cube to a cubexJensAyton wrote:While it can read from cube maps, it fails at the edges of faces and produces artefacts. This does not affect writing cube maps.
Povray Planets - Planet textures for your galaxy