00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
#ifndef TEXTURE_H
00022
#define TEXTURE_H
00023
00024
#include "colour.h"
00025
#include "finish.h"
00026
#include "lightray.h"
00027
00028
class CameraRay;
00029
00034 class Texture {
00035
00036
public:
00037
ColourA* colour;
00038
const Finish* finish;
00039
00040
public:
00041
Texture(
ColourA *c,
const Finish *f): colour(c), finish(f) {}
00042
00043 ~
Texture() {
00044
delete(colour);
00045 }
00046
00047
private:
00048
Texture(
const Texture& t);
00049
Texture& operator=(
const Texture&);
00050
00051
public:
00052
00053
void setColour(
ColourA* c) {
if (c) colour =
new ColourA(*c);}
00054
void setFinish(
const Finish* f) {finish = f;}
00055
00056
Colour enlightShadow(
const CameraRay &cray)
const;
00057
Colour enlightLight(
LightRay& lray,
const CameraRay& cray)
const;
00058
00059 };
00060
00061
#endif