summaryrefslogtreecommitdiff
path: root/texturestbi.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'texturestbi.cpp')
-rw-r--r--texturestbi.cpp20
1 files changed, 0 insertions, 20 deletions
diff --git a/texturestbi.cpp b/texturestbi.cpp
deleted file mode 100644
index abd802e..0000000
--- a/texturestbi.cpp
+++ /dev/null
@@ -1,20 +0,0 @@
-#include <stdexcept>
-#include <SFML/Window/OpenGL.hpp>
-#include "texturestbi.h"
-#include "stb_image.h"
-
-TextureSTBI::TextureSTBI(const char* filename) {
- int w, h, ch;
- uint8_t* data = stbi_load(filename, &w, &h, &ch, 4);
-
- unsigned int format;
- if(ch == 4) {
- format = GL_RGBA;
- } else {
- format = GL_RGB;
- }
-
- build(data, format, w, h);
-
- stbi_image_free(data);
-}