1 //------------------------------------------------------------------------------
4 // This file was automatically generated by SWIG (http://www.swig.org).
7 // Do not make changes to this file unless you know what you are doing--modify
8 // the SWIG interface file instead.
9 //------------------------------------------------------------------------------
14 internal class Matrix3 : global::System.IDisposable
16 private global::System.Runtime.InteropServices.HandleRef swigCPtr;
17 protected bool swigCMemOwn;
19 internal Matrix3(global::System.IntPtr cPtr, bool cMemoryOwn)
21 swigCMemOwn = cMemoryOwn;
22 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
25 internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Matrix3 obj)
27 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
30 //A Flag to check who called Dispose(). (By User or DisposeQueue)
31 private bool isDisposeQueued = false;
32 //A Flat to check if it is already disposed.
33 protected bool disposed = false;
40 isDisposeQueued = true;
41 DisposeQueue.Instance.Add(this);
47 //Throw excpetion if Dispose() is called in separate thread.
48 if (!Window.IsInstalled())
50 throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
55 Dispose(DisposeTypes.Implicit);
59 Dispose(DisposeTypes.Explicit);
60 System.GC.SuppressFinalize(this);
64 protected virtual void Dispose(DisposeTypes type)
71 if (type == DisposeTypes.Explicit)
74 //Release your own managed resources here.
75 //You should release all of your own disposable objects here.
79 //Release your own unmanaged resources here.
80 //You should not access any managed member here except static instance.
81 //because the execution order of Finalizes is non-deterministic.
83 if (swigCPtr.Handle != global::System.IntPtr.Zero)
88 NDalicPINVOKE.delete_Matrix3(swigCPtr);
90 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
96 public static Matrix3 IDENTITY
100 global::System.IntPtr cPtr = NDalicPINVOKE.Matrix3_IDENTITY_get();
101 Matrix3 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Matrix3(cPtr, false);
102 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
107 public Matrix3() : this(NDalicPINVOKE.new_Matrix3__SWIG_0(), true)
109 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
112 public Matrix3(Matrix3 m) : this(NDalicPINVOKE.new_Matrix3__SWIG_1(Matrix3.getCPtr(m)), true)
114 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
117 public Matrix3(Matrix m) : this(NDalicPINVOKE.new_Matrix3__SWIG_2(Matrix.getCPtr(m)), true)
119 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
122 public Matrix3(float s00, float s01, float s02, float s10, float s11, float s12, float s20, float s21, float s22) : this(NDalicPINVOKE.new_Matrix3__SWIG_3(s00, s01, s02, s10, s11, s12, s20, s21, s22), true)
124 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
127 public Matrix3 Assign(Matrix3 matrix)
129 Matrix3 ret = new Matrix3(NDalicPINVOKE.Matrix3_Assign__SWIG_0(swigCPtr, Matrix3.getCPtr(matrix)), false);
130 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
134 public Matrix3 Assign(Matrix matrix)
136 Matrix3 ret = new Matrix3(NDalicPINVOKE.Matrix3_Assign__SWIG_1(swigCPtr, Matrix.getCPtr(matrix)), false);
137 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
141 public bool EqualTo(Matrix3 rhs)
143 bool ret = NDalicPINVOKE.Matrix3_EqualTo(swigCPtr, Matrix3.getCPtr(rhs));
144 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
148 public bool NotEqualTo(Matrix3 rhs)
150 bool ret = NDalicPINVOKE.Matrix3_NotEqualTo(swigCPtr, Matrix3.getCPtr(rhs));
151 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
155 public void SetIdentity()
157 NDalicPINVOKE.Matrix3_SetIdentity(swigCPtr);
158 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
161 public SWIGTYPE_p_float AsFloat()
163 global::System.IntPtr cPtr = NDalicPINVOKE.Matrix3_AsFloat__SWIG_0(swigCPtr);
164 SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
165 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
171 bool ret = NDalicPINVOKE.Matrix3_Invert(swigCPtr);
172 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
176 public bool Transpose()
178 bool ret = NDalicPINVOKE.Matrix3_Transpose(swigCPtr);
179 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
183 public void Scale(float scale)
185 NDalicPINVOKE.Matrix3_Scale(swigCPtr, scale);
186 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
189 public float Magnitude()
191 float ret = NDalicPINVOKE.Matrix3_Magnitude(swigCPtr);
192 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
196 public bool ScaledInverseTranspose()
198 bool ret = NDalicPINVOKE.Matrix3_ScaledInverseTranspose(swigCPtr);
199 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
203 public static void Multiply(Matrix3 result, Matrix3 lhs, Matrix3 rhs)
205 NDalicPINVOKE.Matrix3_Multiply(Matrix3.getCPtr(result), Matrix3.getCPtr(lhs), Matrix3.getCPtr(rhs));
206 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();