adding native pointer to manganed classes

implementing c'tors and d'tors for managend classes (execept logging system)
rename some files

git-svn-id: https://assimp.svn.sourceforge.net/svnroot/assimp/trunk@481 67173fc5-114c-0410-ac8e-9d2fd5bffc1f
pull/1/head
rave3d 2009-09-24 14:44:21 +00:00
parent c89107a117
commit bbf5a32e6c
59 changed files with 713 additions and 180 deletions

View File

@ -6,12 +6,23 @@ namespace AssimpNET
Animation::Animation(void) Animation::Animation(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiAnimation();
}
Animation::Animation(aiAnimation* native)
{
this->p_native = native;
} }
Animation::~Animation(void) Animation::~Animation(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
}
aiAnimation* Animation::getNative()
{
return this->p_native;
} }
}//namespace }//namespace

View File

@ -41,8 +41,12 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managed includes
#include "NodeAnim.h" #include "NodeAnim.h"
//native includes
#include "aiAnim.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -51,6 +55,7 @@ namespace AssimpNET
{ {
public: public:
Animation(void); Animation(void);
Animation(aiAnimation* native);
~Animation(void); ~Animation(void);
property array<NodeAnim^>^ mAnimChannels property array<NodeAnim^>^ mAnimChannels
@ -79,6 +84,10 @@ namespace AssimpNET
void set(String^ value){throw gcnew System::NotImplementedException();} void set(String^ value){throw gcnew System::NotImplementedException();}
} }
aiAnimation* getNative();
private:
aiAnimation *p_native;
}; };
}//namespace }//namespace

View File

@ -42,6 +42,7 @@
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="..\..\..\include"
PreprocessorDefinitions="WIN32;_DEBUG" PreprocessorDefinitions="WIN32;_DEBUG"
RuntimeLibrary="3" RuntimeLibrary="3"
WarningLevel="3" WarningLevel="3"
@ -58,8 +59,9 @@
/> />
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="$(NoInherit)" AdditionalDependencies="assimp.lib $(NOINHERIT)"
LinkIncremental="2" LinkIncremental="2"
AdditionalLibraryDirectories="..\..\..\lib\assimp_$(ConfigurationName)_$(PlatformName)"
GenerateDebugInformation="true" GenerateDebugInformation="true"
AssemblyDebug="1" AssemblyDebug="1"
TargetMachine="1" TargetMachine="1"
@ -315,10 +317,6 @@
RelativePath=".\Color4D.h" RelativePath=".\Color4D.h"
> >
</File> </File>
<File
RelativePath=".\DefaultLogger.h"
>
</File>
<File <File
RelativePath=".\Enums.h" RelativePath=".\Enums.h"
> >
@ -331,26 +329,10 @@
RelativePath=".\Importer.h" RelativePath=".\Importer.h"
> >
</File> </File>
<File
RelativePath=".\IOStream.h"
>
</File>
<File
RelativePath=".\IOSystem.h"
>
</File>
<File <File
RelativePath=".\Light.h" RelativePath=".\Light.h"
> >
</File> </File>
<File
RelativePath=".\Logger.h"
>
</File>
<File
RelativePath=".\LogStream.h"
>
</File>
<File <File
RelativePath=".\Material.h" RelativePath=".\Material.h"
> >
@ -367,10 +349,30 @@
RelativePath=".\Matrix4x4.h" RelativePath=".\Matrix4x4.h"
> >
</File> </File>
<File
RelativePath=".\mDefaultLogger.h"
>
</File>
<File <File
RelativePath=".\Mesh.h" RelativePath=".\Mesh.h"
> >
</File> </File>
<File
RelativePath=".\mIOStream.h"
>
</File>
<File
RelativePath=".\mIOSystem.h"
>
</File>
<File
RelativePath=".\mLogger.h"
>
</File>
<File
RelativePath=".\mLogStream.h"
>
</File>
<File <File
RelativePath=".\Node.h" RelativePath=".\Node.h"
> >

View File

@ -7,17 +7,28 @@ namespace AssimpNET
Bone::Bone(void) Bone::Bone(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiBone();
} }
Bone::Bone(const Bone^ other) Bone::Bone(Bone% other)
{ {
throw gcnew System::NotImplementedException(); this->p_native = other.getNative();
}
Bone::Bone(aiBone* native)
{
this->p_native = native;
} }
Bone::~Bone(void) Bone::~Bone(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
}
aiBone* Bone::getNative()
{
return this->p_native;
} }
}//namespace }//namespace

View File

@ -41,9 +41,14 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managed includes
#include "Matrix4x4.h" #include "Matrix4x4.h"
#include "VertexWeight.h" #include "VertexWeight.h"
//native includes
#include "aiMesh.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -52,7 +57,8 @@ namespace AssimpNET
{ {
public: public:
Bone(void); Bone(void);
Bone(const Bone^ other); Bone(Bone% other);
Bone(aiBone* native);
~Bone(void); ~Bone(void);
property String^ mName property String^ mName
@ -75,5 +81,9 @@ namespace AssimpNET
array<VertexWeight^>^ get(){throw gcnew System::NotImplementedException();} array<VertexWeight^>^ get(){throw gcnew System::NotImplementedException();}
void set(array<VertexWeight^>^ value){throw gcnew System::NotImplementedException();} void set(array<VertexWeight^>^ value){throw gcnew System::NotImplementedException();}
} }
aiBone* getNative();
private:
aiBone *p_native;
}; };
}//namespace }//namespace

View File

@ -6,12 +6,18 @@ namespace AssimpNET
Camera::Camera(void) Camera::Camera(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiCamera();
}
Camera::Camera(aiCamera* native)
{
this->p_native = native;
} }
Camera::~Camera(void) Camera::~Camera(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
void Camera::GetCameraMatrix(Matrix4x4^ out) void Camera::GetCameraMatrix(Matrix4x4^ out)
@ -19,4 +25,9 @@ void Camera::GetCameraMatrix(Matrix4x4^ out)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiCamera* Camera::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -41,9 +41,13 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managed includes
#include "Matrix4x4.h" #include "Matrix4x4.h"
#include "Vector3D.h" #include "Vector3D.h"
//native includes
#include "aiCamera.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -52,6 +56,7 @@ namespace AssimpNET
{ {
public: public:
Camera(void); Camera(void);
Camera(aiCamera* native);
~Camera(void); ~Camera(void);
void GetCameraMatrix(Matrix4x4^ out); void GetCameraMatrix(Matrix4x4^ out);
@ -99,5 +104,9 @@ namespace AssimpNET
void set(String^ value){throw gcnew System::NotImplementedException();} void set(String^ value){throw gcnew System::NotImplementedException();}
} }
aiCamera* getNative();
private:
aiCamera *p_native;
}; };
}//namespace }//namespace

View File

