From 319b9d09edb66a54edf29f6bae52e1f0d46b09e5 Mon Sep 17 00:00:00 2001 From: fgenesis Date: Thu, 12 Jul 2012 03:46:18 +0000 Subject: [PATCH] Fix regression that prevented few textures from loading (Labyrinth mod icon, for example) --- BBGE/Localization.cpp | 2 +- BBGE/Texture.cpp | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/BBGE/Localization.cpp b/BBGE/Localization.cpp index 5558e3b..2affc66 100644 --- a/BBGE/Localization.cpp +++ b/BBGE/Localization.cpp @@ -110,7 +110,7 @@ std::string getSystemLocale() size_t found = localeStr.find('.'); - if (found != string::npos) + if (found != std::string::npos) localeStr.resize(found); } #endif diff --git a/BBGE/Texture.cpp b/BBGE/Texture.cpp index bb74f46..df609ec 100644 --- a/BBGE/Texture.cpp +++ b/BBGE/Texture.cpp @@ -281,6 +281,9 @@ void Texture::load(std::string file) return; } + stringToLowerUserData(file); + file = core->adjustFilenameCase(file); + loadName = file; repeating = false; @@ -316,6 +319,7 @@ void Texture::load(std::string file) if (found) { file = localisePath(file); + file = core->adjustFilenameCase(file); /* std::ostringstream os; @@ -606,7 +610,7 @@ ImageTGA *Texture::TGAloadMem(void *mem, int size) // Read the width, height and bits per pixel (16, 24 or 32) bb >> width >> height >> bits; - + /* std::ostringstream os; os << "TGALoad: width: " << width << " height: " << height << " bits: " << bits;