XYZ Maps Documentation
    Preparing search index...

    Interface MaterialExperimental

    The Material to render the model/geometry using the Phong reflection model.

    interface Material {
        ambient?: number[];
        diffuse?: number[];
        diffuseMap?: string;
        emissive?: number[];
        flipY?: boolean;
        illumination?: number;
        mode?: "Triangles" | "Points";
        normalMap?: string;
        opacity?: number;
        pointSize?: number;
        shininess?: number;
        specular?: number[];
        specularMap?: string;
        useUVMapping?: boolean;
        uvScale?: number;
        wrap?:
            | "clamp"
            | "repeat"
            | "mirror"
            | [
                wrapS: "clamp"
                | "repeat"
                | "mirror",
                wrapT: "clamp" | "repeat" | "mirror",
            ];
    }
    Index
    ambient?: number[]

    The Ambient color reflection intensity constant of the material.

    [1,1,1] (white)
    
    diffuse?: number[]

    Diffuse color of the material.

    [1, 1, 1] (white)
    
    diffuseMap?: string

    The name of the diffuse map used by the material. The actual texture must be defined in ModelData.textures.

    emissive?: number[]

    The emissive color of the material. Emissive Color is solid and unaffected by other lightning.

    [1,1,1] (white)
    
    flipY?: boolean

    A flag to specify if the texture should be flipped vertically.

    false
    
    illumination?: number

    The Illumination Mode of the material.

    • mode 0: Constant color mode. Colors, no lightning, no shading
    • mode 1: Diffuse lightning mode.
    1
    
    mode?: "Triangles" | "Points"

    The used primitive type to render the model geometry.

    "Triangles"
    
    normalMap?: string

    The name of the normal map used by the material. The actual texture must be defined in ModelData.textures.

    opacity?: number

    The opacity of the material determines how much this material dissolves into the background. The value must be between 0.0 (completely transparent) and 1.0 (fully opaque).

    1
    
    pointSize?: number

    The used pointSize in pixels to render when mode is set to "Points".

    shininess?: number

    The shininess of the material determines how shiny the specular highlights are rendered. A higher value results in a sharper, more focused highlight, while lower values cause the highlight to become more blown out. The value range is from 0 to 1000.

    32
    
    specular?: number[]

    Specular defines the specular highlight color of the material.

    [1, 1, 1] (white)
    
    specularMap?: string

    The name of the specular map used by the material. The actual texture must be defined in ModelData.textures.

    useUVMapping?: boolean
    uvScale?: number
    wrap?:
        | "clamp"
        | "repeat"
        | "mirror"
        | [
            wrapS: "clamp"
            | "repeat"
            | "mirror",
            wrapT: "clamp" | "repeat" | "mirror",
        ]

    Texture wrapping mode for the U (horizontal) and V (vertical) directions. Supported values are 'clamp', 'repeat', and 'mirror'.

    'repeat'