@ -6,17 +6,22 @@ namespace AssimpNET
Color3D::Color3D(void) Color3D::Color3D(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiColor3D();
} }
Color3D::Color3D(const Color3D^ other) Color3D::Color3D(Color3D% other)
{ {
throw gcnew System::NotImplementedException(); this->p_native = other.getNative();
} }
Color3D::Color3D(float _r, float _g, float _b) Color3D::Color3D(float _r, float _g, float _b)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiColor3D(_r, _g, _b);
}
Color3D::Color3D(aiColor3D* native)
{
this->p_native = native;
} }
bool Color3D::IsBlack() bool Color3D::IsBlack()
@ -59,4 +64,9 @@ float^ Color3D::operator[] (unsigned int i)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiColor3D* Color3D::getNative()
{
return this->p_native;
}
} }

View File

@ -1,5 +1,8 @@
#pragma once #pragma once
//native includes
#include "aiTypes.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -8,8 +11,9 @@ namespace AssimpNET
{ {
public: public:
Color3D(void); Color3D(void);
Color3D(const Color3D^ other); Color3D(Color3D% other);
Color3D(float _r, float _g, float _b); Color3D(float _r, float _g, float _b);
Color3D(aiColor3D* native);
bool IsBlack(); bool IsBlack();
bool operator != (const Color3D^ other); bool operator != (const Color3D^ other);
@ -39,6 +43,10 @@ namespace AssimpNET
void set(float value){throw gcnew System::NotImplementedException();} void set(float value){throw gcnew System::NotImplementedException();}
} }
aiColor3D* getNative();
private:
aiColor3D *p_native;
}; };
} }

View File

@ -6,17 +6,22 @@ namespace AssimpNET
Color4D::Color4D(void) Color4D::Color4D(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiColor4D();
} }
Color4D::Color4D(const Color4D^ other) Color4D::Color4D(Color4D% other)
{ {
throw gcnew System::NotImplementedException(); this->p_native = other.getNative();
} }
Color4D::Color4D(float _r, float _g, float _b, float _a) Color4D::Color4D(float _r, float _g, float _b, float _a)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiColor4D(_r, _g, _b, _a);
}
Color4D::Color4D(aiColor4D *native)
{
this->p_native = native;
} }
bool Color4D::IsBlack() bool Color4D::IsBlack()
@ -39,4 +44,9 @@ float Color4D::operator[] (unsigned int i)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiColor4D* Color4D::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -1,5 +1,8 @@
#pragma once #pragma once
//native includes
#include "aiTypes.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -9,8 +12,9 @@ namespace AssimpNET
{ {
public: public:
Color4D(void); Color4D(void);
Color4D (const Color4D^ other); Color4D (Color4D% other);
Color4D (float _r, float _g, float _b, float _a); Color4D (float _r, float _g, float _b, float _a);
Color4D (aiColor4D* native);
bool IsBlack (); bool IsBlack ();
bool operator!= (const Color4D^ other); bool operator!= (const Color4D^ other);
@ -42,6 +46,9 @@ namespace AssimpNET
void set(float value){throw gcnew System::NotImplementedException();} void set(float value){throw gcnew System::NotImplementedException();}
} }
aiColor4D* getNative();
private:
aiColor4D *p_native;
}; };

View File

@ -1,52 +1,62 @@
#include "DefaultLogger.h" #include "mDefaultLogger.h"
namespace AssimpNET namespace AssimpNET
{ {
DefaultLogger::DefaultLogger(void) AssimpNET::DefaultLogger::DefaultLogger(void)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
DefaultLogger::~DefaultLogger(void) AssimpNET::DefaultLogger::DefaultLogger(Assimp::DefaultLogger* native)
{
this->p_native = native;
}
AssimpNET::DefaultLogger::~DefaultLogger(void)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
bool DefaultLogger::attachStream(LogStream^ stream, unsigned int severity) bool AssimpNET::DefaultLogger::attachStream(LogStream^ stream, unsigned int severity)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
bool DefaultLogger::detachStream(LogStream^ stream, unsigned int severity) bool AssimpNET::DefaultLogger::detachStream(LogStream^ stream, unsigned int severity)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
Logger^ DefaultLogger::create(const String^ name, LogSeverity severity, unsigned int defStream, IOSystem^ io) Logger^ AssimpNET::DefaultLogger::create(const String^ name, LogSeverity severity, unsigned int defStream, IOSystem^ io)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
Logger^ DefaultLogger::get() Logger^ AssimpNET::DefaultLogger::get()
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
bool DefaultLogger::isNullLogger() bool AssimpNET::DefaultLogger::isNullLogger()
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
void DefaultLogger::kill() void AssimpNET::DefaultLogger::kill()
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
void DefaultLogger::set(Logger^ logger) void AssimpNET::DefaultLogger::set(Logger^ logger)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
Assimp::DefaultLogger* AssimpNET::DefaultLogger::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -6,17 +6,23 @@ namespace AssimpNET
Face::Face(void) Face::Face(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiFace();
} }
Face::Face(const Face^ other) Face::Face(Face% other)
{ {
throw gcnew System::NotImplementedException(); this->p_native = other.getNative();
}
Face::Face(aiFace* native)
{
this->p_native = native;
} }
Face::~Face(void) Face::~Face(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
bool Face::operator != (const Face^ other) bool Face::operator != (const Face^ other)
@ -34,5 +40,10 @@ bool Face::operator == (const Face^ other)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiFace* Face::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -41,13 +41,17 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//native includes
#include "aiMesh.h"
namespace AssimpNET namespace AssimpNET
{ {
public ref class Face public ref class Face
{ {
public: public:
Face(void); Face(void);
Face(const Face^ other); Face(Face% other);
Face(aiFace* native);
~Face(void); ~Face(void);
bool operator != (const Face^ other); bool operator != (const Face^ other);
@ -65,5 +69,9 @@ namespace AssimpNET
unsigned int get(){throw gcnew System::NotImplementedException();} unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();} void set(unsigned int value){throw gcnew System::NotImplementedException();}
} }
aiFace* getNative();
private:
aiFace *p_native;
}; };
}//namespace }//namespace

View File

