implementing more public properties

arrays of simple datatypes are complete

git-svn-id: https://assimp.svn.sourceforge.net/svnroot/assimp/trunk@511 67173fc5-114c-0410-ac8e-9d2fd5bffc1f
pull/1/head
rave3d 2009-12-09 07:42:45 +00:00
parent 1b73346c5b
commit 071010b4ee
15 changed files with 345 additions and 84 deletions

View File

@ -60,8 +60,16 @@ namespace AssimpNET
property array<unsigned int>^ mIndices
{
array<unsigned int>^ get(){throw gcnew System::NotImplementedException();}
void set(array<unsigned int>^ value){throw gcnew System::NotImplementedException();}
array<unsigned int>^ get()
{
array<unsigned int>^ tmp = gcnew array<unsigned int>(this->p_native->mNumIndices);
System::Runtime::InteropServices::Marshal::Copy((System::IntPtr)this->p_native->mIndices, (array<int>^)tmp, 0, tmp->Length);
return tmp;
}
void set(array<unsigned int>^ value)
{
System::Runtime::InteropServices::Marshal::Copy((array<int>^)value, 0, (System::IntPtr)this->p_native->mIndices, value->Length);
}
}
property unsigned int mNumIndices

View File

@ -66,8 +66,16 @@ namespace AssimpNET
property array<char>^ mData
{
array<char>^ get(){throw gcnew System::NotImplementedException();}
void set(array<char>^ value){throw gcnew System::NotImplementedException();}
array<char>^ get()
{
array<char>^ tmp = gcnew array<char>(this->p_native->mDataLength);
System::Runtime::InteropServices::Marshal::Copy((System::IntPtr)this->p_native->mData, (array<unsigned char>^)tmp, 0, this->p_native->mDataLength);
return tmp;
}
void set(array<char>^ value)
{
System::Runtime::InteropServices::Marshal::Copy((array<unsigned char>^)value, 0, (System::IntPtr)this->p_native->mData, value->Length);
}
}
property unsigned int mDataLength

View File

@ -141,11 +141,13 @@ namespace AssimpNET
{
array<unsigned int>^get()
{
throw gcnew System::NotImplementedException();
array<unsigned int>^ tmp = gcnew array<unsigned int>(AI_MAX_NUMBER_OF_TEXTURECOORDS);
System::Runtime::InteropServices::Marshal::Copy((System::IntPtr)this->p_native->mNumUVComponents,(array<int>^)tmp,0,AI_MAX_NUMBER_OF_TEXTURECOORDS);
return tmp;
}
void set(array<unsigned int>^ value)
{
throw gcnew System::NotImplementedException();
System::Runtime::InteropServices::Marshal::Copy((array<int>^)value,0,(System::IntPtr)this->p_native->mNumUVComponents, AI_MAX_NUMBER_OF_TEXTURECOORDS);
}
}

View File

@ -69,8 +69,16 @@ namespace AssimpNET
property array<unsigned int>^ mMeshes
{
array<unsigned int>^ get(){throw gcnew System::NotImplementedException();}
void set(array<unsigned int>^ value){throw gcnew System::NotImplementedException();}
array<unsigned int>^ get()
{
array<unsigned int>^ tmp = gcnew array<unsigned int>(this->p_native->mNumMeshes);
System::Runtime::InteropServices::Marshal::Copy((System::IntPtr)this->p_native->mMeshes,(array<int>^)tmp,0,this->p_native->mNumMeshes);
return tmp;
}
void set(array<unsigned int>^ value)
{
System::Runtime::InteropServices::Marshal::Copy((array<int>^)value,0,(System::IntPtr)this->p_native->mMeshes,this->p_native->mNumMeshes);
}
}
property String^ mName
@ -87,26 +95,50 @@ namespace AssimpNET
property unsigned int mNumChildren
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mNumChildren;
}
void set(unsigned int value)
{
this->p_native->mNumChildren = value;
}
}
property unsigned int mNumMeshes
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mNumMeshes;
}
void set(unsigned int value)
{
this->p_native->mNumMeshes = value;
}
}
property Matrix4x4^ mTransformation
{
Matrix4x4^ get(){throw gcnew System::NotImplementedException();}
void set(Matrix4x4^ value){throw gcnew System::NotImplementedException();}
Matrix4x4^ get()
{
return gcnew Matrix4x4(&this->p_native->mTransformation);
}
void set(Matrix4x4^ value)
{
this->p_native->mTransformation = aiMatrix4x4(*value->getNative());
}
}
property Node^ mParent
{
Node^ get(){throw gcnew System::NotImplementedException();}
void set(Node^ value){throw gcnew System::NotImplementedException();}
Node^ get()
{
return gcnew Node(this->p_native->mParent);
}
void set(Node^ value)
{
this->p_native->mParent = new aiNode(*value->getNative());
}
}
aiNode* getNative();

