From 687301377ed48bfc1c0843ef61b114c6299912ae Mon Sep 17 00:00:00 2001 From: kervala Date: Tue, 5 Jan 2016 12:53:32 +0100 Subject: [PATCH] Fixed: Instead of returning an error, convert the bitmap in RGBA --HG-- branch : develop --- code/nel/tools/3d/build_interface/main.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/code/nel/tools/3d/build_interface/main.cpp b/code/nel/tools/3d/build_interface/main.cpp index 343673b34..1b13a0f71 100644 --- a/code/nel/tools/3d/build_interface/main.cpp +++ b/code/nel/tools/3d/build_interface/main.cpp @@ -268,7 +268,11 @@ int main(int nNbArg, char **ppArgs) uint8 colors = pBtmp->load(inFile); - if (colors != 32) throw NLMISC::Exception(AllMapNames[i] + " is using " + toString(colors) + " bits colors, only 32 bit supported!"); + if (pBtmp->getPixelFormat() != CBitmap::RGBA) + { + nlwarning("Converting %s to RGBA (32 bits), originally using %u bits...", AllMapNames[i].c_str(), (uint)colors); + pBtmp->convertToType(CBitmap::RGBA); + } AllMaps[i] = pBtmp; }