2021-01-17 14:36:38 -06:00
|
|
|
#ifndef MATERIAL_H
|
|
|
|
#define MATERIAL_H
|
|
|
|
|
|
|
|
#include <GL/glew.h>
|
|
|
|
#include "stb_image.h"
|
|
|
|
|
|
|
|
#include "types.h"
|
2021-01-19 16:36:10 -06:00
|
|
|
#include "Util.h"
|
2021-01-17 14:36:38 -06:00
|
|
|
|
2021-01-25 15:17:32 -06:00
|
|
|
typedef Vector3 Color;
|
2021-01-17 14:36:38 -06:00
|
|
|
|
|
|
|
class Texture {
|
|
|
|
public:
|
|
|
|
int width, height;
|
|
|
|
Id id;
|
|
|
|
static Texture FromFile(const char *filename);
|
|
|
|
Texture();
|
|
|
|
};
|
|
|
|
|
|
|
|
struct Material {
|
|
|
|
Texture tex;
|
|
|
|
bool usesTex;
|
2021-01-22 18:44:43 -06:00
|
|
|
|
|
|
|
Color ambient;
|
|
|
|
Color diffuse;
|
|
|
|
Color specular;
|
|
|
|
|
|
|
|
int shininess;
|
|
|
|
|
2021-01-27 16:17:22 -06:00
|
|
|
float alphaScissor;
|
2021-01-21 15:26:39 -06:00
|
|
|
bool unshaded;
|
2021-01-22 15:27:32 -06:00
|
|
|
bool cullBack;
|
2021-01-17 14:36:38 -06:00
|
|
|
Material();
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif /* MATERIAL_H */
|