diff options
Diffstat (limited to 'texture.h')
-rw-r--r-- | texture.h | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -1,22 +1,22 @@ #ifndef _TEXTURE_H_ #define _TEXTURE_H_ -#include <stdint.h> -#include <string> +#include "image.h" class Texture { public: Texture(); + Texture(const Image& image); Texture(const std::string& filename); - void load(const std::string& filename); + void load(const Image& image); void bind() const; unsigned int tex() const; unsigned int w() const; unsigned int h() const; protected: - void build(void* data, unsigned int format, unsigned int w, unsigned int h); + void build(const void* data, unsigned int format, unsigned int w, unsigned int h); unsigned int width; unsigned int height; unsigned int texture; |