20#ifndef OSG_GL_FIXED_FUNCTION_AVAILABLE
21 #define GL_AMBIENT 0x1200
22 #define GL_DIFFUSE 0x1201
23 #define GL_SPECULAR 0x1202
24 #define GL_EMISSION 0x1600
25 #define GL_AMBIENT_AND_DIFFUSE 0x1602
26 #define GL_COLOR_MATERIAL 0x0B57
#define GL_DIFFUSE
Definition Material:22
#define GL_AMBIENT_AND_DIFFUSE
Definition Material:25
#define GL_SPECULAR
Definition Material:23
#define GL_AMBIENT
Definition Material:21
#define GL_EMISSION
Definition Material:24
#define COMPARE_StateAttribute_Parameter(parameter)
COMPARE_StateAttribute_Parameter macro is a helper for implementing the StatateAtribute::compare(....
Definition StateAttribute:69
#define COMPARE_StateAttribute_Types(TYPE, rhs_attribute)
COMPARE_StateAttribute_Types macro is a helper for implementing the StateAtribute::compare(....
Definition StateAttribute:57
The core osg library provides the basic scene graph classes such as Nodes, State and Drawables,...
Definition AlphaFunc:19
Vec4f Vec4
Definition Vec4:21
Copy Op(erator) used to control whether shallow or deep copy is used during copy construction and clo...
Definition CopyOp:41
@ SHALLOW_COPY
Definition CopyOp:47
Vec4 _ambientBack
Definition Material:183
virtual void apply(State &state) const
apply the OpenGL state attributes.
Vec4 _diffuseFront
Definition Material:186
bool _emissionFrontAndBack
Definition Material:193
bool getAmbientFrontAndBack() const
Definition Material:119
bool getDiffuseFrontAndBack() const
Definition Material:123
float getShininess(Face face) const
Get the shininess value for specified face.
const Vec4 & getDiffuse(Face face) const
void setTransparency(Face face, float trans)
Set the alpha value of ambient, diffuse, specular and emission colors of specified face,...
void setAlpha(Face face, float alpha)
Set the alpha value of ambient, diffuse, specular and emission colors.
bool _ambientFrontAndBack
Definition Material:181
bool getSpecularFrontAndBack() const
Return whether specular values are equal for front and back faces or not.
Definition Material:136
Vec4 _ambientFront
Definition Material:182
void setSpecular(Face face, const Vec4 &specular)
Set specular value of specified face(s) of the material, valid specular[0..3] range is 0....
bool _shininessFrontAndBack
Definition Material:197
Vec4 _emissionFront
Definition Material:194
ColorMode _colorMode
Definition Material:179
Face
Definition Material:99
@ FRONT
Definition Material:100
@ FRONT_AND_BACK
Definition Material:102
@ BACK
Definition Material:101
Vec4 _diffuseBack
Definition Material:187
ColorMode getColorMode() const
Definition Material:115
const Vec4 & getAmbient(Face face) const
void setShininess(Face face, float shininess)
Set shininess of specified face(s) of the material.
Vec4 _specularFront
Definition Material:190
bool getEmissionFrontAndBack() const
Return whether emission values are equal for front and back faces or not.
Definition Material:149
bool getShininessFrontAndBack() const
Return whether shininess values are equal for front and back faces or not.
Definition Material:162
Vec4 _emissionBack
Definition Material:195
virtual bool getModeUsage(StateAttribute::ModeUsage &) const
Return the modes associated with this StateAttribute.
Definition Material:89
void setEmission(Face face, const Vec4 &emission)
Set emission value of specified face(s) of the material, valid emission[0..3] range is 0....
ColorMode
Definition Material:105
@ OFF
Definition Material:111
@ AMBIENT_AND_DIFFUSE
Definition Material:110
@ DIFFUSE
Definition Material:107
@ EMISSION
Definition Material:109
@ SPECULAR
Definition Material:108
@ AMBIENT
Definition Material:106
virtual int compare(const StateAttribute &sa) const
return -1 if *this < *rhs, 0 if *this==*rhs, 1 if *this>*rhs.
Definition Material:60
const Vec4 & getSpecular(Face face) const
Get the specular value for specified face.
bool _diffuseFrontAndBack
Definition Material:185
const Vec4 & getEmission(Face face) const
Get the emission value for specified face.
bool _specularFrontAndBack
Definition Material:189
void setColorMode(ColorMode mode)
Definition Material:114
void setDiffuse(Face face, const Vec4 &diffuse)
void setAmbient(Face face, const Vec4 &ambient)
Material(const Material &mat, const CopyOp ©op=CopyOp::SHALLOW_COPY)
Copy constructor using CopyOp to manage deep vs shallow copy.
Definition Material:38
float _shininessFront
Definition Material:198
META_StateAttribute(osg, Material, MATERIAL)
float _shininessBack
Definition Material:199
Vec4 _specularBack
Definition Material:191
Encapsulates the current applied OpenGL modes, attributes and vertex arrays settings,...
Definition State:80
@ MATERIAL
Definition StateAttribute:129
Definition StateAttribute:308
#define OSG_EXPORT
Definition Export:39