@ -1,5 +1,5 @@
#include "IOStream.h" #include "mIOStream.h"
namespace AssimpNET namespace AssimpNET
{ {

View File

@ -1,5 +1,5 @@
#include "IOSystem.h" #include "mIOSystem.h"
namespace AssimpNET namespace AssimpNET
{ {
@ -9,9 +9,15 @@ IOSystem::IOSystem(void)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
IOSystem::IOSystem(Assimp::IOSystem* native)
{
this->p_native = native;
}
IOSystem::~IOSystem(void) IOSystem::~IOSystem(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
bool IOSystem::ComparePaths (const String^ one, const String^ second) bool IOSystem::ComparePaths (const String^ one, const String^ second)
@ -34,4 +40,9 @@ IOStream^ IOSystem::Open(const String^ pFile, const String^ pMode)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
Assimp::IOSystem* IOSystem::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -6,27 +6,33 @@ namespace AssimpNET
Importer::Importer(void) Importer::Importer(void)
{ {
throw gcnew System::NotImplementedException(); p_native = new Assimp::Importer();
} }
Importer::Importer(const Importer^ other) Importer::Importer(Importer% other)
{ {
throw gcnew System::NotImplementedException(); p_native = other.getNative();
}
Importer::Importer(Assimp::Importer* native)
{
this->p_native = native;
} }
Importer::~Importer(void) Importer::~Importer(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
void Importer::FreeScene() void Importer::FreeScene()
{ {
throw gcnew System::NotImplementedException(); p_native->FreeScene();
} }
array<char>^ Importer::GetErrorString() System::String^ Importer::GetErrorString()
{ {
throw gcnew System::NotImplementedException(); return gcnew System::String(p_native->GetErrorString());
} }
void Importer::GetExtensionsList(String^ extensions) void Importer::GetExtensionsList(String^ extensions)
@ -49,19 +55,22 @@ Scene^ Importer::getOrphanedScene( )
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
float Importer::GetPropertyFloat(array<char>^ propName) float Importer::GetPropertyFloat(String^ propName)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
//return p_native->GetPropertyFloat(propName->ToCharArray());
} }
int Importer::GetPropertyInt(array<char>^ propName) int Importer::GetPropertyInt(String^ propName)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
//return p_native->GetPropertyInteger((IntPtr)propName->ToCharArray());
} }
String^ Importer::GetPrpertyString(array<char>^ propName) String^ Importer::GetPrpertyString(String^ propName)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
//return System::String(p_native->GetPropertyString(propName->ToCharArray()));
} }
Scene^ Importer::getScene() Scene^ Importer::getScene()
@ -71,12 +80,7 @@ Scene^ Importer::getScene()
bool Importer::IsDefaultIOHandler() bool Importer::IsDefaultIOHandler()
{ {
throw gcnew System::NotImplementedException(); return p_native->IsDefaultIOHandler();
}
bool Importer::IsExtensionSupported(array<char>^ extension)
{
throw gcnew System::NotImplementedException();
} }
bool Importer::IsExtensionSupported(String^ extension) bool Importer::IsExtensionSupported(String^ extension)
@ -84,11 +88,6 @@ bool Importer::IsExtensionSupported(String^ extension)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
Scene^ Importer::ReadFile(array<char>^ fileName, unsigned int flags)
{
throw gcnew System::NotImplementedException();
}
Scene^ Importer::ReadFile(String^ fileName, unsigned int flags) Scene^ Importer::ReadFile(String^ fileName, unsigned int flags)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
@ -96,7 +95,7 @@ Scene^ Importer::ReadFile(String^ fileName, unsigned int flags)
void Importer::SetExtraVerbose(bool verbose) void Importer::SetExtraVerbose(bool verbose)
{ {
throw gcnew System::NotImplementedException(); p_native->SetExtraVerbose(verbose);
} }
void Importer::SetIOHanlder(IOSystem^ ioHandler) void Importer::SetIOHanlder(IOSystem^ ioHandler)
@ -104,24 +103,29 @@ void Importer::SetIOHanlder(IOSystem^ ioHandler)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
void Importer::SetPropertyFloat(array<char>^ propName, float value) void Importer::SetPropertyFloat(String^ propName, float value)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
void Importer::SetPropertyInt(array<char>^ propName, int value) void Importer::SetPropertyInt(String^ propName, int value)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
void Importer::SetPrpertyString(array<char>^ propName, String^ value) void Importer::SetPrpertyString(String^ propName, String^ value)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
bool Importer::ValidateFlags(unsigned int flags) bool Importer::ValidateFlags(unsigned int flags)
{ {
throw gcnew System::NotImplementedException(); return p_native->ValidateFlags(flags);
}
Assimp::Importer* Importer::getNative()
{
return this->p_native;
} }

View File

@ -41,9 +41,13 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
#include "IOSystem.h" //managed includes
#include "mIOSystem.h"
#include "Scene.h" #include "Scene.h"
//native includes
#include "assimp.hpp"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -103,30 +107,33 @@ namespace AssimpNET
{ {
public: public:
Importer(void); Importer(void);
Importer(const Importer^ other); Importer(Importer% other);
Importer(Assimp::Importer* native);
~Importer(void); ~Importer(void);
void FreeScene(); void FreeScene();
array<char>^ GetErrorString(); System::String^ GetErrorString();
void GetExtensionsList(String^ extensions); void GetExtensionsList(String^ extensions);
IOSystem^ GetIOHandler(); IOSystem^ GetIOHandler();
void GetMemoryRequrements(aiMemoryInfo^ in); void GetMemoryRequrements(aiMemoryInfo^ in);
Scene^ getOrphanedScene( ); Scene^ getOrphanedScene( );
float GetPropertyFloat(array<char>^ propName); float GetPropertyFloat(String^ propName);
int GetPropertyInt(array<char>^ propName); int GetPropertyInt(String^ propName);
String^ GetPrpertyString(array<char>^ propName); String^ GetPrpertyString(String^ propName);
Scene^ getScene(); Scene^ getScene();
bool IsDefaultIOHandler(); bool IsDefaultIOHandler();
bool IsExtensionSupported(array<char>^ extension);
bool IsExtensionSupported(String^ extension); bool IsExtensionSupported(String^ extension);
Scene^ ReadFile(array<char>^ fileName, unsigned int flags);
Scene^ ReadFile(String^ fileName, unsigned int flags); Scene^ ReadFile(String^ fileName, unsigned int flags);
void SetExtraVerbose(bool verbose); void SetExtraVerbose(bool verbose);
void SetIOHanlder(IOSystem^ ioHandler); void SetIOHanlder(IOSystem^ ioHandler);
void SetPropertyFloat(array<char>^ propName, float value); void SetPropertyFloat(String^ propName, float value);
void SetPropertyInt(array<char>^ propName, int value); void SetPropertyInt(String^ propName, int value);
void SetPrpertyString(array<char>^ propName, String^ value); void SetPrpertyString(String^ propName, String^ value);
bool ValidateFlags(unsigned int flags); bool ValidateFlags(unsigned int flags);
Assimp::Importer* getNative();
private:
Assimp::Importer *p_native;
}; };
}//namespace }//namespace

View File

@ -6,12 +6,23 @@ namespace AssimpNET
Light::Light(void) Light::Light(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiLight();
}
Light::Light(aiLight* native)
{
this->p_native = native;
} }
Light::~Light(void) Light::~Light(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
}
aiLight* Light::getNative()
{
return this->p_native;
} }
}//namespace }//namespace

View File

