diff --git a/CMakeLists.txt b/CMakeLists.txt index 6417053ac..67e832c1a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -67,7 +67,7 @@ OPTION( ASSIMP_NO_EXPORT ) OPTION( ASSIMP_BUILD_ZLIB "Build your own zlib" - OFF + OFF ) OPTION( ASSIMP_BUILD_ASSIMP_TOOLS "If the supplementary tools for Assimp are built in addition to the library." @@ -468,6 +468,7 @@ ENDIF ( ASSIMP_BUILD_ASSIMP_TOOLS ) IF ( ASSIMP_BUILD_SAMPLES) IF ( WIN32 ) ADD_SUBDIRECTORY( samples/SimpleTexturedOpenGL/ ) + ADD_SUBDIRECTORY( samples/SimpleTexturedDirectx11 ) ENDIF ( WIN32 ) ADD_SUBDIRECTORY( samples/SimpleOpenGL/ ) ENDIF ( ASSIMP_BUILD_SAMPLES ) diff --git a/code/CMakeLists.txt b/code/CMakeLists.txt index 37ad34b85..ec08d6a88 100644 --- a/code/CMakeLists.txt +++ b/code/CMakeLists.txt @@ -756,12 +756,11 @@ SET( Extra_SRCS ) SOURCE_GROUP( Extra FILES ${Extra_SRCS}) - SET( Clipper_SRCS ../contrib/clipper/clipper.hpp ../contrib/clipper/clipper.cpp ) -SOURCE_GROUP( Clipper FILES ${Clipper_SRCS}) +SOURCE_GROUP( Contrib\\Clipper FILES ${Clipper_SRCS}) SET( Poly2Tri_SRCS ../contrib/poly2tri/poly2tri/common/shapes.cc @@ -776,7 +775,7 @@ SET( Poly2Tri_SRCS ../contrib/poly2tri/poly2tri/sweep/sweep_context.cc ../contrib/poly2tri/poly2tri/sweep/sweep_context.h ) -SOURCE_GROUP( Poly2Tri FILES ${Poly2Tri_SRCS}) +SOURCE_GROUP( Contrib\\Poly2Tri FILES ${Poly2Tri_SRCS}) SET( unzip_SRCS ../contrib/unzip/crypt.h @@ -785,7 +784,7 @@ SET( unzip_SRCS ../contrib/unzip/unzip.c ../contrib/unzip/unzip.h ) -SOURCE_GROUP( unzip FILES ${unzip_SRCS}) +SOURCE_GROUP(Contrib\\unzip FILES ${unzip_SRCS}) SET( ziplib_SRCS ../contrib/zip/src/miniz.h @@ -793,7 +792,7 @@ SET( ziplib_SRCS ../contrib/zip/src/zip.h ) -SOURCE_GROUP( ziplib FILES ${ziplib_SRCS} ) +SOURCE_GROUP( Contrib\\ziplib FILES ${ziplib_SRCS} ) SET ( openddl_parser_SRCS ../contrib/openddlparser/code/OpenDDLParser.cpp @@ -810,7 +809,7 @@ SET ( openddl_parser_SRCS ../contrib/openddlparser/include/openddlparser/DDLNode.h ../contrib/openddlparser/include/openddlparser/Value.h ) -SOURCE_GROUP( openddl_parser FILES ${openddl_parser_SRCS}) +SOURCE_GROUP( Contrib\\openddl_parser FILES ${openddl_parser_SRCS}) SET ( open3dgc_SRCS ../contrib/Open3DGC/o3dgcAdjacencyInfo.h @@ -843,7 +842,7 @@ SET ( open3dgc_SRCS ../contrib/Open3DGC/o3dgcVector.h ../contrib/Open3DGC/o3dgcVector.inl ) -SOURCE_GROUP( open3dgc FILES ${open3dgc_SRCS}) +SOURCE_GROUP( Contrib\\open3dgc FILES ${open3dgc_SRCS}) # Check dependencies for glTF importer with Open3DGC-compression. # RT-extensions is used in "contrib/Open3DGC/o3dgcTimer.h" for collecting statistics. Pointed file diff --git a/code/FBXConverter.cpp b/code/FBXConverter.cpp index c556d3bba..a61ae4006 100644 --- a/code/FBXConverter.cpp +++ b/code/FBXConverter.cpp @@ -964,7 +964,7 @@ namespace Assimp { { if (indices[i] < 0) epcount++; } - unsigned int pcount = indices.size(); + unsigned int pcount = static_cast( indices.size() ); unsigned int scount = out_mesh->mNumFaces = pcount - epcount; aiFace* fac = out_mesh->mFaces = new aiFace[scount](); diff --git a/code/SMDLoader.cpp b/code/SMDLoader.cpp index 00d92e0b4..4185c3400 100644 --- a/code/SMDLoader.cpp +++ b/code/SMDLoader.cpp @@ -486,7 +486,7 @@ void SMDImporter::CreateOutputAnimations(const std::string &pFile, IOSystem* pIO if (bLoadAnimationList) { GetAnimationFileList(pFile, pIOHandler, animFileList); } - int animCount = animFileList.size() + 1; + int animCount = static_cast( animFileList.size() ) + 1; pScene->mNumAnimations = 1; pScene->mAnimations = new aiAnimation*[animCount]; memset(pScene->mAnimations, 0, sizeof(aiAnimation*)*animCount); @@ -510,7 +510,7 @@ void SMDImporter::CreateOutputAnimation(int index, const std::string &name) { anim->mName.Set(name.c_str()); } anim->mDuration = dLengthOfAnim; - anim->mNumChannels = asBones.size(); + anim->mNumChannels = static_cast( asBones.size() ); anim->mTicksPerSecond = 25.0; // FIXME: is this correct? aiNodeAnim** pp = anim->mChannels = new aiNodeAnim*[anim->mNumChannels]; diff --git a/code/glTF2Asset.h b/code/glTF2Asset.h index 0015197c2..2937c0ce9 100644 --- a/code/glTF2Asset.h +++ b/code/glTF2Asset.h @@ -223,7 +223,8 @@ namespace glTF2 ComponentType_FLOAT = 5126 }; - inline unsigned int ComponentTypeSize(ComponentType t) + inline + unsigned int ComponentTypeSize(ComponentType t) { switch (t) { case ComponentType_SHORT: @@ -250,7 +251,7 @@ namespace glTF2 }; //! Values for the Sampler::magFilter field - enum class SamplerMagFilter: unsigned int + enum class SamplerMagFilter : unsigned int { UNSET = 0, SamplerMagFilter_Nearest = 9728, @@ -258,7 +259,7 @@ namespace glTF2 }; //! Values for the Sampler::minFilter field - enum class SamplerMinFilter: unsigned int + enum class SamplerMinFilter : unsigned int { UNSET = 0, SamplerMinFilter_Nearest = 9728, diff --git a/contrib/irrXML/CMakeLists.txt b/contrib/irrXML/CMakeLists.txt index 48941970a..ef3ce1478 100644 --- a/contrib/irrXML/CMakeLists.txt +++ b/contrib/irrXML/CMakeLists.txt @@ -13,7 +13,7 @@ if ( MSVC ) ADD_DEFINITIONS( -D_CRT_SECURE_NO_WARNINGS ) endif ( MSVC ) -add_library(IrrXML STATIC ${IrrXML_SRCS}) +add_library(IrrXML ${IrrXML_SRCS}) set(IRRXML_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}" CACHE INTERNAL "IrrXML_Include" ) set(IRRXML_LIBRARY "IrrXML" CACHE INTERNAL "IrrXML" ) diff --git a/contrib/irrXML/CXMLReaderImpl.h b/contrib/irrXML/CXMLReaderImpl.h index 7d33b9404..6f3bec5fa 100644 --- a/contrib/irrXML/CXMLReaderImpl.h +++ b/contrib/irrXML/CXMLReaderImpl.h @@ -10,8 +10,11 @@ #include "irrArray.h" #include +#include +#include +#include +//using namespace Assimp; -using namespace Assimp; #ifdef _DEBUG #define IRR_DEBUGPRINT(x) printf((x)); @@ -162,7 +165,8 @@ public: return 0; core::stringc c = attr->Value.c_str(); - return fast_atof(c.c_str()); + return static_cast(atof(c.c_str())); + //return fast_atof(c.c_str()); } @@ -174,7 +178,8 @@ public: return 0; core::stringc c = attrvalue; - return fast_atof(c.c_str()); + return static_cast(atof(c.c_str())); + //return fast_atof(c.c_str()); } @@ -428,7 +433,7 @@ private: ++P; // remove trailing whitespace, if any - while( isspace( P[-1])) + while( std::isspace( P[-1])) --P; NodeName = core::string(pBeginClose, (int)(P - pBeginClose)); diff --git a/contrib/irrXML/irrXML.cpp b/contrib/irrXML/irrXML.cpp index 532eed544..609d51359 100644 --- a/contrib/irrXML/irrXML.cpp +++ b/contrib/irrXML/irrXML.cpp @@ -9,7 +9,7 @@ #include "irrXML.h" #include "irrString.h" #include "irrArray.h" -#include +//#include #include "CXMLReaderImpl.h" namespace irr