- Change BaseImporter::GetExtensionList to add all known file extensions to a std::set, so uniqueness is guaranteed. Also rewrite all related functions in Importer. NOTE: This does *not* change the public interface.

- FIX build error on vc8/release-noboost x64, ConvertUTF.c had wrong PCH settings.
- ADD knowext and listext verbs to assimp_cmd, add some raw docs.
- Update unit tests to reflect these changes. Currently I keep getting failures in some tests, this needs to be resolved *urgently*.

git-svn-id: https://assimp.svn.sourceforge.net/svnroot/assimp/trunk@567 67173fc5-114c-0410-ac8e-9d2fd5bffc1f
This commit is contained in:
aramis_acg
2010-03-02 17:38:01 +00:00
parent 8ef1e5b4ba
commit 5738860990
72 changed files with 417 additions and 262 deletions

View File

@@ -2,7 +2,6 @@
#include "UnitTestPCH.h"
#include "utImporter.h"
#define InputData_BLOCK_SIZE 1310
// test data for Importer::ReadFileFromMemory() - ./test/3DS/CameraRollAnim.3ds
@@ -71,9 +70,12 @@ bool TestPlugin :: CanRead( const std::string& pFile,
extension == ".linux" || extension == ".windows" );
}
void TestPlugin :: GetExtensionList(std::string& append)
void TestPlugin :: GetExtensionList(std::set<std::string>& extensions)
{
append.append("*.apple;*.mac;*.linux;*.windows");
extensions.insert("apple");
extensions.insert("mac");
extensions.insert("linux");
extensions.insert("windows");
}
void TestPlugin :: InternReadFile( const std::string& pFile,
@@ -135,12 +137,13 @@ void ImporterTest :: testStringProperty (void)
void ImporterTest :: testPluginInterface (void)
{
pImp->RegisterLoader(new TestPlugin());
CPPUNIT_ASSERT(pImp->IsExtensionSupported(".apple"));
CPPUNIT_ASSERT(pImp->IsExtensionSupported(".mac"));
CPPUNIT_ASSERT(pImp->IsExtensionSupported(".linux"));
CPPUNIT_ASSERT(pImp->IsExtensionSupported(".windows"));
CPPUNIT_ASSERT(pImp->IsExtensionSupported(".x")); /* x and 3ds must be available of course */
CPPUNIT_ASSERT(pImp->IsExtensionSupported("*.linux"));
CPPUNIT_ASSERT(pImp->IsExtensionSupported("windows"));
CPPUNIT_ASSERT(pImp->IsExtensionSupported(".x")); /* x and 3ds must be available in this Assimp build, of course! */
CPPUNIT_ASSERT(pImp->IsExtensionSupported(".3ds"));
CPPUNIT_ASSERT(!pImp->IsExtensionSupported("."));