@ -41,9 +41,13 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managed includes
#include "Vector3D.h" #include "Vector3D.h"
#include "Color3D.h" #include "Color3D.h"
//natvie includes
#include "aiLight.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -61,6 +65,7 @@ namespace AssimpNET
{ {
public: public:
Light(void); Light(void);
Light(aiLight* native);
~Light(void); ~Light(void);
property float AngleInnerCone property float AngleInnerCone
@ -134,5 +139,9 @@ namespace AssimpNET
LightSourceType get(){throw gcnew System::NotImplementedException();} LightSourceType get(){throw gcnew System::NotImplementedException();}
void set(LightSourceType value){throw gcnew System::NotImplementedException();} void set(LightSourceType value){throw gcnew System::NotImplementedException();}
} }
aiLight* getNative();
private:
aiLight *p_native;
}; };
}//namespace }//namespace

View File

@ -1,5 +1,5 @@
#include "LogStream.h" #include "mLogStream.h"
namespace AssimpNET namespace AssimpNET
{ {
@ -9,9 +9,15 @@ LogStream::LogStream(void)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
LogStream::LogStream(Assimp::LogStream* native)
{
this->p_native = native;
}
LogStream::~LogStream(void) LogStream::~LogStream(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
LogStream^ LogStream::createDefaultStream(DefaulLogStreams streams, array<char>^ name, IOSystem^ io) LogStream^ LogStream::createDefaultStream(DefaulLogStreams streams, array<char>^ name, IOSystem^ io)
@ -19,4 +25,9 @@ LogStream^ LogStream::createDefaultStream(DefaulLogStreams streams, array<char>^
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
Assimp::LogStream* LogStream::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -1,5 +1,5 @@
#include "Logger.h" #include "mLogger.h"
namespace AssimpNET namespace AssimpNET
{ {
@ -9,14 +9,20 @@ Logger::Logger(void)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
Logger::Logger(LogSeverity) Logger::Logger(LogSeverity severity)
{ {
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
Logger::Logger(Assimp::Logger* native)
{
this->p_native = native;
}
Logger::~Logger(void) Logger::~Logger(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
void Logger::debug (const String^ message) void Logger::debug (const String^ message)
@ -49,4 +55,9 @@ void Logger::warn(const String^ message)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
Assimp::Logger* Logger::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -6,12 +6,18 @@ namespace AssimpNET
Material::Material(void) Material::Material(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiMaterial();
}
Material::Material(aiMaterial* native)
{
this->p_native = native;
} }
Material::~Material(void) Material::~Material(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
generic<typename T> generic<typename T>
@ -32,4 +38,9 @@ aiReturn Material::GetTexture(TextureType type, unsigned int index, String^ path
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiMaterial* Material::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -41,10 +41,14 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managed includes
#include "Enums.h" #include "Enums.h"
#include "MaterialProperty.h" #include "MaterialProperty.h"
#include "Texture.h" #include "Texture.h"
//native includes
#include "aiMaterial.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -53,6 +57,7 @@ namespace AssimpNET
{ {
public: public:
Material(void); Material(void);
Material(aiMaterial* native);
~Material(void); ~Material(void);
generic<typename T> generic<typename T>
@ -82,5 +87,9 @@ namespace AssimpNET
void set(array<MaterialProperty^>^ value){throw gcnew System::NotImplementedException();} void set(array<MaterialProperty^>^ value){throw gcnew System::NotImplementedException();}
} }
aiMaterial* getNative();
private:
aiMaterial *p_native;
}; };
}//namespace }//namespace

View File

@ -6,12 +6,23 @@ namespace AssimpNET
MaterialProperty::MaterialProperty(void) MaterialProperty::MaterialProperty(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiMaterialProperty();
}
MaterialProperty::MaterialProperty(aiMaterialProperty* native)
{
this->p_native = native;
} }
MaterialProperty::~MaterialProperty(void) MaterialProperty::~MaterialProperty(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
}
aiMaterialProperty* MaterialProperty::getNative()
{
return this->p_native;
} }
}//namespace }//namespace

View File

@ -41,6 +41,9 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//native includes
#include "aiMaterial.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -58,6 +61,7 @@ namespace AssimpNET
{ {
public: public:
MaterialProperty(void); MaterialProperty(void);
MaterialProperty(aiMaterialProperty* native);
~MaterialProperty(void); ~MaterialProperty(void);
property array<char>^ mData property array<char>^ mData
@ -95,5 +99,9 @@ namespace AssimpNET
PropertyTypeInfo get(){throw gcnew System::NotImplementedException();} PropertyTypeInfo get(){throw gcnew System::NotImplementedException();}
void set(PropertyTypeInfo value){throw gcnew System::NotImplementedException();} void set(PropertyTypeInfo value){throw gcnew System::NotImplementedException();}
} }
aiMaterialProperty* getNative();
private:
aiMaterialProperty *p_native;
}; };
}//namespace }//namespace

View File

@ -6,24 +6,30 @@ namespace AssimpNET
Matrix3x3::Matrix3x3(void) Matrix3x3::Matrix3x3(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiMatrix3x3;
} }
Matrix3x3::Matrix3x3(const Matrix4x4^ matrix) Matrix3x3::Matrix3x3(Matrix4x4^ matrix)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiMatrix3x3(*(matrix->getNative()));
} }
Matrix3x3::Matrix3x3( float _a1, float _a2, float _a3, Matrix3x3::Matrix3x3( float _a1, float _a2, float _a3,
float _b1, float _b2, float _b3, float _b1, float _b2, float _b3,
float _c1, float _c2, float _c3) float _c1, float _c2, float _c3)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiMatrix3x3(_a1, _a2, _a3, _b1, _b2, _b3, _c1, _c2, _c3);
}
Matrix3x3::Matrix3x3(aiMatrix3x3* native)
{
this->p_native = native;
} }
Matrix3x3::~Matrix3x3(void) Matrix3x3::~Matrix3x3(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
float Matrix3x3::Determinant() float Matrix3x3::Determinant()
@ -86,5 +92,10 @@ Matrix3x3^ Matrix3x3::Translation(const Vector2D^ v, Matrix3x3^ out)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiMatrix3x3* Matrix3x3::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -41,20 +41,26 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managed includes
#include "Vector3D.h" #include "Vector3D.h"
#include "Vector2D.h" #include "Vector2D.h"
#include "Matrix4x4.h" #include "Matrix4x4.h"
//native includes
#include "aiVector3D.h"
#include "aiMatrix3x3.h"
namespace AssimpNET namespace AssimpNET
{ {
public ref class Matrix3x3 public ref class Matrix3x3
{ {
public: public:
Matrix3x3(void); Matrix3x3(void);
Matrix3x3(const Matrix4x4^ matrix); Matrix3x3(Matrix4x4^ matrix);
Matrix3x3( float _a1, float _a2, float _a3, Matrix3x3( float _a1, float _a2, float _a3,
float _b1, float _b2, float _b3, float _b1, float _b2, float _b3,
float _c1, float _c2, float _c3); float _c1, float _c2, float _c3);
Matrix3x3(aiMatrix3x3* native);
~Matrix3x3(void); ~Matrix3x3(void);
float Determinant(); float Determinant();
@ -125,5 +131,9 @@ namespace AssimpNET
void set(float value){throw gcnew System::NotImplementedException();} void set(float value){throw gcnew System::NotImplementedException();}
} }
aiMatrix3x3* getNative();
private:
aiMatrix3x3 *p_native;
}; };
}//namespace }//namespace

