1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
5 * Moonlight List (moonlight-list@lists.ximian.com)
7 * Copyright 2009 Novell, Inc. (http://www.novell.com)
9 * See the LICENSE file included with the distribution for details.
13 #ifndef __MOONLIGHT_PROJECTION_H__
14 #define __MOONLIGHT_PROJECTION_H__
18 #include "dependencyobject.h"
20 /* @Namespace=None */ // The managed Matrix3D is a struct
21 /* @ManagedDependencyProperties=Manual */
22 /* @ManagedEvents=None */
23 class Matrix3D
: public DependencyObject
{
28 virtual ~Matrix3D () {}
31 /* @PropertyType=double,DefaultValue=1.0,GenerateAccessors */
32 const static int M11Property
;
33 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
34 const static int M12Property
;
35 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
36 const static int M13Property
;
37 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
38 const static int M14Property
;
39 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
40 const static int M21Property
;
41 /* @PropertyType=double,DefaultValue=1.0,GenerateAccessors */
42 const static int M22Property
;
43 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
44 const static int M23Property
;
45 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
46 const static int M24Property
;
47 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
48 const static int M31Property
;
49 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
50 const static int M32Property
;
51 /* @PropertyType=double,DefaultValue=1.0,GenerateAccessors */
52 const static int M33Property
;
53 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
54 const static int M34Property
;
55 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
56 const static int OffsetXProperty
;
57 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
58 const static int OffsetYProperty
;
59 /* @PropertyType=double,DefaultValue=0.0,GenerateAccessors */
60 const static int OffsetZProperty
;
61 /* @PropertyType=double,DefaultValue=1.0,GenerateAccessors */
62 const static int M44Property
;
64 /* @GenerateCBinding,GeneratePInvoke */
67 virtual void OnPropertyChanged (PropertyChangedEventArgs
*args
, MoonError
*error
);
69 /* @GenerateCBinding,GeneratePInvoke */
70 gpointer
GetMatrixValues () { return matrix
; }
75 void SetM11 (double m11
);
78 void SetM12 (double m12
);
81 void SetM13 (double m13
);
84 void SetM14 (double m14
);
87 void SetM21 (double m21
);
90 void SetM22 (double m22
);
93 void SetM23 (double m23
);
96 void SetM24 (double m24
);
99 void SetM31 (double m31
);
102 void SetM32 (double m32
);
105 void SetM33 (double m33
);
108 void SetM34 (double m34
);
111 void SetOffsetX (double offsetX
);
112 double GetOffsetX ();
114 void SetOffsetY (double offsetY
);
115 double GetOffsetY ();
117 void SetOffsetZ (double offsetY
);
118 double GetOffsetZ ();
120 void SetM44 (double m44
);
124 /* @Namespace=System.Windows.Media.Media3D */
125 class UnmanagedMatrix3D
: public Matrix3D
{
128 virtual ~UnmanagedMatrix3D () {}
131 /* @GenerateCBinding,GeneratePInvoke */
132 UnmanagedMatrix3D () { SetObjectType (Type::UNMANAGEDMATRIX3D
); }
135 /* @Namespace=System.Windows.Media */
136 class Projection
: public DependencyObject
{
138 /* @GenerateCBinding,GeneratePInvoke,ManagedAccess=Protected */
139 Projection () { SetObjectType (Type::PROJECTION
); }
142 virtual ~Projection () {}
145 /* @Namespace=System.Windows.Media */
146 class PlaneProjection
: public Projection
{
148 /* @GenerateCBinding,GeneratePInvoke */
149 PlaneProjection () { SetObjectType (Type::PLANEPROJECTION
); }
151 /* @PropertyType=double,DefaultValue=0.5,GenerateAccessors */
152 const static int CenterOfRotationXProperty
;
153 /* @PropertyType=double,DefaultValue=0.5,GenerateAccessors */
154 const static int CenterOfRotationYProperty
;
155 /* @PropertyType=double,DefaultValue=0.5,GenerateAccessors */
156 const static int CenterOfRotationZProperty
;
158 /* @PropertyType=double,GenerateAccessors */
159 const static int GlobalOffsetXProperty
;
160 /* @PropertyType=double,GenerateAccessors */
161 const static int GlobalOffsetYProperty
;
162 /* @PropertyType=double,GenerateAccessors */
163 const static int GlobalOffsetZProperty
;
165 /* @PropertyType=double,GenerateAccessors */
166 const static int LocalOffsetXProperty
;
167 /* @PropertyType=double,GenerateAccessors */
168 const static int LocalOffsetYProperty
;
169 /* @PropertyType=double,GenerateAccessors */
170 const static int LocalOffsetZProperty
;
172 /* @PropertyType=double,GenerateAccessors */
173 const static int RotationXProperty
;
174 /* @PropertyType=double,GenerateAccessors */
175 const static int RotationYProperty
;
176 /* @PropertyType=double,GenerateAccessors */
177 const static int RotationZProperty
;
179 /* @PropertyType=Matrix3D,GenerateAccessors,ManagedSetterAccess=Internal */
180 const static int ProjectionMatrixProperty
;
183 // Property Accessors
185 double GetCenterOfRotationX ();
186 void SetCenterOfRotationX (double value
);
188 double GetCenterOfRotationY ();
189 void SetCenterOfRotationY (double value
);
191 double GetCenterOfRotationZ ();
192 void SetCenterOfRotationZ (double value
);
194 double GetGlobalOffsetX ();
195 void SetGlobalOffsetX (double value
);
197 double GetGlobalOffsetY ();
198 void SetGlobalOffsetY (double value
);
200 double GetGlobalOffsetZ ();
201 void SetGlobalOffsetZ (double value
);
203 double GetLocalOffsetX ();
204 void SetLocalOffsetX (double value
);
206 double GetLocalOffsetY ();
207 void SetLocalOffsetY (double value
);
209 double GetLocalOffsetZ ();
210 void SetLocalOffsetZ (double value
);
212 double GetRotationX ();
213 void SetRotationX (double value
);
215 double GetRotationY ();
216 void SetRotationY (double value
);
218 double GetRotationZ ();
219 void SetRotationZ (double value
);
221 Matrix3D
* GetProjectionMatrix ();
222 void SetProjectionMatrix (Matrix3D
* value
);
225 virtual ~PlaneProjection () {}
228 /* @Namespace=System.Windows.Media */
229 /* @ContentProperty="ProjectionMatrix" */
230 class Matrix3DProjection
: public Projection
{
232 /* @GenerateCBinding,GeneratePInvoke */
233 Matrix3DProjection () { SetObjectType (Type::MATRIX3DPROJECTION
); }
235 /* @PropertyType=Matrix3D,GenerateAccessors */
236 const static int ProjectionMatrixProperty
;
240 // Property Accessors
242 void SetProjectionMatrix (Matrix3D
*matrix
);
243 Matrix3D
*GetProjectionMatrix ();
246 virtual ~Matrix3DProjection () {}