From 611778045dc69efe2253d4ddc599f69b993d37e8 Mon Sep 17 00:00:00 2001 From: abma Date: Thu, 16 Apr 2015 02:55:41 +0200 Subject: [PATCH] fix for upstream changes --- code/3DSConverter.cpp | 1 + code/3DSExporter.cpp | 1 + code/ACLoader.h | 8 +++---- code/AssbinExporter.cpp | 5 ++-- code/AssxmlExporter.cpp | 5 ++-- code/BaseImporter.cpp | 1 + code/Bitmap.h | 2 +- code/BlenderLoader.cpp | 2 ++ code/ColladaLoader.cpp | 2 ++ code/DefaultIOStream.h | 5 +--- code/Defines.h | 49 ++++++++++++++++++++++++++++++++++++++ code/IFCBoolean.cpp | 1 + code/IFCUtil.cpp | 1 + code/Importer.cpp | 1 + code/Importer.h | 2 +- code/MD3Loader.cpp | 2 ++ code/MDLMaterialLoader.cpp | 3 ++- code/ObjExporter.cpp | 1 + code/OgreParsingUtils.h | 1 + code/OpenGEXImporter.cpp | 3 ++- code/OpenGEXImporter.h | 3 +++ code/PlyExporter.cpp | 5 ++-- code/STLExporter.cpp | 3 ++- code/SceneCombiner.h | 2 +- code/StandardShapes.cpp | 1 + code/StreamReader.h | 1 + code/StringComparison.h | 1 + code/XFileExporter.cpp | 2 +- code/XFileExporter.h | 1 + code/XFileHelper.h | 1 + code/XFileImporter.cpp | 3 +++ code/XGLLoader.cpp | 2 ++ 32 files changed, 100 insertions(+), 21 deletions(-) create mode 100644 code/Defines.h diff --git a/code/3DSConverter.cpp b/code/3DSConverter.cpp index b33eec57f..d5a83461c 100644 --- a/code/3DSConverter.cpp +++ b/code/3DSConverter.cpp @@ -51,6 +51,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "../include/assimp/DefaultLogger.hpp" #include "StringComparison.h" #include +#include using namespace Assimp; diff --git a/code/3DSExporter.cpp b/code/3DSExporter.cpp index ad2d6a963..b16a3b2c7 100644 --- a/code/3DSExporter.cpp +++ b/code/3DSExporter.cpp @@ -49,6 +49,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "StringComparison.h" #include "../include/assimp/IOSystem.hpp" #include "../include/assimp/DefaultLogger.hpp" +#include "../include/assimp/Exporter.hpp" #include using namespace Assimp; diff --git a/code/ACLoader.h b/code/ACLoader.h index 20fa000ca..0f713dc99 100644 --- a/code/ACLoader.h +++ b/code/ACLoader.h @@ -49,10 +49,10 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "BaseImporter.h" #include "../include/assimp/types.h" -class aiNode; -class aiMesh; -class aiMaterial; -class aiLight; +struct aiNode; +struct aiMesh; +struct aiMaterial; +struct aiLight; namespace Assimp { diff --git a/code/AssbinExporter.cpp b/code/AssbinExporter.cpp index 2b9ce53bc..9ab21def9 100644 --- a/code/AssbinExporter.cpp +++ b/code/AssbinExporter.cpp @@ -41,9 +41,10 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * ASSBIN exporter main code */ #include "assbin_chunks.h" -#include "./../include/assimp/version.h" +#include "../include/assimp/version.h" #include "../include/assimp/IOStream.hpp" -#include "../include/assimp/IOSystem.hpp" +#include "../include/assimp/IOSystem.hpp" +#include "../include/assimp/Exporter.hpp" #include "ProcessHelper.h" #include "Exceptional.h" #include diff --git a/code/AssxmlExporter.cpp b/code/AssxmlExporter.cpp index 7279fa398..7bab7b1fe 100644 --- a/code/AssxmlExporter.cpp +++ b/code/AssxmlExporter.cpp @@ -43,8 +43,9 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include #include "./../include/assimp/version.h" #include "ProcessHelper.h" -#include "../include/assimp/IOStream.hpp" -#include "../include/assimp/IOSystem.hpp" +#include "../include/assimp/IOStream.hpp" +#include "../include/assimp/IOSystem.hpp" +#include "../include/assimp/Exporter.hpp" #ifdef ASSIMP_BUILD_NO_OWN_ZLIB # include diff --git a/code/BaseImporter.cpp b/code/BaseImporter.cpp index aae15f3e5..3eb0826ae 100644 --- a/code/BaseImporter.cpp +++ b/code/BaseImporter.cpp @@ -55,6 +55,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include #include #include +#include using namespace Assimp; diff --git a/code/Bitmap.h b/code/Bitmap.h index 38e3f864c..582f39565 100644 --- a/code/Bitmap.h +++ b/code/Bitmap.h @@ -54,7 +54,7 @@ struct aiTexture; namespace Assimp { -struct IOStream; +class IOStream; class Bitmap { protected: diff --git a/code/BlenderLoader.cpp b/code/BlenderLoader.cpp index 5ae668d79..ae7df0b64 100644 --- a/code/BlenderLoader.cpp +++ b/code/BlenderLoader.cpp @@ -57,6 +57,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "StreamReader.h" #include "MemoryIOWrapper.h" +#include + // zlib is needed for compressed blend files #ifndef ASSIMP_BUILD_NO_COMPRESSED_BLEND diff --git a/code/ColladaLoader.cpp b/code/ColladaLoader.cpp index a51adcbc9..2f59e161a 100644 --- a/code/ColladaLoader.cpp +++ b/code/ColladaLoader.cpp @@ -52,12 +52,14 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "fast_atof.h" #include "ParsingUtils.h" #include "SkeletonMeshBuilder.h" +#include "Defines.h" #include "time.h" #include #include "../include/assimp/DefaultLogger.hpp" #include "../include/assimp/Importer.hpp" #include +#include "Defines.h" using namespace Assimp; diff --git a/code/DefaultIOStream.h b/code/DefaultIOStream.h index 5adb21e1d..694527d81 100644 --- a/code/DefaultIOStream.h +++ b/code/DefaultIOStream.h @@ -45,10 +45,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include #include "../include/assimp/IOStream.hpp" #include "../include/assimp/importerdesc.h" - -#if (!defined SIZE_MAX) -# define SIZE_MAX (~((size_t)0)) -#endif +#include "Defines.h" namespace Assimp { diff --git a/code/Defines.h b/code/Defines.h new file mode 100644 index 000000000..e1e444378 --- /dev/null +++ b/code/Defines.h @@ -0,0 +1,49 @@ +/* +Open Asset Import Library (assimp) +---------------------------------------------------------------------- + +Copyright (c) 2006-2012, assimp team +All rights reserved. + +Redistribution and use of this software in source and binary forms, +with or without modification, are permitted provided that the +following conditions are met: + +* Redistributions of source code must retain the above + copyright notice, this list of conditions and the + following disclaimer. + +* Redistributions in binary form must reproduce the above + copyright notice, this list of conditions and the + following disclaimer in the documentation and/or other + materials provided with the distribution. + +* Neither the name of the assimp team, nor the names of its + contributors may be used to endorse or promote products + derived from this software without specific prior + written permission of the assimp team. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +---------------------------------------------------------------------- +*/ + +// We need those constants, workaround for any platforms where nobody defined them yet +#if (!defined SIZE_MAX) +# define SIZE_MAX (~((size_t)0)) +#endif + +#if (!defined UINT_MAX) +# define UINT_MAX (~((unsigned int)0)) +#endif + diff --git a/code/IFCBoolean.cpp b/code/IFCBoolean.cpp index 2bc7e9717..c5307121a 100644 --- a/code/IFCBoolean.cpp +++ b/code/IFCBoolean.cpp @@ -47,6 +47,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "IFCUtil.h" #include "PolyTools.h" #include "ProcessHelper.h" +#include "Defines.h" #include #include diff --git a/code/IFCUtil.cpp b/code/IFCUtil.cpp index 9fb070325..dfaf19427 100644 --- a/code/IFCUtil.cpp +++ b/code/IFCUtil.cpp @@ -49,6 +49,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "IFCUtil.h" #include "PolyTools.h" #include "ProcessHelper.h" +#include "Defines.h" namespace Assimp { namespace IFC { diff --git a/code/Importer.cpp b/code/Importer.cpp index 9f3efb4ca..9c9bdbf8d 100644 --- a/code/Importer.cpp +++ b/code/Importer.cpp @@ -78,6 +78,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "Profiler.h" #include #include +#include #ifndef ASSIMP_BUILD_NO_VALIDATEDS_PROCESS # include "ValidateDataStructure.h" diff --git a/code/Importer.h b/code/Importer.h index 9d24d23a3..c1f508fc4 100644 --- a/code/Importer.h +++ b/code/Importer.h @@ -47,7 +47,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include #include "../include/assimp/matrix4x4.h" -class aiScene; +struct aiScene; namespace Assimp { class ProgressHandler; diff --git a/code/MD3Loader.cpp b/code/MD3Loader.cpp index 39f9c2712..9517747b2 100644 --- a/code/MD3Loader.cpp +++ b/code/MD3Loader.cpp @@ -63,6 +63,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "../include/assimp/IOSystem.hpp" #include "../include/assimp/material.h" #include "../include/assimp/scene.h" +#include + using namespace Assimp; diff --git a/code/MDLMaterialLoader.cpp b/code/MDLMaterialLoader.cpp index c02dd22f6..6f5baee4e 100644 --- a/code/MDLMaterialLoader.cpp +++ b/code/MDLMaterialLoader.cpp @@ -50,8 +50,9 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "../include/assimp/texture.h" #include "../include/assimp/IOSystem.hpp" #include "../include/assimp/DefaultLogger.hpp" -#include "qnan.h" #include "../include/assimp/scene.h" +#include "qnan.h" +#include "Defines.h" using namespace Assimp; diff --git a/code/ObjExporter.cpp b/code/ObjExporter.cpp index 64c11c3bb..099b337da 100644 --- a/code/ObjExporter.cpp +++ b/code/ObjExporter.cpp @@ -46,6 +46,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "ObjExporter.h" #include "../include/assimp/version.h" #include "../include/assimp/IOSystem.hpp" +#include "../include/assimp/Exporter.hpp" #include #include "Exceptional.h" #include "../include/assimp/material.h" diff --git a/code/OgreParsingUtils.h b/code/OgreParsingUtils.h index 173a8589e..91dfecb00 100644 --- a/code/OgreParsingUtils.h +++ b/code/OgreParsingUtils.h @@ -48,6 +48,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include #include #include +#include namespace Assimp { diff --git a/code/OpenGEXImporter.cpp b/code/OpenGEXImporter.cpp index 9dd2197a7..1c85923ce 100644 --- a/code/OpenGEXImporter.cpp +++ b/code/OpenGEXImporter.cpp @@ -39,12 +39,13 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #ifndef ASSIMP_BUILD_NO_OPENGEX_IMPORTER -#include "AssimpPCH.h" #include "OpenGEXImporter.h" #include "DefaultIOSystem.h" #include "MakeVerboseFormat.h" #include +#include "../include/assimp/scene.h" + #include diff --git a/code/OpenGEXImporter.h b/code/OpenGEXImporter.h index f5c328ff7..8e65a2536 100644 --- a/code/OpenGEXImporter.h +++ b/code/OpenGEXImporter.h @@ -43,13 +43,16 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #ifndef ASSIMP_BUILD_NO_OPENGEX_IMPORTER #include "BaseImporter.h" +#include "../include/assimp/mesh.h" #include +#include namespace ODDLParser { class DDLNode; struct Context; } +struct aiNode; namespace Assimp { namespace OpenGEX { diff --git a/code/PlyExporter.cpp b/code/PlyExporter.cpp index 88fb4607f..d790f9d31 100644 --- a/code/PlyExporter.cpp +++ b/code/PlyExporter.cpp @@ -43,11 +43,12 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #if !defined(ASSIMP_BUILD_NO_EXPORT) && !defined(ASSIMP_BUILD_NO_PLY_EXPORTER) #include "PlyExporter.h" -#include "../include/assimp/version.h" -#include "../include/assimp/IOSystem.hpp" #include #include "Exceptional.h" #include "../include/assimp/scene.h" +#include "../include/assimp/version.h" +#include "../include/assimp/IOSystem.hpp" +#include "../include/assimp/Exporter.hpp" using namespace Assimp; diff --git a/code/STLExporter.cpp b/code/STLExporter.cpp index be424d60c..580620f94 100644 --- a/code/STLExporter.cpp +++ b/code/STLExporter.cpp @@ -45,9 +45,10 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "STLExporter.h" #include "../include/assimp/version.h" #include "../include/assimp/IOSystem.hpp" +#include "../include/assimp/scene.h" +#include "../include/assimp/Exporter.hpp" #include #include "Exceptional.h" -#include "../include/assimp/scene.h" #include "ByteSwap.h" using namespace Assimp; diff --git a/code/SceneCombiner.h b/code/SceneCombiner.h index 71e1ba647..34337ed81 100644 --- a/code/SceneCombiner.h +++ b/code/SceneCombiner.h @@ -46,12 +46,12 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "../include/assimp/ai_assert.h" #include "../include/assimp/types.h" +#include "Defines.h" #include #include #include #include #include -#include "../include/assimp/Compiler/pstdint.h" struct aiScene; struct aiNode; diff --git a/code/StandardShapes.cpp b/code/StandardShapes.cpp index a8af6d0c7..e9b135421 100644 --- a/code/StandardShapes.cpp +++ b/code/StandardShapes.cpp @@ -47,6 +47,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "StandardShapes.h" #include "StringComparison.h" +#include "Defines.h" #include #include "../include/assimp/mesh.h" diff --git a/code/StreamReader.h b/code/StreamReader.h index 428fe084a..bb96a20ce 100644 --- a/code/StreamReader.h +++ b/code/StreamReader.h @@ -49,6 +49,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "Exceptional.h" #include #include "../include/assimp/IOStream.hpp" +#include "Defines.h" namespace Assimp { diff --git a/code/StringComparison.h b/code/StringComparison.h index 9d15a542c..1f0ab1d9b 100644 --- a/code/StringComparison.h +++ b/code/StringComparison.h @@ -54,6 +54,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include #include #include +#include namespace Assimp { diff --git a/code/XFileExporter.cpp b/code/XFileExporter.cpp index c45beff1f..48f7e6697 100644 --- a/code/XFileExporter.cpp +++ b/code/XFileExporter.cpp @@ -52,8 +52,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include #include #include -#include "../include/assimp/IOSystem.hpp" #include "Exceptional.h" +#include "../include/assimp/IOSystem.hpp" #include "../include/assimp/scene.h" #include "../include/assimp/light.h" diff --git a/code/XFileExporter.h b/code/XFileExporter.h index 4b0553c3d..b99856f29 100644 --- a/code/XFileExporter.h +++ b/code/XFileExporter.h @@ -48,6 +48,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "../include/assimp/ai_assert.h" #include "../include/assimp/matrix4x4.h" +#include "../include/assimp/Exporter.hpp" #include struct aiScene; diff --git a/code/XFileHelper.h b/code/XFileHelper.h index 1b80b9d67..35a893ad7 100644 --- a/code/XFileHelper.h +++ b/code/XFileHelper.h @@ -51,6 +51,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "../include/assimp/quaternion.h" #include "../include/assimp/mesh.h" #include "../include/assimp/anim.h" +#include "Defines.h" namespace Assimp { diff --git a/code/XFileImporter.cpp b/code/XFileImporter.cpp index 0a57f18b1..41b8b411f 100644 --- a/code/XFileImporter.cpp +++ b/code/XFileImporter.cpp @@ -53,6 +53,9 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include "../include/assimp/scene.h" #include "../include/assimp/DefaultLogger.hpp" #include +#include "Defines.h" +#include + using namespace Assimp; diff --git a/code/XGLLoader.cpp b/code/XGLLoader.cpp index 2d2c1ad90..8187b2b12 100644 --- a/code/XGLLoader.cpp +++ b/code/XGLLoader.cpp @@ -53,6 +53,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include #include "../include/assimp/mesh.h" #include "../include/assimp/scene.h" +#include + using namespace Assimp;