View File

@ -6,12 +6,12 @@ namespace AssimpNET
Matrix4x4::Matrix4x4(void) Matrix4x4::Matrix4x4(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiMatrix4x4();
} }
Matrix4x4::Matrix4x4(const Matrix3x3 other) Matrix4x4::Matrix4x4(Matrix3x3^ other)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiMatrix4x4(*(other->getNative()));
} }
Matrix4x4::Matrix4x4( float _a1, float _a2, float _a3, float _a4, Matrix4x4::Matrix4x4( float _a1, float _a2, float _a3, float _a4,
@ -19,12 +19,21 @@ Matrix4x4::Matrix4x4( float _a1, float _a2, float _a3, float _a4,
float _c1, float _c2, float _c3, float _c4, float _c1, float _c2, float _c3, float _c4,
float _d1, float _d2, float _d3, float _d4) float _d1, float _d2, float _d3, float _d4)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiMatrix4x4( _a1, _a2, _a3, _a4,
_b1, _b2, _b3, _b4,
_c1, _c2, _c3, _c4,
_d1, _c2, _d3, _d4);
}
Matrix4x4::Matrix4x4(aiMatrix4x4* native)
{
this->p_native = native;
} }
Matrix4x4::~Matrix4x4(void) Matrix4x4::~Matrix4x4(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
void Matrix4x4::Decompose(Vector3D^ scaling, Quaternion^ rotation, Vector3D^ position) void Matrix4x4::Decompose(Vector3D^ scaling, Quaternion^ rotation, Vector3D^ position)
@ -127,4 +136,9 @@ Matrix4x4^ Matrix4x4::Translation (const Vector3D^ v, Matrix4x4^ out)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiMatrix4x4* Matrix4x4::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -45,7 +45,9 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "Vector3D.h" #include "Vector3D.h"
#include "Quaternion.h" #include "Quaternion.h"
//native includes
#include "aiVector3D.h"
#include "aiMatrix4x4.h"
namespace AssimpNET namespace AssimpNET
{ {
@ -53,11 +55,12 @@ namespace AssimpNET
{ {
public: public:
Matrix4x4(void); Matrix4x4(void);
Matrix4x4(const Matrix3x3 other); Matrix4x4(Matrix3x3^ other);
Matrix4x4( float _a1, float _a2, float _a3, float _a4, Matrix4x4( float _a1, float _a2, float _a3, float _a4,
float _b1, float _b2, float _b3, float _b4, float _b1, float _b2, float _b3, float _b4,
float _c1, float _c2, float _c3, float _c4, float _c1, float _c2, float _c3, float _c4,
float _d1, float _d2, float _d3, float _d4); float _d1, float _d2, float _d3, float _d4);
Matrix4x4(aiMatrix4x4* native);
~Matrix4x4(void); ~Matrix4x4(void);
void Decompose(Vector3D^ scaling, Quaternion^ rotation, Vector3D^ position); void Decompose(Vector3D^ scaling, Quaternion^ rotation, Vector3D^ position);
@ -180,5 +183,9 @@ namespace AssimpNET
void set(float value){throw gcnew System::NotImplementedException();} void set(float value){throw gcnew System::NotImplementedException();}
} }
aiMatrix4x4* getNative();
private:
aiMatrix4x4 *p_native;
}; };
}//namespace }//namespace

View File

@ -6,12 +6,18 @@ namespace AssimpNET
Mesh::Mesh(void) Mesh::Mesh(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiMesh();
}
Mesh::Mesh(aiMesh* native)
{
this->p_native = native;
} }
Mesh::~Mesh(void) Mesh::~Mesh(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
unsigned int Mesh::GetNumColorChannels() unsigned int Mesh::GetNumColorChannels()
@ -59,4 +65,9 @@ bool Mesh::HasVertexColors()
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiMesh* Mesh::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -41,11 +41,15 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managed includes
#include "Vector3D.h" #include "Vector3D.h"
#include "Bone.h" #include "Bone.h"
#include "Color4D.h" #include "Color4D.h"
#include "Face.h" #include "Face.h"
//native includes
#include "aiMesh.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -54,6 +58,7 @@ namespace AssimpNET
{ {
public: public:
Mesh(void); Mesh(void);
Mesh(aiMesh* native);
~Mesh(void); ~Mesh(void);
unsigned int GetNumColorChannels(); unsigned int GetNumColorChannels();
@ -150,5 +155,9 @@ namespace AssimpNET
void set(array<Vector3D^>^ value){throw gcnew System::NotImplementedException();} void set(array<Vector3D^>^ value){throw gcnew System::NotImplementedException();}
} }
aiMesh* getNative();
private:
aiMesh *p_native;
}; };
}//namespace }//namespace

View File

@ -6,12 +6,18 @@ namespace AssimpNET
Node::Node(void) Node::Node(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiNode();
}
Node::Node(aiNode* native)
{
this->p_native = native;
} }
Node::~Node(void) Node::~Node(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
Node^ Node::findNode(array<char>^ name) Node^ Node::findNode(array<char>^ name)
@ -24,4 +30,9 @@ Node^ Node::findNode(const String^ name)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiNode* Node::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -41,8 +41,12 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managed includes
#include "Matrix4x4.h" #include "Matrix4x4.h"
//native inclueds
#include "aiScene.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -51,6 +55,7 @@ namespace AssimpNET
{ {
public: public:
Node(void); Node(void);
Node(aiNode* native);
~Node(void); ~Node(void);
Node^ findNode(array<char>^ name); Node^ findNode(array<char>^ name);
@ -98,5 +103,9 @@ namespace AssimpNET
void set(Node^ value){throw gcnew System::NotImplementedException();} void set(Node^ value){throw gcnew System::NotImplementedException();}
} }
aiNode* getNative();
private:
aiNode *p_native;
}; };
}//namespace }//namespace

View File

@ -6,12 +6,23 @@ namespace AssimpNET
NodeAnim::NodeAnim(void) NodeAnim::NodeAnim(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiNodeAnim();
}
NodeAnim::NodeAnim(aiNodeAnim* native)
{
this->p_native = native;
} }
NodeAnim::~NodeAnim(void) NodeAnim::~NodeAnim(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
}
aiNodeAnim* NodeAnim::getNative()
{
return this->p_native;
} }
}//namespace }//namespace

View File

