Location: Texas, U.S.A.
Member Is Offline
Mood: Not enough hours in a day
posted on 9-1-11 at 13:58
Blender maps and Detail maps
There has been some confusion since about JO about blender maps and detail maps. Hopefully this thread will end that confusion
once and for all.
What is a Blender/ Blend map?
A blender map is an RGBA .TGA file that is used in conjunction with the detail maps in order to apply textures to specific areas
in the terrains.
What is a Detail map?
A detail map is an RGBA or RGB .TGA file that has a texture(s) that is applied to the terrain in one of two ways:
Multiplied to color map - one or more RGBA channels of the detail map is multiplied to the terrain's color map. Overlaps the color map - the RGB detail map is directly applied to the terrain and overrides any tinting done by the color map. The
Alpha channel is ignored
Type 2 detail maps are used for close-up terrain when the "Terrain" option (in game options) is set to High.
Type 1 detail maps are used for terrain that is further away from the player. It is also used for close-up terrain when the "Terrain" option (in
game options) is set to Normal or Low.
How does the game use Blender and Detail Maps?
When the game loads up the terrain, all 4 detail maps are automatically applied to the terrain, and then uses the Blender map to
controls the transparency of those textures at specific spots.
Single-Channel Blender Map Example
This blender map is an example of a single-channel blender map. Areas that are pure Red have the detail map fully visible on the terrain, while areas
that are pure black have the detail map transparent. Shades of red in-between have varying levels of opacity.
Dual-Channel Blender Map Example
This blender map is an example of a dual-channel blender map. The same mechanics explained before is still used here, but each color represents a
different detail map: such as red being dirt areas while green being grassy areas.
Detail Map Hierarchy
The maps are layered top-down in this order:
Layers at the top (smaller number) are rendered over the lower layers. So if you have an Area that has a lot of Red on it, then the Green, Blue, and
Alpha layers will be rendered, but not seen by the player.
Differences between Type 1 Detail maps and Type 2 Detail Maps
Type 1 Detail maps have their channels directly correspond with the blender map channels. The Red channel will be applied to red
blend areas, the Green channel with the green blend areas, etc.
Type 2 Detail maps, since they're not split up into channels, must be defined in the .TRN for each blend channel:
detailmap_c1 - Red blend channel detailmap_c2 - Green blend channel detailmap_c3 - Blue blend channel detailmap_c4 - Alpha blend channel (?)
Note that detailmap_c4 has not been seen in any .trn generated by Nova, and is currently only a speculation
Detail maps and Terrain Level of Detail
The terrain is a polygonal mesh object just like any other 3D object, and thus uses an LOD scheme for performance optimization.
Type 2 Detail maps are only rendered on areas of the terrain that are at their highest LOD, while Type 1 Detail maps are cycled between these three
entries listed in the .TRN:
Higher LOD's (and detail maps) are rendered/seen at closer areas while lower LOD's are rendered/seen at further areas.
Detail Maps and Terrain Tiles
Some terrain tiles used in the MED have been able to force the Alpha detail channel to show. In most stock detail map .TGA's the
Alpha channel has been a rock or smooth asphalt texture.
Time is not my enemy, although we do have many disagreements...