View File

@ -82,20 +82,38 @@ namespace AssimpNET
property unsigned int mNumPositionKeys
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mNumPositionKeys;
}
void set(unsigned int value)
{
this->p_native->mNumPositionKeys = value;
}
}
property unsigned int mNumRotationKeys
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mNumRotationKeys;
}
void set(unsigned int value)
{
this->p_native->mNumRotationKeys = value;
}
}
property unsigned int mNumScalingKeys
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mNumScalingKeys;
}
void set(unsigned int value)
{
this->p_native->mNumScalingKeys = value;
}
}
property array<VectorKey^>^ mPositionKeys

View File

@ -66,14 +66,26 @@ namespace AssimpNET
property double mTime
{
double get(){throw gcnew System::NotImplementedException();}
void set(double value){System::NotImplementedException();}
double get()
{
return this->p_native->mTime;
}
void set(double value)
{
this->p_native->mTime = value;
}
}
property Quaternion^ mValue
{
Quaternion^ get() {throw gcnew System::NotImplementedException();}
void set(Quaternion^ value){throw gcnew System::NotImplementedException();}
Quaternion^ get()
{
return gcnew Quaternion(&this->p_native->mValue);
}
void set(Quaternion^ value)
{
this->p_native->mValue = aiQuaternion(*value->getNative());
}
}
aiQuatKey* getNative();

View File

@ -79,26 +79,50 @@ namespace AssimpNET
property float x
{
float get() { throw gcnew System::NotImplementedException();}
void set(float value) { throw gcnew System::NotImplementedException();}
float get()
{
return this->p_native->x;
}
void set(float value)
{
this->p_native->x = value;
}
}
property float y
{
float get() { throw gcnew System::NotImplementedException();}
void set(float value) { throw gcnew System::NotImplementedException();}
float get()
{
return this->p_native->y;
}
void set(float value)
{
this->p_native->y = value;
}
}
property float z
{
float get() { throw gcnew System::NotImplementedException();}
void set(float value) { throw gcnew System::NotImplementedException();}
float get()
{
return this->p_native->z;
}
void set(float value)
{
this->p_native->z = value;
}
}
property float w
{
float get() { throw gcnew System::NotImplementedException();}
void set(float value) { throw gcnew System::NotImplementedException();}
float get()
{
return this->p_native->w;
}
void set(float value)
{
this->p_native->w = value;
}
}
aiQuaternion* getNative();

View File

@ -84,8 +84,14 @@ namespace AssimpNET
}
property unsigned int mFlags
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mFlags;
}
void set(unsigned int value)
{
this->p_native->mFlags = value;
}
}
property array<Light^>^ mLights
{
@ -104,38 +110,81 @@ namespace AssimpNET
}
property unsigned int mNumAnimations
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mNumAnimations;
}
void set(unsigned int value)
{
this->p_native->mNumAnimations = value;
}
}
property unsigned int mNumCameras
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mNumCameras;
}
void set(unsigned int value)
{
this->p_native->mNumCameras = value;
}
}
property unsigned int mNumLights
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mNumLights;
}
void set(unsigned int value)
{
this->p_native->mNumLights = value;
}
}
property unsigned int mNumMaterials
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mNumMaterials;
}
void set(unsigned int value)
{
this->p_native->mNumMaterials = value;
}
}
property unsigned int mNumMeshes
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mNumMeshes;
}
void set(unsigned int value)
{
this->p_native->mNumMeshes = value;
}
}
property unsigned int mNumTextures
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mNumTextures;
}
void set(unsigned int value)
{
this->p_native->mNumTextures = value;
}
}
property Node^ mRootNode
{
Node^ get(){throw gcnew System::NotImplementedException();}
void set(Node^ value){throw gcnew System::NotImplementedException();}
Node^ get()
{
return gcnew Node(this->p_native->mRootNode);
}
void set(Node^ value)
{
//this->p_native->mRootNode = new aiNode(value->getNative());
this->p_native->mRootNode = value->getNative();
}
}
property array<Texture^>^ mTextures
{

View File

@ -24,26 +24,50 @@ public ref class Texel
property unsigned char a
{
unsigned char get(){throw gcnew System::NotImplementedException();}
void set(unsigned char value){throw gcnew System::NotImplementedException();}
unsigned char get()
{
return this->p_native->a;
}
void set(unsigned char value)
{
this->p_native->a = value;
}
}
property unsigned char r
{
unsigned char get(){throw gcnew System::NotImplementedException();}
void set(unsigned char value){throw gcnew System::NotImplementedException();}
unsigned char get()
{
return this->p_native->r;
}
void set(unsigned char value)
{
this->p_native->r = value;
}
}
property unsigned char g
{
unsigned char get(){throw gcnew System::NotImplementedException();}
void set(unsigned char value){throw gcnew System::NotImplementedException();}
unsigned char get()
{
return this->p_native->g;
}
void set(unsigned char value)
{
this->p_native->g = value;
}
}
property unsigned char b
{
unsigned char get(){throw gcnew System::NotImplementedException();}
void set(unsigned char value){throw gcnew System::NotImplementedException();}
unsigned char get()
{
return this->p_native->b;
}
void set(unsigned char value)
{
this->p_native->b = value;
}
}
aiTexel* getNative();

View File

@ -108,23 +108,53 @@ namespace AssimpNET
property array<char, 4>^ achFormatHint
{
array<char, 4>^ get(){throw gcnew System::NotImplementedException();}
void set(array<char, 4>^ value){throw gcnew System::NotImplementedException();}
array<char, 4>^ get()
{
array<char, 4>^ tmp = array<char, 4>();
System::Runtime::InteropServices::Marshal::Copy((System::IntPtr)this->p_native->achFormatHint,(array<unsigned char>^)tmp,0,4);
return tmp;
}
void set(array<char, 4>^ value)
{
System::Runtime::InteropServices::Marshal::Copy((array<unsigned char>^)value,0,(System::IntPtr)this->p_native->achFormatHint,4);
}
}
property unsigned int mHeight
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mHeight;
}
void set(unsigned int value)
{
this->p_native->mHeight = value;
}
}
property unsigned int mWidth
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mWidth;
}
void set(unsigned int value)
{
this->p_native->mWidth = value;
}
}
property Texel^ pcData;
property Texel^ pcData
{
Texel^ get()
{
return gcnew Texel(this->p_native->pcData);
}
void set(Texel^ value)
{
this->p_native->pcData = new aiTexel(*value->getNative());
}
}
aiTexture* getNative();
private:

