OSDN Git Service

#36897 [DTXC] MIDIインポート機能の呼び出し口を、ファイルメニュー内にも配置。
[dtxmania/dtxmania.git] / SlimDXc_Jun2010(VC++2008) / source / direct3d11 / Viewport11.h
1 /*\r
2 * Copyright (c) 2007-2010 SlimDX Group\r
3\r
4 * Permission is hereby granted, free of charge, to any person obtaining a copy\r
5 * of this software and associated documentation files (the "Software"), to deal\r
6 * in the Software without restriction, including without limitation the rights\r
7 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\r
8 * copies of the Software, and to permit persons to whom the Software is\r
9 * furnished to do so, subject to the following conditions:\r
10\r
11 * The above copyright notice and this permission notice shall be included in\r
12 * all copies or substantial portions of the Software.\r
13\r
14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\r
15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\r
16 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\r
17 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\r
18 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\r
19 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\r
20 * THE SOFTWARE.\r
21 */\r
22 #pragma once\r
23 \r
24 namespace SlimDX\r
25 {\r
26         namespace Direct3D11\r
27         {\r
28                 /// <summary>\r
29                 /// Defines a rectangular region of a render-target surface onto which 3D rendering is projected.\r
30                 /// </summary>\r
31                 /// <unmanaged>D3D11_VIEWPORT</unmanaged>\r
32                 public value class Viewport : System::IEquatable<Viewport>\r
33                 {\r
34                         float m_X;\r
35                         float m_Y;\r
36                         float m_Width;\r
37                         float m_Height;\r
38                         float m_MinZ;\r
39                         float m_MaxZ;\r
40 \r
41                 public:\r
42                         /// <summary>\r
43                         /// Gets or sets the viewport's X position.\r
44                         /// </summary>\r
45                         property float X\r
46                         {\r
47                                 float get();\r
48                                 void set( float value );\r
49                         }\r
50                         \r
51                         /// <summary>\r
52                         /// Gets or sets the viewport's Y position.\r
53                         /// </summary>\r
54                         property float Y\r
55                         {\r
56                                 float get();\r
57                                 void set( float value );\r
58                         }\r
59                         \r
60                         /// <summary>\r
61                         /// Gets or sets the viewport's width.\r
62                         /// </summary>\r
63                         property float Width\r
64                         {\r
65                                 float get();\r
66                                 void set( float value );\r
67                         }\r
68                         \r
69                         /// <summary>\r
70                         /// Gets or sets the viewport's height.\r
71                         /// </summary>\r
72                         property float Height\r
73                         {\r
74                                 float get();\r
75                                 void set( float value );\r
76                         }\r
77 \r
78                         /// <summary>\r
79                         /// Gets or sets the viewport's minimum Z depth.\r
80                         /// </summary>\r
81                         property float MinZ\r
82                         {\r
83                                 float get();\r
84                                 void set( float value );\r
85                         }\r
86                         \r
87                         /// <summary>\r
88                         /// Gets or sets the viewport's maximum Z depth.\r
89                         /// </summary>\r
90                         property float MaxZ\r
91                         {\r
92                                 float get();\r
93                                 void set( float value );\r
94                         }\r
95                         \r
96                         /// <summary>\r
97                         /// Initializes a new instance of the <see cref="Viewport"/> structure.\r
98                         /// </summary>\r
99                         /// <param name="x">The X coordinate of the viewport.</param>\r
100                         /// <param name="y">The Y coordinate of the viewport.</param>\r
101                         /// <param name="width">The width of the viewport.</param>\r
102                         /// <param name="height">The height of the viewport.</param>\r
103                         Viewport( float x, float y, float width, float height);\r
104 \r
105                         /// <summary>\r
106                         /// Initializes a new instance of the <see cref="Viewport"/> structure.\r
107                         /// </summary>\r
108                         /// <param name="x">The X coordinate of the viewport.</param>\r
109                         /// <param name="y">The Y coordinate of the viewport.</param>\r
110                         /// <param name="width">The width of the viewport.</param>\r
111                         /// <param name="height">The height of the viewport.</param>\r
112                         /// <param name="minZ">The minimum Z distance of the viewport.</param>\r
113                         /// <param name="maxZ">The maximum Z distance of the viewport.</param>\r
114                         Viewport( float x, float y, float width, float height, float minZ, float maxZ );\r
115                         \r
116                         /// <summary>\r
117                         /// Tests for equality between two viewports.\r
118                         /// </summary>\r
119                         /// <param name="left">The first value to compare.</param>\r
120                         /// <param name="right">The second value to compare.</param>\r
121                         /// <returns><c>true</c> if <paramref name="left"/> has the same value as <paramref name="right"/>; otherwise, <c>false</c>.</returns>\r
122                         static bool operator == ( Viewport left, Viewport right );\r
123                         \r
124                         /// <summary>\r
125                         /// Tests for inequality between two viewports.\r
126                         /// </summary>\r
127                         /// <param name="left">The first value to compare.</param>\r
128                         /// <param name="right">The second value to compare.</param>\r
129                         /// <returns><c>true</c> if <paramref name="left"/> has a different value than <paramref name="right"/>; otherwise, <c>false</c>.</returns>\r
130                         static bool operator != ( Viewport left, Viewport right );\r
131 \r
132                         /// <summary>\r
133                         /// Converts the value of the viewport to its equivalent string representation.\r
134                         /// </summary>\r
135                         /// <returns>The string representation of the value of this instance.</returns>\r
136                         virtual System::String^ ToString() override;\r
137 \r
138                         /// <summary>\r
139                         /// Returns the hash code for this instance.\r
140                         /// </summary>\r
141                         /// <returns>A 32-bit signed floateger hash code.</returns>\r
142                         virtual int GetHashCode() override;\r
143 \r
144                         /// <summary>\r
145                         /// Returns a value indicating whether this instance is equal to the specified object.\r
146                         /// </summary>\r
147                         /// <param name="obj">An object to compare with this instance.</param>\r
148                         /// <returns><c>true</c> if <paramref name="obj"/> has the same value as this instance; otherwise, <c>false</c>.</returns>\r
149                         virtual bool Equals( System::Object^ obj ) override;\r
150 \r
151                         /// <summary>\r
152                         /// Returns a value indicating whether this instance is equal to the specified object.\r
153                         /// </summary>\r
154                         /// <param name="other">A <see cref="Viewport"/> to compare with this instance.</param>\r
155                         /// <returns><c>true</c> if <paramref name="other"/> has the same value as this instance; otherwise, <c>false</c>.</returns>\r
156                         virtual bool Equals( Viewport other );\r
157 \r
158                         /// <summary>\r
159                         /// Returns a value indicating whether the two viewports are equivalent.\r
160                         /// </summary>\r
161                         /// <param name="value1">The first value to compare.</param>\r
162                         /// <param name="value2">The second value to compare.</param>\r
163                         /// <returns><c>true</c> if <paramref name="value1"/> has the same value as <paramref name="value2"/>; otherwise, <c>false</c>.</returns>\r
164                         static bool Equals( Viewport% value1, Viewport% value2 );\r
165                 };\r
166         }\r
167 }