@ -41,9 +41,13 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managend includes
#include "VectorKey.h" #include "VectorKey.h"
#include "QuatKey.h" #include "QuatKey.h"
//native includes
#include "aiAnim.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -61,6 +65,7 @@ namespace AssimpNET
{ {
public: public:
NodeAnim(void); NodeAnim(void);
NodeAnim(aiNodeAnim* native);
~NodeAnim(void); ~NodeAnim(void);
property String^ mNodeName property String^ mNodeName
@ -117,5 +122,9 @@ namespace AssimpNET
void set(array<VectorKey^>^ value){throw gcnew System::NotImplementedException();} void set(array<VectorKey^>^ value){throw gcnew System::NotImplementedException();}
} }
aiNodeAnim* getNative();
private:
aiNodeAnim *p_native;
}; };
}//namespace }//namespace

View File

@ -5,17 +5,23 @@ namespace AssimpNET
QuatKey::QuatKey(void) QuatKey::QuatKey(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiQuatKey();
} }
QuatKey::QuatKey(double time, const Quaternion^ value) QuatKey::QuatKey(double time, Quaternion% value)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiQuatKey(time, *(value.getNative()));
}
QuatKey::QuatKey(aiQuatKey* native)
{
this->p_native = native;
} }
QuatKey::~QuatKey() QuatKey::~QuatKey()
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
bool QuatKey::operator != (const QuatKey^ o) bool QuatKey::operator != (const QuatKey^ o)
@ -38,4 +44,9 @@ bool QuatKey::operator > (const QuatKey^ o)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiQuatKey* QuatKey::getNative()
{
return this->p_native;
}
} }

View File

@ -41,8 +41,12 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managend includes
#include "Quaternion.h" #include "Quaternion.h"
//native includes
#include "aiAnim.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -51,7 +55,8 @@ namespace AssimpNET
{ {
public: public:
QuatKey(); QuatKey();
QuatKey(double time, const Quaternion^ value); QuatKey(double time, Quaternion% value);
QuatKey(aiQuatKey* native);
~QuatKey(); ~QuatKey();
bool operator != (const QuatKey^ o); bool operator != (const QuatKey^ o);
@ -70,5 +75,9 @@ namespace AssimpNET
Quaternion^ get() {throw gcnew System::NotImplementedException();} Quaternion^ get() {throw gcnew System::NotImplementedException();}
void set(Quaternion^ value){throw gcnew System::NotImplementedException();} void set(Quaternion^ value){throw gcnew System::NotImplementedException();}
} }
aiQuatKey* getNative();
private:
aiQuatKey *p_native;
}; };
} }

View File

@ -1,42 +1,49 @@
#include "Quaternion.h" #include "Quaternion.h"
#include "Matrix3x3.h"
namespace AssimpNET namespace AssimpNET
{ {
Quaternion::Quaternion(void) Quaternion::Quaternion(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiQuaternion();
} }
Quaternion::Quaternion(Vector3D^ normalized) Quaternion::Quaternion(Vector3D^ normalized)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiQuaternion(*(normalized->getNative()));
} }
Quaternion::Quaternion(Vector3D^ axis, float angle) Quaternion::Quaternion(Vector3D^ axis, float angle)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiQuaternion(*(axis->getNative()), angle);
} }
Quaternion::Quaternion(float rotx, float roty, float rotz) Quaternion::Quaternion(float rotx, float roty, float rotz)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiQuaternion(rotx, roty, rotz);
} }
Quaternion::Quaternion(const Matrix3x3^ rotMatrix) Quaternion::Quaternion(Matrix3x3^ rotMatrix)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiQuaternion((*rotMatrix->getNative()));
} }
Quaternion::Quaternion(float _w, float _x, float _y, float _z) Quaternion::Quaternion(float _w, float _x, float _y, float _z)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiQuaternion(_w, _x, _y, _z);
}
Quaternion::Quaternion(aiQuaternion* native)
{
this->p_native = native;
} }
Quaternion::~Quaternion(void) Quaternion::~Quaternion(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
Quaternion^ Quaternion::Conjugate() Quaternion^ Quaternion::Conjugate()
@ -79,4 +86,9 @@ void Quaternion::Interpolate(Quaternion^ pOut, const Quaternion^ pStart, const Q
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiQuaternion* Quaternion::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -41,9 +41,12 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managed includes
#include "Vector3D.h" #include "Vector3D.h"
//#include "Matrix3x3.h"
//native includes
#include "aiTypes.h"
#include "aiQuaternion.h"
using namespace System; using namespace System;
@ -59,8 +62,9 @@ namespace AssimpNET
Quaternion(Vector3D^ normalized); Quaternion(Vector3D^ normalized);
Quaternion(Vector3D^ axis, float angle); Quaternion(Vector3D^ axis, float angle);
Quaternion(float rotx, float roty, float rotz); Quaternion(float rotx, float roty, float rotz);
Quaternion(const Matrix3x3^ rotMatrix); Quaternion(Matrix3x3^ rotMatrix);
Quaternion(float _w, float _x, float _y, float _z); Quaternion(float _w, float _x, float _y, float _z);
Quaternion(aiQuaternion* native);
~Quaternion(void); ~Quaternion(void);
Quaternion^ Conjugate(); Quaternion^ Conjugate();
@ -97,5 +101,9 @@ namespace AssimpNET
void set(float value) { throw gcnew System::NotImplementedException();} void set(float value) { throw gcnew System::NotImplementedException();}
} }
aiQuaternion* getNative();
private:
aiQuaternion *p_native;
}; };
}//namespace }//namespace

View File

@ -6,12 +6,18 @@ namespace AssimpNET
Scene::Scene(void) Scene::Scene(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiScene();
}
Scene::Scene(aiScene* native)
{
this->p_native = native;
} }
Scene::~Scene(void) Scene::~Scene(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
bool Scene::HasAnimations() bool Scene::HasAnimations()
@ -44,4 +50,9 @@ bool Scene::HasTextures()
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiScene* Scene::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -41,6 +41,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managend includes
#include "Animation.h" #include "Animation.h"
#include "Camera.h" #include "Camera.h"
#include "Light.h" #include "Light.h"
@ -49,6 +50,10 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "Node.h" #include "Node.h"
#include "Texture.h" #include "Texture.h"
//native includes
#include "aiScene.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -57,7 +62,9 @@ namespace AssimpNET
{ {
public: public:
Scene(void); Scene(void);
Scene(aiScene* native);
~Scene(void); ~Scene(void);
bool HasAnimations(); bool HasAnimations();
bool HasCameras(); bool HasCameras();
bool HasLights(); bool HasLights();
@ -136,5 +143,9 @@ namespace AssimpNET
void set(array<Texture^>^ value){throw gcnew System::NotImplementedException();} void set(array<Texture^>^ value){throw gcnew System::NotImplementedException();}
} }
aiScene* getNative();
private:
aiScene *p_native;
}; };
}//namespace }//namespace

View File

@ -6,12 +6,18 @@ namespace AssimpNET
Texel::Texel(void) Texel::Texel(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiTexel();
}
Texel::Texel(aiTexel* native)
{
this->p_native = native;
} }
Texel::~Texel(void) Texel::~Texel(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
Texel::operator Color4D() Texel::operator Color4D()
@ -29,4 +35,9 @@ bool Texel::operator == (const Texel^ t)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiTexel* Texel::getNative()
{
return this->p_native;
}
} }

