Kochol Game Engine  0.1.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Material.h
Go to the documentation of this file.
1 // File name: Material.h
2 // Des: The Material class.
3 // Date: 2/1/1386
4 // Programmer: Ali Akbar Mohammadi(Kochol)
5 
6 #ifndef MATERIAL_H
7 #define MATERIAL_H
8 
9 #include "../KgeUnknown.h"
10 #include "../kgedef.h"
11 #include "../core/String.h"
12 #include "../core/KgeMemory.h"
13 #include "Color.h"
14 #include "Shader.h"
15 #include "Texture.h"
16 
17 namespace kge
18 {
19 namespace gfx
20 {
23 class Material: public KgeUnknown
24 {
25 public:
26  Material() : Shininess(0.0f), Alpha(false), TextureAlphal(false), Culling(true)
27  {
29  for (int i = 0; i < 8; i++)
30  ppTexture[i] = NULL;
31 
32  }
33 
35  {
37  }
38 
40  {
41  Name = mat.Name;
42  Ambient = mat.Ambient;
43  Diffuse = mat.Diffuse;
44  Specular = mat.Specular;
45  Emissive = mat.Emissive;
46  Shininess = mat.Shininess;
47  for (int i = 0; i < 8; i++)
48  ppTexture[i] = mat.ppTexture[i];
49  *shader = *mat.shader;
50  Alpha = mat.Alpha;
52  Culling = mat.Culling;
53 
54  return *this;
55  }
56 
62  float Shininess;
65  bool Alpha;
67  bool Culling;
69  float FrenselVal;
70 
71 }; // Material
72 
73 } // gfx
74 
75 } // kge
76 
77 #endif // MATERIAL_H