OSDN Git Service

DTXMania089リリースに際してのtag付け。
[dtxmania/dtxmania.git] / 110401(DTXMania089) / SlimDXc_Jun2010(VC++2008) / source / direct3d11 / EffectVariable11.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 #include "../ComObject.h"\r
25 \r
26 #include "Enums11.h"\r
27 \r
28 namespace SlimDX\r
29 {\r
30         namespace Direct3D11\r
31         {\r
32                 ref class EffectConstantBuffer;\r
33                 ref class EffectMatrixVariable;\r
34                 ref class EffectResourceVariable;\r
35                 ref class EffectShaderVariable;\r
36                 ref class EffectScalarVariable;\r
37                 ref class EffectVectorVariable;\r
38                 ref class EffectStringVariable;\r
39                 ref class EffectUnorderedAccessViewVariable;\r
40                 ref class EffectBlendVariable;\r
41                 ref class EffectClassInstanceVariable;\r
42                 ref class EffectDepthStencilVariable;\r
43                 ref class EffectDepthStencilViewVariable;\r
44                 ref class EffectInterfaceVariable;\r
45                 ref class EffectRasterizerVariable;\r
46                 ref class EffectRenderTargetViewVariable;\r
47                 ref class EffectSamplerVariable;\r
48                 value class EffectVariableDescription;\r
49                 ref class EffectType;\r
50                 \r
51                 /// <summary>\r
52                 /// Defines a base class for all effect variables.\r
53                 /// </summary>\r
54                 /// <unmanaged>ID3DX11EffectVariable</unmanaged>\r
55                 public ref class EffectVariable\r
56                 {\r
57                 private:\r
58                         ID3DX11EffectVariable* m_Pointer;\r
59                         \r
60                 internal:\r
61                         EffectVariable( ID3DX11EffectVariable* pointer );\r
62 \r
63                 public:\r
64                         /// <summary>\r
65                         /// Initializes a new instance of the <see cref="EffectVariable"/> class.\r
66                         /// </summary>\r
67                         /// <param name="pointer">A pointer to the unmanaged interface.</param>\r
68                         EffectVariable( System::IntPtr pointer );\r
69 \r
70                         /// <summary>\r
71                         /// Gets the effect variable's description.\r
72                         /// </summary>\r
73                         property EffectVariableDescription Description\r
74                         {\r
75                                 EffectVariableDescription get();\r
76                         }\r
77                         \r
78                         /// <summary>\r
79                         /// Indicates whether the data type matches the data stored after casting to a specific interface.\r
80                         /// </summary>\r
81                         property bool IsValid\r
82                         {\r
83                                 bool get();\r
84                         }\r
85 \r
86                         /// <summary>\r
87                         /// Gets the parent constant buffer for this variable.\r
88                         /// </summary>\r
89                         property EffectConstantBuffer^ ParentConstantBuffer\r
90                         {\r
91                                 EffectConstantBuffer^ get();\r
92                         }\r
93 \r
94                         /// <summary>\r
95                         /// Get an annotation by index.\r
96                         /// </summary>\r
97                         /// <param name="index">The zero-based index of the annotation to retrieve.</param>\r
98                         /// <returns>The annotation at the specified index.</returns>\r
99                         EffectVariable^ GetAnnotationByIndex( int index );\r
100 \r
101                         /// <summary>\r
102                         /// Get an annotation by name.\r
103                         /// </summary>\r
104                         /// <param name="name">The name of the annotation to retrieve.</param>\r
105                         /// <returns>The annotation with the given name.</returns>\r
106                         EffectVariable^ GetAnnotationByName( System::String^ name );\r
107                         \r
108                         /// <summary>\r
109                         /// Gets an element of an array variable.\r
110                         /// </summary>\r
111                         /// <param name="index">The zero-based index of the element to retrieve.</param>\r
112                         /// <returns>The element at the specified index in the array.</returns>\r
113                         EffectVariable^ GetElement( int index );\r
114                         \r
115                         /// <summary>\r
116                         /// Get a structure member by index.\r
117                         /// </summary>\r
118                         /// <param name="index">The zero-based index of the structure member to retrieve.</param>\r
119                         /// <returns>The structure member at the specified index.</returns>\r
120                         EffectVariable^ GetMemberByIndex( int index );\r
121 \r
122                         /// <summary>\r
123                         /// Get a structure member by name.\r
124                         /// </summary>\r
125                         /// <param name="name">The name of the structure member to retrieve.</param>\r
126                         /// <returns>The structure member with the given name.</returns>\r
127                         EffectVariable^ GetMemberByName( System::String^ name );\r
128 \r
129                         /// <summary>\r
130                         /// Get a structure member by semantic.\r
131                         /// </summary>\r
132                         /// <param name="name">The semantic of the structure member to retrieve.</param>\r
133                         /// <returns>The structure member with the given semantic.</returns>\r
134                         EffectVariable^ GetMemberBySemantic( System::String^ name );\r
135                         \r
136                         /// <summary>\r
137                         /// Reinterprets the effect variable as a more specialized blend-state variable.\r
138                         /// </summary>\r
139                         /// <returns>The specialized effect variable.</returns>\r
140                         EffectBlendVariable^ AsBlend();\r
141 \r
142                         /// <summary>\r
143                         /// Reinterprets the effect variable as a more specialized class instance variable.\r
144                         /// </summary>\r
145                         /// <returns>The specialized effect variable.</returns>\r
146                         EffectClassInstanceVariable^ AsClassInstance();\r
147 \r
148                         /// <summary>\r
149                         /// Reinterprets the effect variable as a more specialized constant buffer variable.\r
150                         /// </summary>\r
151                         /// <returns>The specialized effect variable.</returns>\r
152                         EffectConstantBuffer^ AsConstantBuffer();\r
153 \r
154                         /// <summary>\r
155                         /// Reinterprets the effect variable as a more specialized depth-stencil-state variable.\r
156                         /// </summary>\r
157                         /// <returns>The specialized effect variable.</returns>\r
158                         EffectDepthStencilVariable^ AsDepthStencil();\r
159 \r
160                         /// <summary>\r
161                         /// Reinterprets the effect variable as a more specialized depth-stencil view variable.\r
162                         /// </summary>\r
163                         /// <returns>The specialized effect variable.</returns>\r
164                         EffectDepthStencilViewVariable^ AsDepthStencilView();\r
165 \r
166                         /// <summary>\r
167                         /// Reinterprets the effect variable as a more specialized interface variable.\r
168                         /// </summary>\r
169                         /// <returns>The specialized effect variable.</returns>\r
170                         EffectInterfaceVariable^ AsInterface();\r
171 \r
172                         /// <summary>\r
173                         /// Reinterprets the effect variable as a more specialized matrix variable.\r
174                         /// </summary>\r
175                         /// <returns>The specialized effect variable.</returns>\r
176                         EffectMatrixVariable^ AsMatrix();\r
177 \r
178                         /// <summary>\r
179                         /// Reinterprets the effect variable as a more specialized rasterizer-state variable.\r
180                         /// </summary>\r
181                         /// <returns>The specialized effect variable.</returns>\r
182                         EffectRasterizerVariable^ AsRasterizer();\r
183 \r
184                         /// <summary>\r
185                         /// Reinterprets the effect variable as a more specialized render target view variable.\r
186                         /// </summary>\r
187                         /// <returns>The specialized effect variable.</returns>\r
188                         EffectRenderTargetViewVariable^ AsRenderTargetView();\r
189 \r
190                         /// <summary>\r
191                         /// Reinterprets the effect variable as a more specialized sampler state variable.\r
192                         /// </summary>\r
193                         /// <returns>The specialized effect variable.</returns>\r
194                         EffectSamplerVariable^ AsSampler();\r
195 \r
196                         /// <summary>\r
197                         /// Reinterprets the effect variable as a more specialized shader resource variable.\r
198                         /// </summary>\r
199                         /// <returns>The specialized effect variable.</returns>\r
200                         EffectResourceVariable^ AsResource();\r
201 \r
202                         /// <summary>\r
203                         /// Reinterprets the effect variable as a more specialized scalar variable.\r
204                         /// </summary>\r
205                         /// <returns>The specialized effect variable.</returns>\r
206                         EffectScalarVariable^ AsScalar();\r
207 \r
208                         /// <summary>\r
209                         /// Reinterprets the effect variable as a more specialized shader variable.\r
210                         /// </summary>\r
211                         /// <returns>The specialized effect variable.</returns>\r
212                         EffectShaderVariable^ AsShader();\r
213 \r
214                         /// <summary>\r
215                         /// Reinterprets the effect variable as a more specialized string variable.\r
216                         /// </summary>\r
217                         /// <returns>The specialized effect variable.</returns>\r
218                         EffectStringVariable^ AsString();\r
219 \r
220                         /// <summary>\r
221                         /// Reinterprets the effect variable as a more specialized unordered access view variable.\r
222                         /// </summary>\r
223                         /// <returns>The specialized effect variable.</returns>\r
224                         EffectUnorderedAccessViewVariable^ AsUnorderedAccessView();\r
225 \r
226                         /// <summary>\r
227                         /// Reinterprets the effect variable as a more specialized vector variable.\r
228                         /// </summary>\r
229                         /// <returns>The specialized effect variable.</returns>\r
230                         EffectVectorVariable^ AsVector();\r
231 \r
232                         /// <summary>\r
233                         /// Gets information about the variable type.\r
234                         /// </summary>\r
235                         /// <returns>A type descriptor containing information about the variable type.</returns>\r
236                         EffectType^ GetVariableType();\r
237 \r
238                         /// <summary>\r
239                         /// Sets the value of the variable using raw bytes.\r
240                         /// </summary>\r
241                         /// <param name="count">The number of bytes to set.</param>\r
242                         /// <returns>A <see cref="SlimDX::Result"/> object describing the result of the operation.</returns>\r
243                         Result SetRawValue(DataStream^ data, int count);\r
244 \r
245                         /// <summary>\r
246                         /// Gets the value of the variable in raw bytes.\r
247                         /// </summary>\r
248                         /// <param name="count">The number of bytes to retrieve.</param>\r
249                         /// <returns>The raw data representing the value of the variable.</returns>\r
250                         DataStream^ GetRawValue(int count);\r
251                 };\r
252         }\r
253 };