Terrain Color

From CryWiki

Jump to: navigation, search
About
Author Eshme
Skill Level Beginner
Compatibility Not specified.
Requirements Sandbox2
Date Added 21/12/07
Last Modified 06/11/08

Contents

The Terrain Texture

The Terrain Texture is one or more combined textures of any given tile size, which contains the color information for your Map. The Terrain Texture should not be confused with all kinds of textures you can apply to your terrain.

Note
Needs fixing

in Sandbox however its the Terrain Colorization. The one u see from the distance. This texture is the combination of all Terrain texture „Tiles“. This texture is only stored within the Sandbox and not visible in game and can get very large.

Terrain Texture (scaled down  to 10%) and the Heightmap
Terrain Texture (scaled down to 10%) and the Heightmap

The picture above shows a fraction of the Terrain Texture of the Island Map and looks like a satellite photo. In fact its possible for you to create them from satellite pictures. To give you some figures of its scale, the full Terrain Texture is 16k x 16k Pixels; but each pixel is only 0,5m² big if you zoom into this Map. (Not in all areas though, i will explain that further down) To view its size, choose (Terrain/ExportImport Terrain Texture) and look at the RGB figure.

The Terrain Tile

A very tiny Tiling setup, for a very tiny testing map
A very tiny Tiling setup, for a very tiny testing map

A Terrain Tile is a fraction of the terrain texture. A full Terrain texture can consist of, for example, 2x2 or 8x8 tiles; or even just one, where each can have a different resolution. Sandbox automatically sets up good tiling to start from.

Tiling is probably meant to give the ability to improve the quality in one Area, while decreasing it in another to increase performance. The image on the right shows 4 Tiles of 64 squarepixels making a 128x128 Terrain Texture. Don't confuse this with the RGB size, if it will be higher than you expect. Increasing just one tile to 128 causes the whole size to be 256x256 rather than 192x192. You can view this Layout by going to (Terrain/ExportImport Terrain Texture).

Different tile resolutions
Different tile resolutions

Basically, the higher the resolution of a Tile, the more detailed your Terrain texture, and the smoother and finer your Layer transitions. 1 Pixel of a Tile can also be assigned to one Texture layer (by Painting Terrain) and is usually somewhere around 1m² big on your terrain depending on the Resolution.

Note
A layer consists of 3 components: Detail, Distance Texture and Color. Which one you will see depends on how far away the camera is.
Examples of different tile resolution from high above
Examples of different tile resolution from high above

The top image has 16 times more detail because its tile size is 1024pixels² rather than 64pixels². The number below displayes the pixels per meter. To view those numbers, switch to the LayerPainter, and click on "Change" under Tiling Resolution at the bottom. Then hover your mouse over the terrain to view those Tiles. Click to change Resolution.

Rule of thumb is, playing areas should be very detailed, and less important areas in the distance are better left low detail for performance reasons. A good value for very detailed is 2 pixels per meter, and for low detail its 0.13Pixels per meter.

If you reached a Tile with 2048² pixels (the maximum) and still want more detail, you can add Tiles by choosing (Terrain/Texture ... File/RefineTerrainTextureTiles). However, be careful because that operation can't be undone. Also dont go over 8x8 Tiles because that seems to be buggy.

Surface Texture

Generate Surface Texture is the usual step you need to do, to transfer the Terrain Texture into the game readable format. Choosing (File/GenerateSurfaceTexture) gets you to choose yet another Resolution.

Something basic about the Surface Texture first. In opposition to the Terrain Texture, this one is final and reflects what you will see in game. This will also eat your performance for lunch. Depending on how you render it, it can be of lower quality than what you painted. Im guessing it is some optimization for the engine, some quality drops are to be expected. You can however repeat generating it over and over again, while your Terrain Texture will stay untouched.

With the Dialog you can see at the right, you basically choose Pixels per meter again. Im not sure of the technique behind it. Im mostly leaving it at the higher the better, i suppose. As far as Tile Resolution goes, with a good setting of 2pixels per meter, i would try to achieve the same with the Surface Texture.

The Island map, which has 8km² seems to be generated with 16384x16384, which seems to retain the quality of the Terrain texture the most as its also 16384x16384 Pixels. Youll probably notice that this is the maximum the Surface Texture can do, thus any higher quality Terrain Texture or bigger Mapsize wont give you a higher quality of Surface. Your 32k Terrain Texture will end up only 16k in essence. Or a bigger map than 8k will be limited to 16k Surface Texture just as the Island map has. On the other end, generating a bigger Surface texture than your Terrain Texture doesnt make much sense. Thus my advice is to render it in the same size as the Terrain Texture (Quality reason) but not bigger than 2Pixels per meter (Performance reason).

Note
Sometimes in small maps a bigger Surface Texture results in lower actual quality

For scetching you can do a 512x512 Render anytime. Just when you want some high quality you can choose a high resolution. The Tickbox HighQuality and Calculate Terrain Sky Accessibility dont affect the resolution. Remember, your high detail Terrain Texture wont get lost. It'll come back once you begin to paint again per individual Terrain sector.

Statistics

The Level of Detail of a map you choose from the start will define the rest of it. Grow a huge map, but realize you loose quality in the later stages. Save your time and resources by good management.

Terrain layers still look amazing at lowered resolution and do smooth transitions. And the detail texture, and anything else you see up close, will always appear the same to you. Here is some data of the Island Demo map.

Terrain Texture16384x16384 Pixels (2 pix/meter)
Texture Tiling(8x8 Tiles)
Tiling Sizes2048x2048Pixels (2Pix/m) for playing fields,

Distance is 128x128 (0.13Pix/m) to 256x256 (0.25Pix/m)

Surface Texture16384x16384 Pixels (2 pix/meter) )
Personal tools