Change PositionUsesAnchorPoint property to PositionUsesPivotPoint
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / internal / Model3dView.cs
1 /** Copyright (c) 2017 Samsung Electronics Co., Ltd.
2 *
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at
6 *
7 * http://www.apache.org/licenses/LICENSE-2.0
8 *
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS,
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License.
14 *
15 */
16 // This File has been auto-generated by SWIG and then modified using DALi Ruby Scripts
17 //------------------------------------------------------------------------------
18 // <auto-generated />
19 //
20 // This file was automatically generated by SWIG (http://www.swig.org).
21 // Version 3.0.9
22 //
23 // Do not make changes to this file unless you know what you are doing--modify
24 // the SWIG interface file instead.
25 //------------------------------------------------------------------------------
26
27 using Tizen.NUI.BaseComponents;
28
29 namespace Tizen.NUI
30 {
31
32     internal class Model3dView : View
33     {
34         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
35
36         internal Model3dView(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.Model3dView_SWIGUpcast(cPtr), cMemoryOwn)
37         {
38             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
39         }
40
41         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Model3dView obj)
42         {
43             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
44         }
45
46         protected override void Dispose(DisposeTypes type)
47         {
48             if (disposed)
49             {
50                 return;
51             }
52
53             if (type == DisposeTypes.Explicit)
54             {
55                 //Called by User
56                 //Release your own managed resources here.
57                 //You should release all of your own disposable objects here.
58
59             }
60
61             //Release your own unmanaged resources here.
62             //You should not access any managed member here except static instance.
63             //because the execution order of Finalizes is non-deterministic.
64
65             if (swigCPtr.Handle != global::System.IntPtr.Zero)
66             {
67                 if (swigCMemOwn)
68                 {
69                     swigCMemOwn = false;
70                     NDalicPINVOKE.delete_Model3dView(swigCPtr);
71                 }
72                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
73             }
74
75             base.Dispose(type);
76         }
77
78         public class Property : global::System.IDisposable
79         {
80             private global::System.Runtime.InteropServices.HandleRef swigCPtr;
81             protected bool swigCMemOwn;
82
83             internal Property(global::System.IntPtr cPtr, bool cMemoryOwn)
84             {
85                 swigCMemOwn = cMemoryOwn;
86                 swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
87             }
88
89             internal static global::System.Runtime.InteropServices.HandleRef getCPtr(Property obj)
90             {
91                 return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;
92             }
93
94             //A Flag to check who called Dispose(). (By User or DisposeQueue)
95             private bool isDisposeQueued = false;
96             //A Flat to check if it is already disposed.
97             protected bool disposed = false;
98
99
100             ~Property()
101             {
102                 if (!isDisposeQueued)
103                 {
104                     isDisposeQueued = true;
105                     DisposeQueue.Instance.Add(this);
106                 }
107             }
108
109             public void Dispose()
110             {
111                 //Throw excpetion if Dispose() is called in separate thread.
112                 if (!Window.IsInstalled())
113                 {
114                     throw new System.InvalidOperationException("This API called from separate thread. This API must be called from MainThread.");
115                 }
116
117                 if (isDisposeQueued)
118                 {
119                     Dispose(DisposeTypes.Implicit);
120                 }
121                 else
122                 {
123                     Dispose(DisposeTypes.Explicit);
124                     System.GC.SuppressFinalize(this);
125                 }
126             }
127
128             protected virtual void Dispose(DisposeTypes type)
129             {
130                 if (disposed)
131                 {
132                     return;
133                 }
134
135                 if (type == DisposeTypes.Explicit)
136                 {
137                     //Called by User
138                     //Release your own managed resources here.
139                     //You should release all of your own disposable objects here.
140
141                 }
142
143                 //Release your own unmanaged resources here.
144                 //You should not access any managed member here except static instance.
145                 //because the execution order of Finalizes is non-deterministic.
146
147                 if (swigCPtr.Handle != global::System.IntPtr.Zero)
148                 {
149                     if (swigCMemOwn)
150                     {
151                         swigCMemOwn = false;
152                         NDalicPINVOKE.delete_Model3dView_Property(swigCPtr);
153                     }
154                     swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero);
155                 }
156
157                 disposed = true;
158             }
159
160             public Property() : this(NDalicPINVOKE.new_Model3dView_Property(), true)
161             {
162                 if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
163             }
164
165             public static readonly int GEOMETRY_URL = NDalicPINVOKE.Model3dView_Property_GEOMETRY_URL_get();
166             public static readonly int MATERIAL_URL = NDalicPINVOKE.Model3dView_Property_MATERIAL_URL_get();
167             public static readonly int IMAGES_URL = NDalicPINVOKE.Model3dView_Property_IMAGES_URL_get();
168             public static readonly int ILLUMINATION_TYPE = NDalicPINVOKE.Model3dView_Property_ILLUMINATION_TYPE_get();
169             public static readonly int TEXTURE0_URL = NDalicPINVOKE.Model3dView_Property_TEXTURE0_URL_get();
170             public static readonly int TEXTURE1_URL = NDalicPINVOKE.Model3dView_Property_TEXTURE1_URL_get();
171             public static readonly int TEXTURE2_URL = NDalicPINVOKE.Model3dView_Property_TEXTURE2_URL_get();
172             public static readonly int LIGHT_POSITION = NDalicPINVOKE.Model3dView_Property_LIGHT_POSITION_get();
173
174         }
175
176         public Model3dView() : this(NDalicPINVOKE.Model3dView_New__SWIG_0(), true)
177         {
178             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
179
180         }
181         public Model3dView(string objUrl, string mtlUrl, string imagesUrl) : this(NDalicPINVOKE.Model3dView_New__SWIG_1(objUrl, mtlUrl, imagesUrl), true)
182         {
183             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
184
185         }
186         public Model3dView(Model3dView model3dView) : this(NDalicPINVOKE.new_Model3dView__SWIG_1(Model3dView.getCPtr(model3dView)), true)
187         {
188             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
189         }
190
191         public Model3dView Assign(Model3dView model3dView)
192         {
193             Model3dView ret = new Model3dView(NDalicPINVOKE.Model3dView_Assign(swigCPtr, Model3dView.getCPtr(model3dView)), false);
194             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
195             return ret;
196         }
197
198         public new static Model3dView DownCast(BaseHandle handle)
199         {
200             Model3dView ret = new Model3dView(NDalicPINVOKE.Model3dView_DownCast(BaseHandle.getCPtr(handle)), true);
201             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
202             return ret;
203         }
204
205         public enum IluminationTypeEnum
206         {
207             DIFFUSE,
208             DIFFUSE_WITH_TEXTURE,
209             DIFFUSE_WITH_NORMAL_MAP
210         }
211
212         public string GeometryUrl
213         {
214             get
215             {
216                 string temp;
217                 GetProperty(Model3dView.Property.GEOMETRY_URL).Get(out temp);
218                 return temp;
219             }
220             set
221             {
222                 SetProperty(Model3dView.Property.GEOMETRY_URL, new Tizen.NUI.PropertyValue(value));
223             }
224         }
225         public string MaterialUrl
226         {
227             get
228             {
229                 string temp;
230                 GetProperty(Model3dView.Property.MATERIAL_URL).Get(out temp);
231                 return temp;
232             }
233             set
234             {
235                 SetProperty(Model3dView.Property.MATERIAL_URL, new Tizen.NUI.PropertyValue(value));
236             }
237         }
238         public string ImagesUrl
239         {
240             get
241             {
242                 string temp;
243                 GetProperty(Model3dView.Property.IMAGES_URL).Get(out temp);
244                 return temp;
245             }
246             set
247             {
248                 SetProperty(Model3dView.Property.IMAGES_URL, new Tizen.NUI.PropertyValue(value));
249             }
250         }
251         public int IlluminationType
252         {
253             get
254             {
255                 int temp = 0;
256                 GetProperty(Model3dView.Property.ILLUMINATION_TYPE).Get(out temp);
257                 return temp;
258             }
259             set
260             {
261                 SetProperty(Model3dView.Property.ILLUMINATION_TYPE, new Tizen.NUI.PropertyValue(value));
262             }
263         }
264         public string Texture0Url
265         {
266             get
267             {
268                 string temp;
269                 GetProperty(Model3dView.Property.TEXTURE0_URL).Get(out temp);
270                 return temp;
271             }
272             set
273             {
274                 SetProperty(Model3dView.Property.TEXTURE0_URL, new Tizen.NUI.PropertyValue(value));
275             }
276         }
277         public string Texture1Url
278         {
279             get
280             {
281                 string temp;
282                 GetProperty(Model3dView.Property.TEXTURE1_URL).Get(out temp);
283                 return temp;
284             }
285             set
286             {
287                 SetProperty(Model3dView.Property.TEXTURE1_URL, new Tizen.NUI.PropertyValue(value));
288             }
289         }
290         public string Texture2Url
291         {
292             get
293             {
294                 string temp;
295                 GetProperty(Model3dView.Property.TEXTURE2_URL).Get(out temp);
296                 return temp;
297             }
298             set
299             {
300                 SetProperty(Model3dView.Property.TEXTURE2_URL, new Tizen.NUI.PropertyValue(value));
301             }
302         }
303         public Vector3 LightPosition
304         {
305             get
306             {
307                 Vector3 temp = new Vector3(0.0f, 0.0f, 0.0f);
308                 GetProperty(Model3dView.Property.LIGHT_POSITION).Get(temp);
309                 return temp;
310             }
311             set
312             {
313                 SetProperty(Model3dView.Property.LIGHT_POSITION, new Tizen.NUI.PropertyValue(value));
314             }
315         }
316
317     }
318
319 }