Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/orxonox/branches/sound/src/material.h @ 3360

Last change on this file since 3360 was 2964, checked in by bensch, 20 years ago

orxonox/branches/sound: merged Trunk back into sound. and included all headers for real into the configure.ac-script.

File size: 1.2 KB
Line 
1/*!
2  \file material.h
3  \brief Contains the Material Class that handles Material for 3D-Objects.
4*/
5
6#ifndef _MATERIAL_H
7#define _MATERIAL_H
8
9extern int verbose; //!< will be obsolete soon.
10
11#include <GL/gl.h>
12#include <GL/glu.h>
13#include <stdlib.h>
14#include <fstream>
15
16//! Class to handle Materials.
17class Material
18{
19 public:
20  Material ();
21  Material (char* mtlName);
22  Material* addMaterial(char* mtlName);
23
24  void init(void);
25  ~Material ();
26
27
28  void setName (char* mtlName);
29  char* getName (void);
30  void setIllum (int illum);
31  void setIllum (char* illum);
32  void setDiffuse (float r, float g, float b);
33  void setDiffuse (char* rgb);
34  void setAmbient (float r, float g, float b);
35  void setAmbient (char* rgb);
36  void setSpecular (float r, float g, float b);
37  void setSpecular (char* rgb);
38  void setShininess (float shini);
39  void setShininess (char* shini);
40  void setTransparency (float trans);
41  void setTransparency (char* trans);
42
43  Material* search (char* mtlName);
44
45  bool select (void);
46
47  Material* nextMat; //!< pointer to the Next Material of the List. NULL if no next exists.
48
49 private:
50  char name [50];
51  int illumModel;
52  float diffuse [4];
53  float ambient [4];
54  float specular [4];
55  float shininess;
56  float transparency;
57
58};
59#endif
Note: See TracBrowser for help on using the repository browser.