View File

@ -72,14 +72,26 @@ namespace AssimpNET
property float x
{
float get(){throw gcnew System::NotImplementedException();}
void set(float value){throw gcnew System::NotImplementedException();}
float get()
{
return this->p_native->x;
}
void set(float value)
{
this->p_native->x = value;
}
}
property float y
{
float get(){throw gcnew System::NotImplementedException();}
void set(float value){throw gcnew System::NotImplementedException();}
float get()
{
return this->p_native->y;
}
void set(float value)
{
this->p_native->x = value;
}
}
aiVector2D* getNative();

View File

@ -76,20 +76,38 @@ namespace AssimpNET
property float x
{
float get(){throw gcnew System::NotImplementedException();}
void set(float value){throw gcnew System::NotImplementedException();}
float get()
{
return this->p_native->x;
}
void set(float value)
{
this->p_native->x = value;
}
}
property float y
{
float get(){throw gcnew System::NotImplementedException();}
void set(float value){throw gcnew System::NotImplementedException();}
float get()
{
return this->p_native->y;
}
void set(float value)
{
this->p_native->y = value;
}
}
property float z
{
float get(){throw gcnew System::NotImplementedException();}
void set(float value){throw gcnew System::NotImplementedException();}
float get()
{
return this->p_native->z;
}
void set(float value)
{
this->p_native->z = value;
}
}
aiVector3D* getNative();

View File

@ -67,14 +67,26 @@ namespace AssimpNET
property double mTime
{
double get(){throw gcnew System::NotImplementedException();}
void set(double value){System::NotImplementedException();}
double get()
{
return this->p_native->mTime;
}
void set(double value)
{
this->p_native->mTime = value;
}
}
property Vector3D^ mValue
{
Vector3D^ get() {throw gcnew System::NotImplementedException();}
void set(Vector3D^ value){throw gcnew System::NotImplementedException();}
Vector3D^ get()
{
return gcnew Vector3D(&this->p_native->mValue);
}
void set(Vector3D^ value)
{
this->p_native->mValue = aiVector3D(*value->getNative());
}
}
aiVectorKey* getNative();

View File

@ -59,14 +59,26 @@ namespace AssimpNET
property unsigned int mVertexId
{
unsigned int get(){throw gcnew System::NotImplementedException();}
void set(unsigned int value){throw gcnew System::NotImplementedException();}
unsigned int get()
{
return this->p_native->mVertexId;
}
void set(unsigned int value)
{
this->p_native->mVertexId = value;
}
}
property float mWeight
{
float get(){throw gcnew System::NotImplementedException();}
void set(float value){throw gcnew System::NotImplementedException();}
float get()
{
return this->p_native->mWeight;
}
void set(float value)
{
this->p_native->mWeight = value;
}
}
aiVertexWeight* getNative();