Started working on 2D patterns.
This commit is contained in:
28
source/include/uv_pattern.h
Normal file
28
source/include/uv_pattern.h
Normal file
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* DoRayMe - a quick and dirty Raytracer
|
||||
* UV Pattern header
|
||||
*
|
||||
* Created by Manoël Trapier
|
||||
* Copyright (c) 2020 986-Studio.
|
||||
*
|
||||
*/
|
||||
#ifndef DORAYME_UV_PATTERN_H
|
||||
#define DORAYME_UV_PATTERN_H
|
||||
|
||||
#include <colour.h>
|
||||
|
||||
class UVPattern
|
||||
{
|
||||
public:
|
||||
Colour a;
|
||||
Colour b;
|
||||
double width;
|
||||
double height;
|
||||
|
||||
UVPattern(double width, double height, Colour a, Colour b) : a(a), b(b),
|
||||
width(width), height(height) {};
|
||||
|
||||
virtual Colour uvPatternAt(double u, double v) = 0;
|
||||
};
|
||||
|
||||
#endif /* DORAYME_UV_PATTERN_H */
|
||||
Reference in New Issue
Block a user