Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Tools for creating terrain files?

Selma Serrurier
Registered User
Join date: 21 Nov 2006
Posts: 9
12-20-2006 10:56
This isn't really a build question, but I didn't know where else to ask.

I read the following in the SL Knowledge Base:

"Many commercial and shareware tools exist for creating terrain files. Existing real world terrain data is also available from various sources that can be useful starting points for creating your own height fields."

Does anyone know of any such tools and where I might find them?

Thanks!

Selma
Selma Serrurier
Registered User
Join date: 21 Nov 2006
Posts: 9
12-20-2006 11:02
I should also mention that the sample terrain file I downloaded via the same Knowledge Base item was in Photoshop RAW format.

Selma
Mathieu Basiat
Wavemaster
Join date: 24 Apr 2006
Posts: 57
12-20-2006 11:13
you can use photoshop or Backhoe http://secondlife.com/ddbeta/detail.php?pid=00000012
Selma Serrurier
Registered User
Join date: 21 Nov 2006
Posts: 9
12-20-2006 11:18
Thanks! I will checkout Backhoe. I have tried to figure out how to do this in PSCS2 using RAW and channels...but i just don't get it.

I know I can paint in the channels and stuff. Okay with that. It's understanding what the final image will look like in SL that has me puzzled. So I know how to translate my island vision into something SL can translate that looks like what I imagine.
Lee Ponzu
What Would Steve Do?
Join date: 28 Jun 2006
Posts: 1,770
12-20-2006 11:46
My advice...free...worth every penny.

Easiest is Backhoe, which runs on mac only. It can read an existing terrain and modify it, or it can create a new one from scratch. Play with it for awhile, there is no thorough documentation, so you have to learn my doing.

You can use Photoshop or the Gimp, and the Gimp is probably easier for SL terrain files. To use image tools, you must be familiar with editing channels! rtfm

For whatever reason, SL chose to represent terrain as a 13 channel camera .RAW file (which photoshop, gimp, and other tools can process). Unfortunately, these image tools show the terrain as a top down 256x256 image, where white is high, and black is low, and gray is somewhere in between. Backhoe gives you a 3D view, as you would hope for (see example two posts down). In the Gimp and in Photoshop it is very hard to know what you are doing, especially for a beginner.

There are some reports about a tool called TerraGen, about which I know nothing.

Here's my short, short guide...

Create a 256x256 pixel image. Each pixel will represent 1 sq.m. of terrain, with 0,0 at the Southwest. TIP: You need to work in the channels, not in the layers. Forget layers 8-) for this.

Overview

Height data will be in the red channel, channel 1.
Multiplier data will be in channel 2. (More on this in a moment.)
Water height will be in channel 3.

The rest probably don't matter now, but if this is an existing terrain, don't mess with them. They contain data about parcels, for sale, health, and so on.

The multiplier: This is tricky. For beginners, Set all the values to 127. Do this by setting the rgb values of your foreground color to 0,127,0, and painting the channel 2. 127 represents a height multiplier of 1.0. More on this later.

Water height: if you are adjacent to other Linden water, this layer should contain a value of 20 everywhere. Set foreground color to 0,0,20 and paint channel 3.

Height data: In channel 1. a value of 0 now means 0 meters, and a value of 255 now means 255 m. Paint with shades of RED in channel 1. That is, your colors should be 0,0,0 to 255,0,0 while you paint in the red channel. Imagine you are looking down from space, and black is the sea bottom and white the tops of the mountains. By the way, the Gimp has autogeneration of terrains in the patterns tool. They look pretty cool.

Precision adjustment: So, now you can create terrain that goes from 0 to 255 meters height on a 1 meter grid. however, the minimum ht change from one meter to the next is also 1 meter, which is a lot. Suppose that what you really want is for the min change to be 1/2 meter. This is where the multiplier channel comes in. Go back and paint the multiplier channel with the value 64 instead of 127. This changes the *scale of height changes*. 0 is still 0 meters, but 255 (white, or actually red) now represents 1/2 of 255, or about 127. The step is now 1/2 meter. On the downside, the highest point you can represent is 127 meters.

Suppose you want even finer changes from one square to the next. Then, reduce the multiplier layer to 32 everywhere. The min step is now 1/4 meter, but the highest point possible is about 64 meters.

So, in fact, one of the first decisions you should make is the multiplier layer, especially in Backhoe. Set a multiplier to give you the highest point you want, but no higher. This will give you the best possible precision.

So, now you have this data in channels 1, 2, and 3. What next? The image must have 13 channels, so add ten more, or not if you already had some extras. Put them below 1, 2, and 3. If you are creating, fill them with 0.

Then, save the file as a camera .raw file, interlace.. View it in Backhoe. Buying a $200 used mac might be worthwhile just for this 8-) or, email it to me, and if I am not deluged with requests, I will display it in 3d and send you a picture 8-) [email]lee.ponzu@yahoo.com[/email] (see how nice I am? 8-)

Note on reading raw files: You have to tell the tool how the file is structured, and if you don't know, too bad. So, when you read in a .raw from SL, it is 256x256, 13 channels, interlaced.

Good luck. Post questions here.
Selma Serrurier
Registered User
Join date: 21 Nov 2006
Posts: 9
12-20-2006 12:31
Wow! Thank you so much. This was most helpful!

I'm a Mac user so Backhoe is probably where I will begin. I'm proficient in Photoshop and using channels, so no problem there. I understood MOST of what you explained! :)

I'm just not experienced in using channels in this way and trying to translate to a 3D image. Backhoe I will definitely use.

You're right about opening in PS, btw. It's 256x256 with 13 channels. I opened the sample file from SL...just didn't understand how to read it! You've cleared that up for me immensely.

Thanks again!

Selma
Lee Ponzu
What Would Steve Do?
Join date: 28 Jun 2006
Posts: 1,770
Example
12-20-2006 14:45
When I got home after posting that long screed above, I used the Gimp to create an island, and am attaching a snapshot of my screen looking at the island in Backhoe. Ignore my real name 8-)

lee
Sterling Whitcroft
Registered User
Join date: 2 Jul 2006
Posts: 678
12-21-2006 06:39
...What Lee said.


Here are screen shots of 3 islands I've made with Backhoe. These are early iterations of a project I'm doing in world. After I see what's working in SL, I iterate from Backhoe to SL until I've settled on a terrain that works.
(I find vertical scale in SL is a little unsettling. I make some seemingly VERY high mountains, but houses with 10m ceilings make the mountains all out of proportion :-))
Mathieu Basiat
Wavemaster
Join date: 24 Apr 2006
Posts: 57
12-21-2006 08:59
one more tip

i've found that starting with the outline of the islands i'm making, filled with whatever color makes that just above sea level, and then working my way into to ocean and to the opposite for the mountains....
Emma Nowhere
Registered User
Join date: 15 Aug 2006
Posts: 29
12-21-2006 13:40
I've found that doing the rough shaping in-world and exporting the terrain file, or using Backhoe, works as a starting point, but that using Photoshop's blur effects to smooth the terrain really yields nice results that can't be achieved any other way. I mostly use Backhoe to visualize while doing the edits in Photoshop.