View File

@ -1,7 +1,11 @@
#pragma once #pragma once
//managend includes
#include "Color4D.h" #include "Color4D.h"
//native includes
#include "aiTexture.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -11,6 +15,7 @@ public ref class Texel
{ {
public: public:
Texel(void); Texel(void);
Texel(aiTexel* native);
~Texel(void); ~Texel(void);
operator Color4D(); operator Color4D();
@ -40,6 +45,10 @@ public ref class Texel
unsigned char get(){throw gcnew System::NotImplementedException();} unsigned char get(){throw gcnew System::NotImplementedException();}
void set(unsigned char value){throw gcnew System::NotImplementedException();} void set(unsigned char value){throw gcnew System::NotImplementedException();}
} }
aiTexel* getNative();
private:
aiTexel *p_native;
}; };
}//namespace }//namespace

View File

@ -6,12 +6,18 @@ namespace AssimpNET
Texture::Texture(void) Texture::Texture(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiTexture();
}
Texture::Texture(aiTexture* native)
{
this->p_native = native;
} }
Texture::~Texture(void) Texture::~Texture(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
bool Texture::CheckFormat(array<char>^ s) bool Texture::CheckFormat(array<char>^ s)
@ -19,4 +25,9 @@ bool Texture::CheckFormat(array<char>^ s)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiTexture* Texture::getNative()
{
return this->p_native;
}
}//namespace }//namespace

View File

@ -41,8 +41,12 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managend includes
#include "Texel.h" #include "Texel.h"
//native includs
#include "aiTexture.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -97,6 +101,7 @@ namespace AssimpNET
{ {
public: public:
Texture(void); Texture(void);
Texture(aiTexture* native);
~Texture(void); ~Texture(void);
bool CheckFormat(array<char>^ s); bool CheckFormat(array<char>^ s);
@ -120,5 +125,9 @@ namespace AssimpNET
} }
property Texel^ pcData; property Texel^ pcData;
aiTexture* getNative();
private:
aiTexture *p_native;
}; };
}//namespace }//namespace

View File

@ -6,27 +6,33 @@ namespace AssimpNET
Vector2D::Vector2D(void) Vector2D::Vector2D(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVector2D();
} }
Vector2D::Vector2D(const Vector2D^ o) Vector2D::Vector2D(Vector2D% o)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVector2D(*(o.getNative()));
} }
Vector2D::Vector2D(float _xy) Vector2D::Vector2D(float _xy)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVector2D(_xy);
} }
Vector2D::Vector2D(float _x, float _y) Vector2D::Vector2D(float _x, float _y)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVector2D(_x, _y);
}
Vector2D::Vector2D(aiVector2D* native)
{
this->p_native = native;
} }
Vector2D::~Vector2D(void) Vector2D::~Vector2D(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
float Vector2D::Length() float Vector2D::Length()
@ -94,5 +100,10 @@ Vector2D^ Vector2D::SymMul(const Vector2D^ o)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiVector2D* Vector2D::getNative()
{
return this->p_native;
}
} }

View File

@ -41,6 +41,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//native includes
#include "aiTypes.h"
namespace AssimpNET namespace AssimpNET
{ {
@ -49,9 +51,10 @@ namespace AssimpNET
{ {
public: public:
Vector2D(void); Vector2D(void);
Vector2D(const Vector2D^ o); Vector2D(Vector2D% o);
Vector2D(float _xy); Vector2D(float _xy);
Vector2D(float _x, float _y); Vector2D(float _x, float _y);
Vector2D(aiVector2D* native);
~Vector2D(void); ~Vector2D(void);
float Length(); float Length();
Vector2D^ Normalize(); Vector2D^ Normalize();
@ -78,6 +81,10 @@ namespace AssimpNET
float get(){throw gcnew System::NotImplementedException();} float get(){throw gcnew System::NotImplementedException();}
void set(float value){throw gcnew System::NotImplementedException();} void set(float value){throw gcnew System::NotImplementedException();}
} }
aiVector2D* getNative();
private:
aiVector2D *p_native;
}; };
}//namespace }//namespace

View File

@ -6,27 +6,33 @@ namespace AssimpNET
Vector3D::Vector3D(void) Vector3D::Vector3D(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVector3D();
} }
Vector3D::Vector3D(const Vector3D^ o) Vector3D::Vector3D(Vector3D% o)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVector3D(*(o.getNative()));
} }
Vector3D::Vector3D(float _xyz) Vector3D::Vector3D(float _xyz)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVector3D(_xyz);
} }
Vector3D::Vector3D(float _x, float _y, float _z) Vector3D::Vector3D(float _x, float _y, float _z)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVector3D(_x, _y, _z);
}
Vector3D::Vector3D(aiVector3D* native)
{
this->p_native = native;
} }
Vector3D::~Vector3D(void) Vector3D::~Vector3D(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
float Vector3D::Length() float Vector3D::Length()
@ -99,4 +105,9 @@ Vector3D^ Vector3D::SymMul(const Vector3D^ o)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiVector3D* Vector3D::getNative()
{
return this->p_native;
}
} }

View File

@ -41,8 +41,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//native includes
//#include "Matrix4x4.h" #include "aiTypes.h"
using namespace System; using namespace System;
@ -54,9 +54,10 @@ namespace AssimpNET
{ {
public: public:
Vector3D(void); Vector3D(void);
Vector3D(const Vector3D^ o); Vector3D(Vector3D% o);
Vector3D(float _xyz); Vector3D(float _xyz);
Vector3D(float _x, float _y, float _z); Vector3D(float _x, float _y, float _z);
Vector3D(aiVector3D* native);
~Vector3D(void); ~Vector3D(void);
float Length(); float Length();
Vector3D^ Normalize(); Vector3D^ Normalize();
@ -91,7 +92,9 @@ namespace AssimpNET
void set(float value){throw gcnew System::NotImplementedException();} void set(float value){throw gcnew System::NotImplementedException();}
} }
aiVector3D* getNative();
private:
aiVector3D *p_native;
}; };
}//namespace }//namespace

View File

@ -6,17 +6,23 @@ namespace AssimpNET
VectorKey::VectorKey(void) VectorKey::VectorKey(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVectorKey();
} }
VectorKey::VectorKey(double time, const Vector3D^ value) VectorKey::VectorKey(double time, Vector3D^ value)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVectorKey(time, *(value->getNative()));
}
VectorKey::VectorKey(aiVectorKey* native)
{
this->p_native = native;
} }
VectorKey::~VectorKey(void) VectorKey::~VectorKey(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
} }
bool VectorKey::operator != (const VectorKey^ o) bool VectorKey::operator != (const VectorKey^ o)
@ -39,4 +45,9 @@ bool VectorKey::operator > (const VectorKey^ o)
throw gcnew System::NotImplementedException(); throw gcnew System::NotImplementedException();
} }
aiVectorKey* VectorKey::getNative()
{
return this->p_native;
}
} }

