/*
Copyright (C) 1997, 1998, 1999, 2000 by Alex Pfaffe
(Digital Dawn Graphics Inc)
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; if not, write to the Free
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#ifndef _ddgMaterial_Class_
#define _ddgMaterial_Class_
#include "struct/ddgcolor.h"
#include "struct/ddgnode.h"
class WEXP ddgMaterial: public ddgNode {
typedef ddgNode super;
ddgColor4 _ambient;
ddgColor4 _diffuse;
ddgColor4 _emission;
ddgColor4 _specular;
float _shininess;
bool _fambient:1;
bool _fdiffuse:1;
bool _femission:1;
bool _fspecular:1;
bool _fshininess:1;
public:
ddgMaterial( unsigned char r = 200, unsigned char g = 200, unsigned char b = 200 );
void ambient(unsigned char r, unsigned char g, unsigned char b, unsigned char t = 255);
void diffuse(unsigned char r, unsigned char g, unsigned char b, unsigned char t = 255);
void specular(unsigned char r, unsigned char g, unsigned char b, unsigned char t = 255);
void emission(unsigned char r, unsigned char g, unsigned char b, unsigned char t = 255);
void shininess(float s);
bool draw (ddgContext *c);
};
#endif