NAME
SoMaterial – surface material definition node
INHERITS FROM
SoMaterial
SYNOPSIS
#include <Inventor/nodes/SoMaterial.h>
Fields from class SoMaterial:
Methods from class SoMaterial:
static SoType getClassTypeId()
void setOverride(SbBool state)
virtual SbBool affectsState() const
SbBool hasDefaultValues() const
SbBool set(const char *fieldDataString)
SbBool isNotifyEnabled() const
void unrefNoDelete() const
virtual SoType getTypeId() const
virtual void setName(const SbName &name)
virtual SbName getName() const
DESCRIPTION
This node defines the current surface material properties for all subsequent shapes.
SoMaterial sets several components of the current material during traversal.
Multiple values can be specified for the
diffuseColor and
transparency. Different
shapes interpret materials with multiple values differently. To bind materials to shapes, use an
SoMaterialBinding node.
FIELDS
SoMFColor ambientColor
Ambient color of the surface.
SoMFColor diffuseColor
Diffuse color(s) of the surface.
SoMFColor specularColor
Specular color of the surface.
SoMFColor emissiveColor
Emissive color of the surface.
SoMFFloat shininess
Shininess coefficient of the surface. Values can range from 0.0 for no shininess (a diffuse surface) to 1.0 for maximum shininess (a highly polished surface).
SoMFFloat transparency
Transparency value(s) of the surface. Values can range from 0.0 for opaque surfaces to 1.0 for completely transparent surfaces. If the transparency type is
SoGLRenderAction::SCREEN_DOOR then only the first transparency value will
be used. With other transparency types, multiple transparencies will be used, if the
SoMaterial node contains as many transparencies as diffuse colors. If there are not as many transparencies as diffuse colors,
only the first transparency will be used.
METHODS
SoMaterial()
Creates a material node with default settings.
static SoType getClassTypeId()
Returns type identifier for this class.
ACTION BEHAVIOR
Sets the ambient color, the diffuse color, the specular color, the emissive color, the shininess, and the transparency of the current material.
FILE FORMAT/DEFAULTS
SEE ALSO
Typeset by Felix Ritter (MeVis Research GmbH)
Hyperlinks by Wolfram Esser (method park Software AG)