View File

@ -41,8 +41,12 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//managend includes
#include "Vector3D.h" #include "Vector3D.h"
//native includes
#include "aiAnim.h"
using namespace System; using namespace System;
namespace AssimpNET namespace AssimpNET
@ -52,7 +56,8 @@ namespace AssimpNET
{ {
public: public:
VectorKey(); VectorKey();
VectorKey(double time, const Vector3D^ value); VectorKey(double time, Vector3D^ value);
VectorKey(aiVectorKey* native);
~VectorKey(void); ~VectorKey(void);
bool operator != (const VectorKey^ o); bool operator != (const VectorKey^ o);
@ -71,5 +76,9 @@ namespace AssimpNET
Vector3D^ get() {throw gcnew System::NotImplementedException();} Vector3D^ get() {throw gcnew System::NotImplementedException();}
void set(Vector3D^ value){throw gcnew System::NotImplementedException();} void set(Vector3D^ value){throw gcnew System::NotImplementedException();}
} }
aiVectorKey* getNative();
private:
aiVectorKey *p_native;
}; };
} }

View File

@ -6,17 +6,28 @@ namespace AssimpNET
VertexWeight::VertexWeight(void) VertexWeight::VertexWeight(void)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVertexWeight();
} }
VertexWeight::VertexWeight(unsigned int pID, float pWeight) VertexWeight::VertexWeight(unsigned int pID, float pWeight)
{ {
throw gcnew System::NotImplementedException(); this->p_native = new aiVertexWeight(pID, pWeight);
}
VertexWeight::VertexWeight(aiVertexWeight *native)
{
this->p_native = native;
} }
VertexWeight::~VertexWeight(void) VertexWeight::~VertexWeight(void)
{ {
throw gcnew System::NotImplementedException(); if(this->p_native)
delete this->p_native;
}
aiVertexWeight* VertexWeight::getNative()
{
return this->p_native;
} }
}//namespace }//namespace

View File

@ -42,7 +42,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
//#include "Matrix4x4.h" //native includes
#include "aiMesh.h"
using namespace System; using namespace System;
@ -53,6 +54,7 @@ namespace AssimpNET
public: public:
VertexWeight(void); VertexWeight(void);
VertexWeight(unsigned int pID, float pWeight); VertexWeight(unsigned int pID, float pWeight);
VertexWeight(aiVertexWeight* native);
~VertexWeight(void); ~VertexWeight(void);
property unsigned int mVertexId property unsigned int mVertexId
@ -66,6 +68,10 @@ namespace AssimpNET
float get(){throw gcnew System::NotImplementedException();} float get(){throw gcnew System::NotImplementedException();}
void set(float value){throw gcnew System::NotImplementedException();} void set(float value){throw gcnew System::NotImplementedException();}
} }
aiVertexWeight* getNative();
private:
aiVertexWeight *p_native;
}; };
}//namespace }//namespace

View File

@ -41,9 +41,13 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
#include "Logger.h" //Managed Includes
#include "LogStream.h" #include "mLogger.h"
#include "IOSystem.h" #include "mLogStream.h"
#include "mIOSystem.h"
//native includes
#include "DefaultLogger.h"
using namespace System; using namespace System;
@ -53,6 +57,7 @@ namespace AssimpNET
{ {
public: public:
DefaultLogger(void); DefaultLogger(void);
DefaultLogger(Assimp::DefaultLogger* native);
~DefaultLogger(void); ~DefaultLogger(void);
virtual bool attachStream(LogStream^ stream, unsigned int severity) override; virtual bool attachStream(LogStream^ stream, unsigned int severity) override;
@ -63,5 +68,9 @@ namespace AssimpNET
static bool isNullLogger(); static bool isNullLogger();
static void kill(); static void kill();
static void set(Logger^ logger); static void set(Logger^ logger);
Assimp::DefaultLogger* getNative();
private:
Assimp::DefaultLogger* p_native;
}; };
}//namespace }//namespace

View File

@ -41,7 +41,11 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
#include "IOStream.h" //managed includes
#include "mIOStream.h"
//native includes
#include "IOSystem.h"
using namespace System; using namespace System;
@ -51,6 +55,7 @@ namespace AssimpNET
{ {
public: public:
IOSystem(void); IOSystem(void);
IOSystem(Assimp::IOSystem* native);
virtual ~IOSystem(void); virtual ~IOSystem(void);
virtual void Close (IOStream^ pFile) = 0; virtual void Close (IOStream^ pFile) = 0;
@ -61,6 +66,10 @@ namespace AssimpNET
virtual char getOsSeperator() = 0; virtual char getOsSeperator() = 0;
IOStream^ Open(const String^ pFile, const String^ pMode); IOStream^ Open(const String^ pFile, const String^ pMode);
virtual IOStream^ Open(array<char>^ pFile, array<char>^ pMode) = 0; virtual IOStream^ Open(array<char>^ pFile, array<char>^ pMode) = 0;
Assimp::IOSystem* getNative();
private:
Assimp::IOSystem *p_native;
}; };
}//namespace }//namespace

View File

@ -41,7 +41,11 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#pragma once #pragma once
#include "LogStream.h" //managed includes
#include "mLogStream.h"
//native includes
#include "Logger.h"
using namespace System; using namespace System;
@ -69,6 +73,7 @@ namespace AssimpNET
protected: protected:
Logger(LogSeverity); Logger(LogSeverity);
Logger(Assimp::Logger* native);
Logger(); Logger();
virtual void OnDebug(array<char>^ message) = 0; virtual void OnDebug(array<char>^ message) = 0;
virtual void OnError(array<char>^ message) = 0; virtual void OnError(array<char>^ message) = 0;
@ -81,5 +86,9 @@ namespace AssimpNET
void set(LogSeverity value){throw gcnew System::NotImplementedException();} void set(LogSeverity value){throw gcnew System::NotImplementedException();}
} }
Assimp::Logger* getNative();
private:
Assimp::Logger *p_native;
}; };
}//namespace }//namespace

View File

@ -19,6 +19,9 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "assimpcmd", "assimp_cmd.vcp
EndProjectSection EndProjectSection
EndProject EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Assimp.NET", "..\..\port\Assimp.NET\Assimp.NET\Assimp.NET.vcproj", "{4922D7BD-5E7A-44DD-BC1D-7F6F0BD82894}" Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Assimp.NET", "..\..\port\Assimp.NET\Assimp.NET\Assimp.NET.vcproj", "{4922D7BD-5E7A-44DD-BC1D-7F6F0BD82894}"
ProjectSection(ProjectDependencies) = postProject
{5691E159-2D9B-407F-971F-EA5C592DC524} = {5691E159-2D9B-407F-971F-EA5C592DC524}
EndProjectSection
EndProject EndProject
Global Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution GlobalSection(SolutionConfigurationPlatforms) = preSolution