Support stb_image based texture reader (closes #541)

This commit is contained in:
Alexander Bock
2018-03-08 17:38:35 +01:00
parent 5a3ef0fda2
commit ae3b6fe850
2 changed files with 10 additions and 1 deletions
+9
View File
@@ -74,6 +74,10 @@
#include <ghoul/io/texture/texturewritersoil.h>
#endif //GHOUL_USE_SOIL
#ifdef GHOUL_USE_STB
#include <ghoul/io/texture/texturereaderstb.h>
#endif // GHOUL_USE_STB
#include <array>
#include <stack>
@@ -404,6 +408,11 @@ void RenderEngine::initialize() {
std::make_shared<ghoul::io::TextureWriterSOIL>()
);
#endif // GHOUL_USE_SOIL
#ifdef GHOUL_USE_STB
ghoul::io::TextureReader::ref().addReader(
std::make_shared<ghoul::io::TextureReaderSTB>()
);
#endif
ghoul::io::TextureReader::ref().addReader(
std::make_shared<ghoul::io::TextureReaderCMAP>()