add some #ifdefs for SWIG
fixed a compile error in DefaultIOSystem add swig-script git-svn-id: https://assimp.svn.sourceforge.net/svnroot/assimp/trunk@546 67173fc5-114c-0410-ac8e-9d2fd5bffc1fpull/1/head
parent
fc47576da5
commit
52228add3a
|
@ -130,7 +130,7 @@ bool IOSystem::ComparePaths (const char* one, const char* second) const
|
||||||
// Convert a relative path into an absolute path
|
// Convert a relative path into an absolute path
|
||||||
inline void MakeAbsolutePath (const char* in, char* _out)
|
inline void MakeAbsolutePath (const char* in, char* _out)
|
||||||
{
|
{
|
||||||
ai_assert(in & _out);
|
ai_assert(in && _out);
|
||||||
char* ret;
|
char* ret;
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
ret = ::_fullpath(_out, in,PATHLIMIT);
|
ret = ::_fullpath(_out, in,PATHLIMIT);
|
||||||
|
|
|
@ -166,7 +166,9 @@ enum aiAnimBehaviour
|
||||||
|
|
||||||
/** This value is not used, it is just here to force the
|
/** This value is not used, it is just here to force the
|
||||||
* the compiler to map this enum to a 32 Bit integer */
|
* the compiler to map this enum to a 32 Bit integer */
|
||||||
|
#ifndef SWIG
|
||||||
_aiAnimBehaviour_Force32Bit = 0x8fffffff
|
_aiAnimBehaviour_Force32Bit = 0x8fffffff
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
// ---------------------------------------------------------------------------
|
// ---------------------------------------------------------------------------
|
||||||
|
|
|
@ -259,10 +259,18 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
enum aiComponent
|
enum aiComponent
|
||||||
{
|
{
|
||||||
/** Normal vectors */
|
/** Normal vectors */
|
||||||
|
#ifdef SWIG
|
||||||
|
aiComponent_NORMALS = 0x2,
|
||||||
|
#else
|
||||||
aiComponent_NORMALS = 0x2u,
|
aiComponent_NORMALS = 0x2u,
|
||||||
|
#endif
|
||||||
|
|
||||||
/** Tangents and bitangents go always together ... */
|
/** Tangents and bitangents go always together ... */
|
||||||
|
#ifdef SWIG
|
||||||
|
aiComponent_TANGENTS_AND_BITANGENTS = 0x4,
|
||||||
|
#else
|
||||||
aiComponent_TANGENTS_AND_BITANGENTS = 0x4u,
|
aiComponent_TANGENTS_AND_BITANGENTS = 0x4u,
|
||||||
|
#endif
|
||||||
|
|
||||||
/** ALL color sets
|
/** ALL color sets
|
||||||
* Use aiComponent_COLORn(N) to specify the N'th set */
|
* Use aiComponent_COLORn(N) to specify the N'th set */
|
||||||
|
@ -305,7 +313,9 @@ enum aiComponent
|
||||||
|
|
||||||
/** This value is not used. It is just there to force the
|
/** This value is not used. It is just there to force the
|
||||||
* compiler to map this enum to a 32 Bit integer. */
|
* compiler to map this enum to a 32 Bit integer. */
|
||||||
|
#ifndef SWIG
|
||||||
_aiComponent_Force32Bit = 0x9fffffff
|
_aiComponent_Force32Bit = 0x9fffffff
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
// Remove a specific color channel 'n'
|
// Remove a specific color channel 'n'
|
||||||
|
|
|
@ -79,7 +79,9 @@ enum aiLightSourceType
|
||||||
/** This value is not used. It is just there to force the
|
/** This value is not used. It is just there to force the
|
||||||
* compiler to map this enum to a 32 Bit integer.
|
* compiler to map this enum to a 32 Bit integer.
|
||||||
*/
|
*/
|
||||||
|
#ifndef SWIG
|
||||||
_aiLightSource_Force32Bit = 0x9fffffff
|
_aiLightSource_Force32Bit = 0x9fffffff
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
// ---------------------------------------------------------------------------
|
// ---------------------------------------------------------------------------
|
||||||
|
|
|
@ -100,7 +100,9 @@ enum aiTextureOp
|
||||||
* This value is not used. It forces the compiler to use at least
|
* This value is not used. It forces the compiler to use at least
|
||||||
* 32 Bit integers to represent this enum.
|
* 32 Bit integers to represent this enum.
|
||||||
*/
|
*/
|
||||||
|
#ifndef SWIG
|
||||||
_aiTextureOp_Force32Bit = 0x9fffffff
|
_aiTextureOp_Force32Bit = 0x9fffffff
|
||||||
|
#endif
|
||||||
//! @endcond
|
//! @endcond
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -134,7 +136,9 @@ enum aiTextureMapMode
|
||||||
* This value is not used. It forces the compiler to use at least
|
* This value is not used. It forces the compiler to use at least
|
||||||
* 32 Bit integers to represent this enum.
|
* 32 Bit integers to represent this enum.
|
||||||
*/
|
*/
|
||||||
|
#ifndef SWIG
|
||||||
_aiTextureMapMode_Force32Bit = 0x9fffffff
|
_aiTextureMapMode_Force32Bit = 0x9fffffff
|
||||||
|
#endif
|
||||||
//! @endcond
|
//! @endcond
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -177,7 +181,9 @@ enum aiTextureMapping
|
||||||
* This value is not used. It forces the compiler to use at least
|
* This value is not used. It forces the compiler to use at least
|
||||||
* 32 Bit integers to represent this enum.
|
* 32 Bit integers to represent this enum.
|
||||||
*/
|
*/
|
||||||
|
#ifndef SWIG
|
||||||
_aiTextureMapping_Force32Bit = 0x9fffffff
|
_aiTextureMapping_Force32Bit = 0x9fffffff
|
||||||
|
#endif
|
||||||
//! @endcond
|
//! @endcond
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -295,7 +301,9 @@ enum aiTextureType
|
||||||
* This value is not used. It forces the compiler to use at least
|
* This value is not used. It forces the compiler to use at least
|
||||||
* 32 Bit integers to represent this enum.
|
* 32 Bit integers to represent this enum.
|
||||||
*/
|
*/
|
||||||
|
#ifndef SWIG
|
||||||
_aiTextureType_Force32Bit = 0x9fffffff
|
_aiTextureType_Force32Bit = 0x9fffffff
|
||||||
|
#endif
|
||||||
//! @endcond
|
//! @endcond
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -371,7 +379,9 @@ enum aiShadingMode
|
||||||
* This value is not used. It forces the compiler to use at least
|
* This value is not used. It forces the compiler to use at least
|
||||||
* 32 Bit integers to represent this enum.
|
* 32 Bit integers to represent this enum.
|
||||||
*/
|
*/
|
||||||
|
#ifndef SWIG
|
||||||
_aiShadingMode_Force32Bit = 0x9fffffff
|
_aiShadingMode_Force32Bit = 0x9fffffff
|
||||||
|
#endif
|
||||||
//! @endcond
|
//! @endcond
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -415,7 +425,9 @@ enum aiTextureFlags
|
||||||
* This value is not used. It forces the compiler to use at least
|
* This value is not used. It forces the compiler to use at least
|
||||||
* 32 Bit integers to represent this enum.
|
* 32 Bit integers to represent this enum.
|
||||||
*/
|
*/
|
||||||
_aiTextureFlags_Force32Bit = 0x9fffffff
|
#ifndef SWIG
|
||||||
|
_aiTextureFlags_Force32Bit = 0x9fffffff
|
||||||
|
#endif
|
||||||
//! @endcond
|
//! @endcond
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -462,7 +474,9 @@ enum aiBlendMode
|
||||||
* This value is not used. It forces the compiler to use at least
|
* This value is not used. It forces the compiler to use at least
|
||||||
* 32 Bit integers to represent this enum.
|
* 32 Bit integers to represent this enum.
|
||||||
*/
|
*/
|
||||||
|
#ifndef SWIG
|
||||||
_aiBlendMode_Force32Bit = 0x9fffffff
|
_aiBlendMode_Force32Bit = 0x9fffffff
|
||||||
|
#endif
|
||||||
//! @endcond
|
//! @endcond
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -554,7 +568,9 @@ enum aiPropertyTypeInfo
|
||||||
/** This value is not used. It is just there to force the
|
/** This value is not used. It is just there to force the
|
||||||
* compiler to map this enum to a 32 Bit integer.
|
* compiler to map this enum to a 32 Bit integer.
|
||||||
*/
|
*/
|
||||||
_aiPTI_Force32Bit = 0x9fffffff
|
#ifndef SWIG
|
||||||
|
_aiPTI_Force32Bit = 0x9fffffff
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
// ---------------------------------------------------------------------------
|
// ---------------------------------------------------------------------------
|
||||||
|
|
|
@ -293,7 +293,9 @@ enum aiPrimitiveType
|
||||||
/** This value is not used. It is just here to force the
|
/** This value is not used. It is just here to force the
|
||||||
* compiler to map this enum to a 32 Bit integer.
|
* compiler to map this enum to a 32 Bit integer.
|
||||||
*/
|
*/
|
||||||
|
#ifndef SWIG
|
||||||
_aiPrimitiveType_Force32Bit = 0x9fffffff
|
_aiPrimitiveType_Force32Bit = 0x9fffffff
|
||||||
|
#endif
|
||||||
}; //! enum aiPrimitiveType
|
}; //! enum aiPrimitiveType
|
||||||
|
|
||||||
// Get the #aiPrimitiveType flag for a specific number of face indices
|
// Get the #aiPrimitiveType flag for a specific number of face indices
|
||||||
|
|
|
@ -5,6 +5,13 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Assimp.NET", "Assimp.NET\As
|
||||||
EndProject
|
EndProject
|
||||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AssimpNetDemo", "AssimpNetDemo\AssimpNetDemo.csproj", "{76085EBB-B11E-4C2B-82C7-47A781D2B4BE}"
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AssimpNetDemo", "AssimpNetDemo\AssimpNetDemo.csproj", "{76085EBB-B11E-4C2B-82C7-47A781D2B4BE}"
|
||||||
EndProject
|
EndProject
|
||||||
|
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Assimp.NET_SWIG", "Assimp.NET_SWIG\Assimp.NET_SWIG.vcproj", "{521DD721-C184-412B-AA80-0E741F2FDD4F}"
|
||||||
|
EndProject
|
||||||
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assimp.NET_SWIG_CS", "Assimp.NET_SWIG_CS\Assimp.NET_SWIG_CS.csproj", "{D88CA6D2-F511-4BAA-99FF-38E12380E58D}"
|
||||||
|
ProjectSection(ProjectDependencies) = postProject
|
||||||
|
{521DD721-C184-412B-AA80-0E741F2FDD4F} = {521DD721-C184-412B-AA80-0E741F2FDD4F}
|
||||||
|
EndProjectSection
|
||||||
|
EndProject
|
||||||
Global
|
Global
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
Debug|Any CPU = Debug|Any CPU
|
Debug|Any CPU = Debug|Any CPU
|
||||||
|
@ -35,6 +42,26 @@ Global
|
||||||
{76085EBB-B11E-4C2B-82C7-47A781D2B4BE}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
|
{76085EBB-B11E-4C2B-82C7-47A781D2B4BE}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
|
||||||
{76085EBB-B11E-4C2B-82C7-47A781D2B4BE}.Release|Mixed Platforms.Build.0 = Release|Any CPU
|
{76085EBB-B11E-4C2B-82C7-47A781D2B4BE}.Release|Mixed Platforms.Build.0 = Release|Any CPU
|
||||||
{76085EBB-B11E-4C2B-82C7-47A781D2B4BE}.Release|Win32.ActiveCfg = Release|Any CPU
|
{76085EBB-B11E-4C2B-82C7-47A781D2B4BE}.Release|Win32.ActiveCfg = Release|Any CPU
|
||||||
|
{521DD721-C184-412B-AA80-0E741F2FDD4F}.Debug|Any CPU.ActiveCfg = Debug|Win32
|
||||||
|
{521DD721-C184-412B-AA80-0E741F2FDD4F}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
|
||||||
|
{521DD721-C184-412B-AA80-0E741F2FDD4F}.Debug|Mixed Platforms.Build.0 = Debug|Win32
|
||||||
|
{521DD721-C184-412B-AA80-0E741F2FDD4F}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||||
|
{521DD721-C184-412B-AA80-0E741F2FDD4F}.Debug|Win32.Build.0 = Debug|Win32
|
||||||
|
{521DD721-C184-412B-AA80-0E741F2FDD4F}.Release|Any CPU.ActiveCfg = Release|Win32
|
||||||
|
{521DD721-C184-412B-AA80-0E741F2FDD4F}.Release|Mixed Platforms.ActiveCfg = Release|Win32
|
||||||
|
{521DD721-C184-412B-AA80-0E741F2FDD4F}.Release|Mixed Platforms.Build.0 = Release|Win32
|
||||||
|
{521DD721-C184-412B-AA80-0E741F2FDD4F}.Release|Win32.ActiveCfg = Release|Win32
|
||||||
|
{521DD721-C184-412B-AA80-0E741F2FDD4F}.Release|Win32.Build.0 = Release|Win32
|
||||||
|
{D88CA6D2-F511-4BAA-99FF-38E12380E58D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{D88CA6D2-F511-4BAA-99FF-38E12380E58D}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{D88CA6D2-F511-4BAA-99FF-38E12380E58D}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
|
||||||
|
{D88CA6D2-F511-4BAA-99FF-38E12380E58D}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
|
||||||
|
{D88CA6D2-F511-4BAA-99FF-38E12380E58D}.Debug|Win32.ActiveCfg = Debug|Any CPU
|
||||||
|
{D88CA6D2-F511-4BAA-99FF-38E12380E58D}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{D88CA6D2-F511-4BAA-99FF-38E12380E58D}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{D88CA6D2-F511-4BAA-99FF-38E12380E58D}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
|
||||||
|
{D88CA6D2-F511-4BAA-99FF-38E12380E58D}.Release|Mixed Platforms.Build.0 = Release|Any CPU
|
||||||
|
{D88CA6D2-F511-4BAA-99FF-38E12380E58D}.Release|Win32.ActiveCfg = Release|Any CPU
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
GlobalSection(SolutionProperties) = preSolution
|
GlobalSection(SolutionProperties) = preSolution
|
||||||
HideSolutionNode = FALSE
|
HideSolutionNode = FALSE
|
||||||
|
|
|
@ -49,6 +49,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
|
|
||||||
using namespace System;
|
using namespace System;
|
||||||
|
|
||||||
|
#pragma managed
|
||||||
|
|
||||||
namespace AssimpNET
|
namespace AssimpNET
|
||||||
{
|
{
|
||||||
public ref class Animation
|
public ref class Animation
|
||||||
|
@ -121,3 +123,6 @@ namespace AssimpNET
|
||||||
};
|
};
|
||||||
}//namespace
|
}//namespace
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,81 @@
|
||||||
|
/* File : example.i */
|
||||||
|
%module(directors="1") AssimpNET_SWIG
|
||||||
|
%{
|
||||||
|
//#include "..\..\..\include\aiAssert.h"
|
||||||
|
#include "..\..\..\include\aiDefines.h"
|
||||||
|
#include "..\..\..\include\aiConfig.h"
|
||||||
|
#include "..\..\..\include\aiTypes.h"
|
||||||
|
#include "..\..\..\include\aiVersion.h"
|
||||||
|
#include "..\..\..\include\aiPostProcess.h"
|
||||||
|
#include "..\..\..\include\aiVector2D.h"
|
||||||
|
#include "..\..\..\include\aiVector3D.h"
|
||||||
|
#include "..\..\..\include\aiMatrix3x3.h"
|
||||||
|
#include "..\..\..\include\aiMatrix4x4.h"
|
||||||
|
#include "..\..\..\include\aiCamera.h"
|
||||||
|
#include "..\..\..\include\aiLight.h"
|
||||||
|
#include "..\..\..\include\aiAnim.h"
|
||||||
|
#include "..\..\..\include\aiMesh.h"
|
||||||
|
#include "..\..\..\include\aiFileIO.h"
|
||||||
|
//#include "..\..\..\include\aiMaterial.h"
|
||||||
|
#include "..\..\..\include\aiQuaternion.h"
|
||||||
|
#include "..\..\..\include\aiScene.h"
|
||||||
|
#include "..\..\..\include\aiTexture.h"
|
||||||
|
#include "..\..\..\include\assimp.hpp"
|
||||||
|
#include "..\..\..\include\IOSystem.h"
|
||||||
|
#include "..\..\..\include\IOStream.h"
|
||||||
|
#include "..\..\..\include\Logger.h"
|
||||||
|
#include "..\..\..\include\LogStream.h"
|
||||||
|
#include "..\..\..\include\NullLogger.h"
|
||||||
|
%}
|
||||||
|
|
||||||
|
#define C_STRUCT
|
||||||
|
#define C_ENUM
|
||||||
|
#define ASSIMP_API
|
||||||
|
#define PACK_STRUCT
|
||||||
|
|
||||||
|
%rename(__add__) operator+;
|
||||||
|
%rename(__addnset__) operator+=;
|
||||||
|
%rename(__sub__) operator-;
|
||||||
|
%rename(__subnset__) operator-=;
|
||||||
|
%rename(__mul__) operator*;
|
||||||
|
%rename(__mulnset__) operator*=;
|
||||||
|
%rename(__div__) operator/;
|
||||||
|
%rename(__divnset__) operator/=;
|
||||||
|
%rename(__equal__) operator==;
|
||||||
|
%rename(__nequal__) operator!=;
|
||||||
|
%rename(__idx__) operator[];
|
||||||
|
%rename(__set__) operator=;
|
||||||
|
%rename(__greater__) operator>;
|
||||||
|
%rename(__smaller__) operator<;
|
||||||
|
|
||||||
|
%include "std_string.i"
|
||||||
|
|
||||||
|
//%include "..\..\..\include\aiAssert.h"
|
||||||
|
%include "..\..\..\include\aiDefines.h"
|
||||||
|
%include "..\..\..\include\aiConfig.h"
|
||||||
|
%include "..\..\..\include\aiTypes.h"
|
||||||
|
%include "..\..\..\include\aiVersion.h"
|
||||||
|
%include "..\..\..\include\aiPostProcess.h"
|
||||||
|
%include "..\..\..\include\aiVector2D.h"
|
||||||
|
%include "..\..\..\include\aiVector3D.h"
|
||||||
|
%include "..\..\..\include\aiMatrix3x3.h"
|
||||||
|
%include "..\..\..\include\aiMatrix4x4.h"
|
||||||
|
%include "..\..\..\include\aiCamera.h"
|
||||||
|
%include "..\..\..\include\aiLight.h"
|
||||||
|
%include "..\..\..\include\aiAnim.h"
|
||||||
|
%include "..\..\..\include\aiMesh.h"
|
||||||
|
%include "..\..\..\include\aiFileIO.h"
|
||||||
|
//%include "..\..\..\include\aiMaterial.h"
|
||||||
|
%include "..\..\..\include\aiQuaternion.h"
|
||||||
|
%include "..\..\..\include\aiScene.h"
|
||||||
|
%include "..\..\..\include\aiTexture.h"
|
||||||
|
%include "..\..\..\include\assimp.hpp"
|
||||||
|
%include "..\..\..\include\IOSystem.h"
|
||||||
|
%include "..\..\..\include\IOStream.h"
|
||||||
|
%include "..\..\..\include\Logger.h"
|
||||||
|
%include "..\..\..\include\LogStream.h"
|
||||||
|
%include "..\..\..\include\NullLogger.h"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue