MTL is a data directory which contains examples of MTL files. An MTL file is an auxilliary file containing definitions of materials that may be accessed by an OBJ file. The OBJ file must specify the name of the MTL file by a command such as
mltlib file_name
It is presumed that the MTL file names and defines various
materials, such as, perhaps, "shinyred" or "iron".
Then, within the OBJ file, the command
usemtl shinyred
indicates that all subsequence faces should be rendered with
this material, until a new material is invoked.
An MTL file contains a sequence of definitions of materials. Each definition begins with a newmtl statement that defines the name of the material, followed by lines specifying particular properties.
newmtl shinyred
Ka 0.1986 0.0000 0.0000
Kd 0.5922 0.0166 0.0000
Ks 0.5974 0.2084 0.2084
illum 2
Ns 100.2237
Comments begin with a '#' character in column 1. Blank lines may be inserted for clarity. Otherwise, the file consists of a sequence of newmtl statements, followed by a definition of various properties for that material.
The quantities that may be defined for a material include:
The computer code and data files described and made available on this web page are distributed under the GNU LGPL license.
You can go up one level to the DATA page.