Texture Mapping

From Catacomb Wiki
(Redirected from Texture mapping)
Jump to navigationJump to search
Texture maps for Catacomb 3D

A texture map is an image applied (mapped) to the surface of a shape or polygon. Catacomb 3D (1991) was the first 2.5D game by id Software to feature the technique, applied to the rasterized polygons that were used to render the game world. Its predecessor, Hovertank 3D (1991), instead only featured walls of solid colours. Texture mapping later also proved a major selling feature for the game's successor, the breakout hit Wolfenstien 3D (1992).

Texture maps may be a bitmap image or a procedural texture. They may be stored in common image file formats, referenced by 3d model formats or material definitions, and assembled into resource bundles. They may have 1-3 dimensions, although 2 dimensions are most common for visible surfaces. For use with modern hardware, texture map data may be stored in swizzled or tiled orderings to improve cache coherency. Rendering APIs typically manage texture map resources (which may be located in device memory) as buffers or surfaces, and may allow 'render to texture' for additional effects such as post processing, environment mapping. They usually contain RGB color data (either stored as direct color, compressed formats, or indexed color), and sometimes an additional channel for alpha blending (RGBA) especially for billboards and decal overlay textures. It is possible to use the alpha channel (which may be convenient to store in formats parsed by hardware) for other uses such as specularity. Multiple texture maps (or channels) may be combined for control over specularity, normals, displacement, or subsurface scattering e.g. for skin rendering. Multiple texture images may be combined in texture atlases or array textures to reduce state changes for modern hardware. (They may be considered a modern evolution of tile map graphics). Modern hardware often supports cube map textures with multiple faces for environment mapping.