Home Reference Source Repository
import Material from 'dh3dlib/js/base/Material.js'
public class | source

Material

Direct Subclass:

ObjMaterial

Material class

Constructor Summary

Public Constructor
public

constructor

Member Summary

Public Members
public
public

ambient: *

public

diffuse: *

public
public
public
public
public

sphere: *

public
public

texture: *

public
public
public

toon: *

public
public

Method Summary

Public Methods
public

clearCache(): void

clear cache

public

getAlpha(): float

get alpha value

public

get ambient value

public

get diffuse value

public

get emission value

public

getShininess(): float

get shininess value

public

get specular value

Public Constructors

public constructor(m: Material) source

constructor

Params:

NameTypeAttributeDescription
m Material

Public Members

public alpha: number source

public ambient: * source

public diffuse: * source

public edge: number source

public emission: * source

public shininess: number source

public specular: * source

public sphere: * source

public sphereFileName: string source

public texture: * source

public textureFileName: string source

public texture_repeat: boolean source

public toon: * source

public toonFileName: string source

public toonIndex: number source

Public Methods

public clearCache(): void source

clear cache

Return:

void

public getAlpha(): float source

get alpha value

Return:

float

alpha value

public getAmbient(): Float32Array source

get ambient value

Return:

Float32Array

ambient value

public getDiffuse(): Float32Array source

get diffuse value

Return:

Float32Array

diffuse value

public getEmission(): Float32Array source

get emission value

Return:

Float32Array

emission value

public getShininess(): float source

get shininess value

Return:

float

shininess value

public getSpecular(): Float32Array source

get specular value

Return:

Float32Array

specular value