Docs / Reference / Content formats
Textures
Textures live in a texture\ folder beside the model, or in the global Texture folder. The
supported file formats and the texture search order are in Modding overview; PBR maps
are in PBR materials.
Texture sidecar (<texture>.<ext>.cfg)#
[surface]
2
[moisture]
[puddles]| Keyword | What it does |
|---|---|
[terrainmapping] |
Map the texture in world coordinates |
[moisture] |
The surface darkens when it rains |
[wet] |
The surface holds a rain film without [moisture], even with no [path] or when painted on the terrain (openOMSI); a painted layer's brush mask weights that film, while [moisture] paint keeps its old one; soil, grass and gravel still soak it up |
[puddles] |
The surface collects puddles |
[surface] n |
Material: 0 asphalt, 1 concrete, 2 cobblestone, 3 dirt, 4 grass, 5 gravel, 6 snow, 7 deep snow. Scripts read it as Axle_SurfaceID_ |
Seasons#
global.cfg [addseason] kind start_day end_day (day of year): 1 spring, 2 autumn, 3 winter,
4 winter with snow, 5 dry summer. Season textures live in texture\Spring, Fall, Winter,
WinterSnow and SummerDry subfolders, with the same file names, and take precedence.
- A texture without a winter picture takes its autumn one.
- A weather with
[snow]takes theWinterSnowpictures whatever the season. With[snowOnRoad]as well,WinterSnowfallpictures come first. - A texture with no snow picture takes its winter one, else its autumn one.
Textures OMSI reads that other loaders refuse#
- A palette bitmap counting more colours than its bit depth holds (4-bit with
biClrUsed17: the A21's and Urbino'sLCD-Innenanzeige.bmp). - DDS files whose fourcc is a D3DFORMAT number (36, 113, 116: 16-bit and float RGBA).
On the graphics card#
openOMSI keeps textures compressed on the GPU where it can:
- DDS files with DXT1-DXT5 (and DX10 BC1-BC3) data go up as they are, with the file's own mip chain. A file without one gets levels made the way D3DX makes them. A DXT1 block with c0 ≤ c1 using index 3 is transparent black; such a file counts as having alpha.
- Uncompressed files (BMP, TGA, JPG, PNG, raw DDS) are compressed on loading: to BC1 without alpha, else BC3. This happens only when the result is close enough (colour PSNR ≥ 33 dB, alpha ≥ 30 dB); noisy cobbles and asphalt stay RGBA.
- Sides that are not multiples of four are resampled to the nearest multiple. Pictures with a side under 128 texels, or under 64² texels in all, stay RGBA.
- A tile's own pictures (light map, road cut, paint masks) keep one level. A mask of only 0 and 255 becomes 1-bit BC1, a soft one BC3.
- Text and script textures and render targets stay RGBA. Scenery
[texttexture]pictures are shared when they show the same thing. - Compressed textures are cached in
~/.openomsi/cache/textures.
options.cfg's [texture] (two values) and [texmemlimit] (401.0 MB in the stock file) are
not imported. openOMSI uses its own texture_compression= (on by default) and video_memory=
(MB for everything on the card; nine tenths of a discrete card's memory when unset). See
Graphics. For tests, OMSI_NO_BC and OMSI_NO_TEXCOMPRESS turn
compression off (see Environment variables).
Something wrong or missing? Fix it on GitHub or open an issue.