From 487071be7745ecaf3508936eadd7291cc1eac5b3 Mon Sep 17 00:00:00 2001 From: ulfjorensen Date: Wed, 14 Sep 2011 09:41:48 +0000 Subject: [PATCH] Bugfix: FCollada's special texture tag "bump" now maps to aiTEXTURE_NORMAL. Thanks to agent8261 for the hint Bugfix: AssimpView now properly skips the leading quotation mark when being executed with a file git-svn-id: https://assimp.svn.sourceforge.net/svnroot/assimp/trunk@1078 67173fc5-114c-0410-ac8e-9d2fd5bffc1f --- code/ColladaLoader.cpp | 2 +- code/Q3BSPZipArchive.h | 2 +- tools/assimp_view/MessageProc.cpp | 6 ++++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/code/ColladaLoader.cpp b/code/ColladaLoader.cpp index a0c9f52bd..6b4870ac8 100644 --- a/code/ColladaLoader.cpp +++ b/code/ColladaLoader.cpp @@ -1260,7 +1260,7 @@ void ColladaLoader::FillMaterials( const ColladaParser& pParser, aiScene* /*pSce AddTexture( mat, pParser, effect, effect.mTexDiffuse, aiTextureType_DIFFUSE); if( !effect.mTexBump.mName.empty()) - AddTexture( mat, pParser, effect, effect.mTexBump, aiTextureType_HEIGHT); + AddTexture( mat, pParser, effect, effect.mTexBump, aiTextureType_NORMALS); if( !effect.mTexTransparent.mName.empty()) AddTexture( mat, pParser, effect, effect.mTexTransparent, aiTextureType_OPACITY); diff --git a/code/Q3BSPZipArchive.h b/code/Q3BSPZipArchive.h index 6594b9260..dbad66062 100644 --- a/code/Q3BSPZipArchive.h +++ b/code/Q3BSPZipArchive.h @@ -40,7 +40,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #ifndef AI_Q3BSP_ZIPARCHIVE_H_INC #define AI_Q3BSP_ZIPARCHIVE_H_INC -#include "unzip.h" +#include "../contrib/unzip/unzip.h" #include "../include/IOStream.h" #include "../include/IOSystem.h" #include diff --git a/tools/assimp_view/MessageProc.cpp b/tools/assimp_view/MessageProc.cpp index c005c27b8..a0c50d93e 100644 --- a/tools/assimp_view/MessageProc.cpp +++ b/tools/assimp_view/MessageProc.cpp @@ -128,10 +128,12 @@ void HandleCommandLine(char* p_szCommand) if (strlen(sz) < 2)return; if (*sz == '\"') - { + { char* sz2 = strrchr(sz,'\"'); if (sz2)*sz2 = 0; - } + sz++; // skip the starting quote + } + strcpy( g_szFileName, sz ); LoadAsset();