1
Fork 0
raytracer/include/image.h
2020-02-17 10:37:01 -05:00

17 lines
333 B
C++

#pragma once
#include <glm/glm.hpp>
template<class T, int Width, int Height>
class Image {
public:
T& get(const int32_t x, const int32_t y) {
return array[y * Width + x];
}
T get(const int32_t x, const int32_t y) const {
return array[y * Width + x];
}
T array[Width * Height] = {};
};