[NUI] TCSACR-226 code change (#1032)
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / Vector3.cs
1 /*
2  * Copyright(c) 2018 Samsung Electronics Co., Ltd.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  */
17 using System;
18 using Tizen.NUI.Binding;
19
20 namespace Tizen.NUI
21 {
22
23     /// <summary>
24     /// A three-dimensional vector.
25     /// </summary>
26     /// <since_tizen> 3 </since_tizen>
27     [TypeConverter(typeof(Vector3TypeConverter))]
28     public class Vector3 : Disposable
29     {
30         /// <summary>
31         /// swigCMemOwn.
32         /// </summary>
33         /// <since_tizen> 3 </since_tizen>
34         protected bool swigCMemOwn;
35         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
36
37         /// <summary>
38         /// The constructor.
39         /// </summary>
40         /// <since_tizen> 3 </since_tizen>
41         public Vector3() : this(Interop.Vector3.new_Vector3__SWIG_0(), true)
42         {
43             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
44         }
45
46         /// <summary>
47         /// The default constructor initializes the vector to 0.
48         /// </summary>
49         /// <param name="x">The x (or width) component.</param>
50         /// <param name="y">The y (or height) component.</param>
51         /// <param name="z">The z (or depth) component.</param>
52         /// <since_tizen> 3 </since_tizen>
53         public Vector3(float x, float y, float z) : this(Interop.Vector3.new_Vector3__SWIG_1(x, y, z), true)
54         {
55             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
56         }
57
58         /// <summary>
59         /// Conversion constructor from an array of three floats.
60         /// </summary>
61         /// <param name="array">An array of xyz.</param>
62         /// <since_tizen> 3 </since_tizen>
63         public Vector3(float[] array) : this(Interop.Vector3.new_Vector3__SWIG_2(array), true)
64         {
65             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
66         }
67
68         /// <summary>
69         /// The constructor.
70         /// </summary>
71         /// <param name="vec2">Vector2 to create this vector from.</param>
72         /// <since_tizen> 3 </since_tizen>
73         public Vector3(Vector2 vec2) : this(Interop.Vector3.new_Vector3__SWIG_3(Vector2.getCPtr(vec2)), true)
74         {
75             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
76         }
77
78         /// <summary>
79         /// The constructor.
80         /// </summary>
81         /// <param name="vec4">Vector4 to create this vector from.</param>
82         /// <since_tizen> 3 </since_tizen>
83         public Vector3(Vector4 vec4) : this(Interop.Vector3.new_Vector3__SWIG_4(Vector4.getCPtr(vec4)), true)
84         {
85             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
86         }
87
88         internal Vector3(global::System.IntPtr cPtr, bool cMemoryOwn)
89         {
90             swigCMemOwn = cMemoryOwn;
91             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
92         }
93
94         /// <summary>
95         /// (1.0f,1.0f,1.0f).
96         /// </summary>
97         /// <since_tizen> 3 </since_tizen>
98         public static Vector3 One
99         {
100             get
101             {
102                 global::System.IntPtr cPtr = Interop.Vector3.Vector3_ONE_get();
103                 Vector3 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector3(cPtr, false);
104                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
105                 return ret;
106             }
107         }
108
109         /// <summary>
110         /// The vector representing the x-axis.
111         /// </summary>
112         /// <since_tizen> 3 </since_tizen>
113         public static Vector3 XAxis
114         {
115             get
116             {
117                 global::System.IntPtr cPtr = Interop.Vector3.Vector3_XAXIS_get();
118                 Vector3 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector3(cPtr, false);
119                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
120                 return ret;
121             }
122         }
123
124         /// <summary>
125         /// The vector representing the y-axis.
126         /// </summary>
127         /// <since_tizen> 3 </since_tizen>
128         public static Vector3 YAxis
129         {
130             get
131             {
132                 global::System.IntPtr cPtr = Interop.Vector3.Vector3_YAXIS_get();
133                 Vector3 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector3(cPtr, false);
134                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
135                 return ret;
136             }
137         }
138
139         /// <summary>
140         /// The vector representing the z-axis.
141         /// </summary>
142         /// <since_tizen> 3 </since_tizen>
143         public static Vector3 ZAxis
144         {
145             get
146             {
147                 global::System.IntPtr cPtr = Interop.Vector3.Vector3_ZAXIS_get();
148                 Vector3 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector3(cPtr, false);
149                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
150                 return ret;
151             }
152         }
153
154         /// <summary>
155         /// The vector representing the negative x-axis.
156         /// </summary>
157         /// <since_tizen> 3 </since_tizen>
158         public static Vector3 NegativeXAxis
159         {
160             get
161             {
162                 global::System.IntPtr cPtr = Interop.Vector3.Vector3_NEGATIVE_XAXIS_get();
163                 Vector3 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector3(cPtr, false);
164                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
165                 return ret;
166             }
167         }
168
169         /// <summary>
170         /// Th vector representing the negative y-axis.
171         /// </summary>
172         /// <since_tizen> 3 </since_tizen>
173         public static Vector3 NegativeYAxis
174         {
175             get
176             {
177                 global::System.IntPtr cPtr = Interop.Vector3.Vector3_NEGATIVE_YAXIS_get();
178                 Vector3 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector3(cPtr, false);
179                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
180                 return ret;
181             }
182         }
183
184         /// <summary>
185         /// The vector representing the negative z-axis.
186         /// </summary>
187         /// <since_tizen> 3 </since_tizen>
188         public static Vector3 NegativeZAxis
189         {
190             get
191             {
192                 global::System.IntPtr cPtr = Interop.Vector3.Vector3_NEGATIVE_ZAXIS_get();
193                 Vector3 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector3(cPtr, false);
194                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
195                 return ret;
196             }
197         }
198
199         /// <summary>
200         /// (0.0f, 0.0f, 0.0f).
201         /// </summary>
202         /// <since_tizen> 3 </since_tizen>
203         public static Vector3 Zero
204         {
205             get
206             {
207                 global::System.IntPtr cPtr = Interop.Vector3.Vector3_ZERO_get();
208                 Vector3 ret = (cPtr == global::System.IntPtr.Zero) ? null : new Vector3(cPtr, false);
209                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
210                 return ret;
211             }
212         }
213
214         /// <summary>
215         /// The x component.
216         /// </summary>
217         /// <since_tizen> 3 </since_tizen>
218         public float X
219         {
220             set
221             {
222                 Interop.Vector3.Vector3_X_set(swigCPtr, value);
223                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
224             }
225             get
226             {
227                 float ret = Interop.Vector3.Vector3_X_get(swigCPtr);
228                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
229                 return ret;
230             }
231         }
232
233         /// <summary>
234         /// The width component.
235         /// </summary>
236         /// <since_tizen> 3 </since_tizen>
237         public float Width
238         {
239             set
240             {
241                 Interop.Vector3.Vector3_Width_set(swigCPtr, value);
242                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
243             }
244             get
245             {
246                 float ret = Interop.Vector3.Vector3_Width_get(swigCPtr);
247                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
248                 return ret;
249             }
250         }
251
252         /// <summary>
253         /// The red component.
254         /// </summary>
255         /// <since_tizen> 3 </since_tizen>
256         public float R
257         {
258             set
259             {
260                 Interop.Vector3.Vector3_r_set(swigCPtr, value);
261                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
262             }
263             get
264             {
265                 float ret = Interop.Vector3.Vector3_r_get(swigCPtr);
266                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
267                 return ret;
268             }
269         }
270
271         /// <summary>
272         /// The y component.
273         /// </summary>
274         /// <since_tizen> 3 </since_tizen>
275         public float Y
276         {
277             set
278             {
279                 Interop.Vector3.Vector3_Y_set(swigCPtr, value);
280                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
281             }
282             get
283             {
284                 float ret = Interop.Vector3.Vector3_Y_get(swigCPtr);
285                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
286                 return ret;
287             }
288         }
289
290         /// <summary>
291         /// The height component.
292         /// </summary>
293         /// <since_tizen> 3 </since_tizen>
294         public float Height
295         {
296             set
297             {
298                 Interop.Vector3.Vector3_Height_set(swigCPtr, value);
299                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
300             }
301             get
302             {
303                 float ret = Interop.Vector3.Vector3_Height_get(swigCPtr);
304                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
305                 return ret;
306             }
307         }
308
309         /// <summary>
310         /// The green component.
311         /// </summary>
312         /// <since_tizen> 3 </since_tizen>
313         public float G
314         {
315             set
316             {
317                 Interop.Vector3.Vector3_g_set(swigCPtr, value);
318                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
319             }
320             get
321             {
322                 float ret = Interop.Vector3.Vector3_g_get(swigCPtr);
323                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
324                 return ret;
325             }
326         }
327
328         /// <summary>
329         /// The z component.
330         /// </summary>
331         /// <since_tizen> 3 </since_tizen>
332         public float Z
333         {
334             set
335             {
336                 Interop.Vector3.Vector3_Z_set(swigCPtr, value);
337                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
338             }
339             get
340             {
341                 float ret = Interop.Vector3.Vector3_Z_get(swigCPtr);
342                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
343                 return ret;
344             }
345         }
346
347         /// <summary>
348         /// The depth component.
349         /// </summary>
350         /// <since_tizen> 3 </since_tizen>
351         public float Depth
352         {
353             set
354             {
355                 Interop.Vector3.Vector3_Depth_set(swigCPtr, value);
356                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
357             }
358             get
359             {
360                 float ret = Interop.Vector3.Vector3_Depth_get(swigCPtr);
361                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
362                 return ret;
363             }
364         }
365
366         /// <summary>
367         /// The blue component.
368         /// </summary>
369         /// <since_tizen> 3 </since_tizen>
370         public float B
371         {
372             set
373             {
374                 Interop.Vector3.Vector3_b_set(swigCPtr, value);
375                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
376             }
377             get
378             {
379                 float ret = Interop.Vector3.Vector3_b_get(swigCPtr);
380                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
381                 return ret;
382             }
383         }
384
385         /// <summary>
386         /// An array subscript operator overload.
387         /// </summary>
388         /// <param name="index">The subscript index.</param>
389         /// <returns>The float at the given index.</returns>
390         /// <since_tizen> 3 </since_tizen>
391         public float this[uint index]
392         {
393             get
394             {
395                 return ValueOfIndex(index);
396             }
397         }
398
399         /// <summary>
400         /// The addition operator.
401         /// </summary>
402         /// <param name="arg1">The first value.</param>
403         /// <param name="arg2">The second value.</param>
404         /// <returns>The vector containing the result of the addition.</returns>
405         /// <since_tizen> 3 </since_tizen>
406         public static Vector3 operator +(Vector3 arg1, Vector3 arg2)
407         {
408             return arg1.Add(arg2);
409         }
410
411         /// <summary>
412         /// The subtraction operator.
413         /// </summary>
414         /// <param name="arg1">The first value.</param>
415         /// <param name="arg2">The second value.</param>
416         /// <returns>The vector containing the result of the subtraction.</returns>
417         /// <since_tizen> 3 </since_tizen>
418         public static Vector3 operator -(Vector3 arg1, Vector3 arg2)
419         {
420             return arg1.Subtract(arg2);
421         }
422
423         /// <summary>
424         /// The unary negation operator.
425         /// </summary>
426         /// <param name="arg1">The target value.</param>
427         /// <returns>The vector containg the negation.</returns>
428         /// <since_tizen> 3 </since_tizen>
429         public static Vector3 operator -(Vector3 arg1)
430         {
431             return arg1.Subtract();
432         }
433
434         /// <summary>
435         /// The multiplication operator.
436         /// </summary>
437         /// <param name="arg1">The first value.</param>
438         /// <param name="arg2">The second value.</param>
439         /// <returns>The vector containing the result of the multiplication.</returns>
440         /// <since_tizen> 3 </since_tizen>
441         public static Vector3 operator *(Vector3 arg1, Vector3 arg2)
442         {
443             return arg1.Multiply(arg2);
444         }
445
446         /// <summary>
447         /// The multiplication operator.
448         /// </summary>
449         /// <param name="arg1">The first value.</param>
450         /// <param name="arg2">The float value to scale the vector.</param>
451         /// <returns>The vector containing the result of the scaling.</returns>
452         /// <since_tizen> 3 </since_tizen>
453         public static Vector3 operator *(Vector3 arg1, float arg2)
454         {
455             return arg1.Multiply(arg2);
456         }
457
458         /// <summary>
459         /// The division operator.
460         /// </summary>
461         /// <param name="arg1">The first value.</param>
462         /// <param name="arg2">The second value.</param>
463         /// <returns>The vector containing the result of the division.</returns>
464         /// <since_tizen> 3 </since_tizen>
465         public static Vector3 operator /(Vector3 arg1, Vector3 arg2)
466         {
467             return arg1.Divide(arg2);
468         }
469
470         /// <summary>
471         /// The division operator.
472         /// </summary>
473         /// <param name="arg1">The first value.</param>
474         /// <param name="arg2">The float value to scale the vector by.</param>
475         /// <returns>The vector containing the result of the scaling.</returns>
476         /// <since_tizen> 3 </since_tizen>
477         public static Vector3 operator /(Vector3 arg1, float arg2)
478         {
479             return arg1.Divide(arg2);
480         }
481
482         /// <summary>
483         /// Determines whether the specified object is equal to the current object.
484         /// </summary>
485         /// <param name="obj">The object to compare with the current object.</param>
486         /// <returns>true if the specified object is equal to the current object; otherwise, false.</returns>
487         public override bool Equals(System.Object obj)
488         {
489             Vector3 vector3 = obj as Vector3;
490             bool equal = false;
491             if (X == vector3?.X && Y == vector3?.Y && Z == vector3?.Z)
492             {
493                 equal = true;
494             }
495             return equal;
496         }
497
498         /// <summary>
499         /// Gets the the hash code of this Vector3.
500         /// </summary>
501         /// <returns>The Hash Code.</returns>
502         /// <since_tizen> 6 </since_tizen>
503         public override int GetHashCode()
504         {
505             return swigCPtr.Handle.GetHashCode();
506         }
507
508         /// <summary>
509         /// Returns the length of the vector.
510         /// </summary>
511         /// <returns>The length of the vector.</returns>
512         /// <since_tizen> 3 </since_tizen>
513         public float Length()
514         {
515             float ret = Interop.Vector3.Vector3_Length(swigCPtr);
516             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
517             return ret;
518         }
519
520         /// <summary>
521         /// Returns the length of the vector squared.<br />
522         /// This is more efficient than Length() for threshold
523         /// testing as it avoids the use of a square root.<br />
524         /// </summary>
525         /// <returns>The length of the vector squared.</returns>
526         /// <since_tizen> 3 </since_tizen>
527         public float LengthSquared()
528         {
529             float ret = Interop.Vector3.Vector3_LengthSquared(swigCPtr);
530             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
531             return ret;
532         }
533
534         /// <summary>
535         /// Sets the vector to be unit length, whilst maintaining its direction.
536         /// </summary>
537         /// <since_tizen> 3 </since_tizen>
538         public void Normalize()
539         {
540             Interop.Vector3.Vector3_Normalize(swigCPtr);
541             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
542         }
543
544         /// <summary>
545         /// Clamps the vector between minimum and maximum vectors.
546         /// </summary>
547         /// <param name="min">The minimum vector.</param>
548         /// <param name="max">The maximum vector.</param>
549         /// <since_tizen> 3 </since_tizen>
550         public void Clamp(Vector3 min, Vector3 max)
551         {
552             Interop.Vector3.Vector3_Clamp(swigCPtr, Vector3.getCPtr(min), Vector3.getCPtr(max));
553             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
554         }
555
556         /// <summary>
557         /// Returns the x and y components (or width and height, or r and g) as a Vector2.
558         /// </summary>
559         /// <returns>The partial vector contents as Vector2 (x,y).</returns>
560         /// <since_tizen> 3 </since_tizen>
561         public Vector2 GetVectorXY()
562         {
563             Vector2 ret = new Vector2(Interop.Vector3.Vector3_GetVectorXY__SWIG_0(swigCPtr), false);
564             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
565             return ret;
566         }
567
568         /// <summary>
569         /// Returns the y and z components (or height and depth, or g and b) as a Vector2.
570         /// </summary>
571         /// <returns>The partial vector contents as Vector2 (y,z).</returns>
572         /// <since_tizen> 3 </since_tizen>
573         public Vector2 GetVectorYZ()
574         {
575             Vector2 ret = new Vector2(Interop.Vector3.Vector3_GetVectorYZ__SWIG_0(swigCPtr), false);
576             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
577             return ret;
578         }
579
580         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Vector3 obj)
581         {
582             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
583         }
584
585         internal static Vector3 GetVector3FromPtr(global::System.IntPtr cPtr)
586         {
587             Vector3 ret = new Vector3(cPtr, false);
588             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
589             return ret;
590         }
591
592         internal SWIGTYPE_p_float AsFloat()
593         {
594             global::System.IntPtr cPtr = Interop.Vector3.Vector3_AsFloat__SWIG_0(swigCPtr);
595             SWIGTYPE_p_float ret = (cPtr == global::System.IntPtr.Zero) ? null : new SWIGTYPE_p_float(cPtr, false);
596             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
597             return ret;
598         }
599
600         /// <summary>
601         /// Dispose.
602         /// </summary>
603         /// <param name="type">The dispose type</param>
604         /// <since_tizen> 3 </since_tizen>
605         protected override void Dispose(DisposeTypes type)
606         {
607             if (disposed)
608             {
609                 return;
610             }
611
612             //Release your own unmanaged resources here.
613             //You should not access any managed member here except static instance.
614             //because the execution order of Finalizes is non-deterministic.
615
616             if (swigCPtr.Handle != global::System.IntPtr.Zero)
617             {
618                 if (swigCMemOwn)
619                 {
620                     swigCMemOwn = false;
621                     Interop.Vector3.delete_Vector3(swigCPtr);
622                 }
623                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
624             }
625             base.Dispose(type);
626         }
627
628         private Vector3 Add(Vector3 rhs)
629         {
630             Vector3 ret = new Vector3(Interop.Vector3.Vector3_Add(swigCPtr, Vector3.getCPtr(rhs)), true);
631             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
632             return ret;
633         }
634
635         private Vector3 AddAssign(Vector3 rhs)
636         {
637             Vector3 ret = new Vector3(Interop.Vector3.Vector3_AddAssign(swigCPtr, Vector3.getCPtr(rhs)), false);
638             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
639             return ret;
640         }
641
642         private Vector3 Subtract(Vector3 rhs)
643         {
644             Vector3 ret = new Vector3(Interop.Vector3.Vector3_Subtract__SWIG_0(swigCPtr, Vector3.getCPtr(rhs)), true);
645             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
646             return ret;
647         }
648
649         private Vector3 SubtractAssign(Vector3 rhs)
650         {
651             Vector3 ret = new Vector3(Interop.Vector3.Vector3_SubtractAssign(swigCPtr, Vector3.getCPtr(rhs)), false);
652             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
653             return ret;
654         }
655
656         private Vector3 Multiply(Vector3 rhs)
657         {
658             Vector3 ret = new Vector3(Interop.Vector3.Vector3_Multiply__SWIG_0(swigCPtr, Vector3.getCPtr(rhs)), true);
659             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
660             return ret;
661         }
662
663         private Vector3 Multiply(float rhs)
664         {
665             Vector3 ret = new Vector3(Interop.Vector3.Vector3_Multiply__SWIG_1(swigCPtr, rhs), true);
666             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
667             return ret;
668         }
669
670         private Vector3 MultiplyAssign(Vector3 rhs)
671         {
672             Vector3 ret = new Vector3(Interop.Vector3.Vector3_MultiplyAssign__SWIG_0(swigCPtr, Vector3.getCPtr(rhs)), false);
673             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
674             return ret;
675         }
676
677         private Vector3 MultiplyAssign(float rhs)
678         {
679             Vector3 ret = new Vector3(Interop.Vector3.Vector3_MultiplyAssign__SWIG_1(swigCPtr, rhs), false);
680             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
681             return ret;
682         }
683
684         private Vector3 MultiplyAssign(Rotation rhs)
685         {
686             Vector3 ret = new Vector3(Interop.Vector3.Vector3_MultiplyAssign__SWIG_2(swigCPtr, Rotation.getCPtr(rhs)), false);
687             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
688             return ret;
689         }
690
691         private Vector3 Divide(Vector3 rhs)
692         {
693             Vector3 ret = new Vector3(Interop.Vector3.Vector3_Divide__SWIG_0(swigCPtr, Vector3.getCPtr(rhs)), true);
694             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
695             return ret;
696         }
697
698         private Vector3 Divide(float rhs)
699         {
700             Vector3 ret = new Vector3(Interop.Vector3.Vector3_Divide__SWIG_1(swigCPtr, rhs), true);
701             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
702             return ret;
703         }
704
705         private Vector3 DivideAssign(Vector3 rhs)
706         {
707             Vector3 ret = new Vector3(Interop.Vector3.Vector3_DivideAssign__SWIG_0(swigCPtr, Vector3.getCPtr(rhs)), false);
708             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
709             return ret;
710         }
711
712         private Vector3 DivideAssign(float rhs)
713         {
714             Vector3 ret = new Vector3(Interop.Vector3.Vector3_DivideAssign__SWIG_1(swigCPtr, rhs), false);
715             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
716             return ret;
717         }
718
719         private Vector3 Subtract()
720         {
721             Vector3 ret = new Vector3(Interop.Vector3.Vector3_Subtract__SWIG_1(swigCPtr), true);
722             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
723             return ret;
724         }
725
726         private bool EqualTo(Vector3 rhs)
727         {
728             bool ret = Interop.Vector3.Vector3_EqualTo(swigCPtr, Vector3.getCPtr(rhs));
729             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
730             return ret;
731         }
732
733         private bool NotEqualTo(Vector3 rhs)
734         {
735             bool ret = Interop.Vector3.Vector3_NotEqualTo(swigCPtr, Vector3.getCPtr(rhs));
736             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
737             return ret;
738         }
739
740         private float ValueOfIndex(uint index)
741         {
742             float ret = Interop.Vector3.Vector3_ValueOfIndex__SWIG_0(swigCPtr, index);
743             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
744             return ret;
745         }
746
747         internal float Dot(Vector3 other)
748         {
749             float ret = Interop.Vector3.Vector3_Dot(swigCPtr, Vector3.getCPtr(other));
750             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
751             return ret;
752         }
753
754         internal Vector3 Cross(Vector3 other)
755         {
756             Vector3 ret = new Vector3(Interop.Vector3.Vector3_Cross(swigCPtr, Vector3.getCPtr(other)), true);
757             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
758             return ret;
759         }
760
761     }
762
763 }