Scenery:Texmapper.cfg File
This is the main configuration file for the texture map generator. It is very similar to the terrain config file and some of the parameters are the same.
Example
#---------------- # Common section #---------------- tile_size_n = 3648 tile_size_e = 3648 start_n = 45.0974 start_e = 7.26291 ref_lat = 50 num_tiles_n = 32 num_tiles_e = 32 #------------------------ # Texture mapper section #------------------------ # Texture resolution (tile_size/tex_size = Approx 3.5m/pixel) tex_size = 1024 # Image format (DXT1/gzip compressed) out_pixel_fmt = DXT1 out_file_ext = .dds.gz # Work cache sizes (in Mb) shd_cache_sz = 200 img_cache_sz = 200 #------- # Flags #------- # Generate mipmaps yes/no (recommended) mipmaps = true # Generate shadows (Only if you have elevation data) shadows = false # Always overwrite existing files in the output directory overwrite = true #--------------- # Input section #--------------- #Input images image_dir { path = /data/geodata/images/aerial/ recursive = true ext = .tif pri = 2 coosys = +proj=utm +zone=30 +datum=WGS84 } image_dir { path = /data/geodata/images/lores/ recursive = true ext = .tif pri = 1 } # Elevation data for shading dem_dir { path = /data/geodata/srtm ext = .tif pri = 1 } dem_dir { path = /data/geodata/srtm30 ext = .DEM.gz pri = 0 }
Common section
This is where we define the area of the world covered by this scenery block. You need to either specify the number of tiles, a tile size and a start point, or alternatively the start/end points of the area. In this example we have chosen tile size and start point.
The tile size is given in meters in north- and east direction.
tile_size_n = 3648 tile_size_e = 3648
Now, since the tiles are parallell with the longitude lines, the width varies over the tile. This means that the tile_size_e parameter is only correct at the given reference latiude, ref_lat.
ref_lat = 50
In this case, the tile width is correct at 50 degrees latitude. Further north, the tile will be narrower, further south the tile will be wider.
The tile start location (south east corner) is given by:
start_n = 45.0974 start_e = 7.26291
And the number of tiles:
num_tiles_n = 32 num_tiles_e = 32
The number of tiles should always be the same in north- and east-direction, and it should always be a power of 2, i.e 2, 4, 8, 16, 32, 64, etc.
For performance, we recommend keeping the tile size around 4km.