|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectde.javagl.utils.obj.impl.DefaultMtl
public class DefaultMtl
Default implementation of an Mtl (material)
| Constructor Summary | |
|---|---|
DefaultMtl(String name)
Creates a new material with the given name |
|
| Method Summary | |
|---|---|
boolean |
equals(Object obj)
|
float |
getD()
Returns the opacity of the material |
FloatTuple |
getKa()
Returns the ambient component of the material |
FloatTuple |
getKd()
Returns the diffuse component of the material |
FloatTuple |
getKs()
Returns the specular component of the material |
String |
getMapKd()
Returns the name of the diffuse map of the material, or null if it has not map. |
String |
getName()
Return the name of the material |
float |
getNs()
Returns the shininess of the material. |
int |
hashCode()
|
void |
setD(float d)
Set the opacity of this material |
void |
setKa(float ka0,
float ka1,
float ka2)
Set the ambient part of this material |
void |
setKd(float kd0,
float kd1,
float kd2)
Set the diffuse part of this material |
void |
setKs(float ks0,
float ks1,
float ks2)
Set the specular part of this material |
void |
setMapKd(String mapKd)
Set the diffuse map name of this material |
void |
setNs(float ns)
Set the shininess of this material |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultMtl(String name)
name - The name of this material| Method Detail |
|---|
public String getName()
Mtl
getName in interface Mtl
public void setKa(float ka0,
float ka1,
float ka2)
ka0 - The ambient component 0ka1 - The ambient component 1ka2 - The ambient component 2public FloatTuple getKa()
Mtl
getKa in interface Mtl
public void setKs(float ks0,
float ks1,
float ks2)
ks0 - The specular component 0ks1 - The specular component 1ks2 - The specular component 2public FloatTuple getKs()
Mtl
getKs in interface Mtl
public void setKd(float kd0,
float kd1,
float kd2)
kd0 - The diffuse component 0kd1 - The diffuse component 1kd2 - The diffuse component 2public FloatTuple getKd()
Mtl
getKd in interface Mtlpublic void setMapKd(String mapKd)
mapKd - The diffuse map name of this materialpublic String getMapKd()
Mtl
getMapKd in interface Mtlpublic void setNs(float ns)
ns - The shininess of this materialpublic float getNs()
Mtl
getNs in interface Mtlpublic void setD(float d)
d - The opacity of this materialpublic float getD()
Mtl
getD in interface Mtlpublic String toString()
toString in class Objectpublic int hashCode()
hashCode in class Objectpublic boolean equals(Object obj)
equals in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||