1 | /* SPDX-License-Identifier: GPL-2.0 OR MIT */
|
---|
2 | /**********************************************************
|
---|
3 | * Copyright 1998-2020 VMware, Inc.
|
---|
4 | *
|
---|
5 | * Permission is hereby granted, free of charge, to any person
|
---|
6 | * obtaining a copy of this software and associated documentation
|
---|
7 | * files (the "Software"), to deal in the Software without
|
---|
8 | * restriction, including without limitation the rights to use, copy,
|
---|
9 | * modify, merge, publish, distribute, sublicense, and/or sell copies
|
---|
10 | * of the Software, and to permit persons to whom the Software is
|
---|
11 | * furnished to do so, subject to the following conditions:
|
---|
12 | *
|
---|
13 | * The above copyright notice and this permission notice shall be
|
---|
14 | * included in all copies or substantial portions of the Software.
|
---|
15 | *
|
---|
16 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
---|
17 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
---|
18 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
---|
19 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
|
---|
20 | * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
|
---|
21 | * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
---|
22 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
---|
23 | * SOFTWARE.
|
---|
24 | *
|
---|
25 | **********************************************************/
|
---|
26 |
|
---|
27 | /*
|
---|
28 | * svga3d_cmd.h --
|
---|
29 | *
|
---|
30 | * SVGA 3d hardware cmd definitions
|
---|
31 | */
|
---|
32 |
|
---|
33 | #ifndef _SVGA3D_CMD_H_
|
---|
34 | #define _SVGA3D_CMD_H_
|
---|
35 |
|
---|
36 | #define INCLUDE_ALLOW_MODULE
|
---|
37 | #define INCLUDE_ALLOW_USERLEVEL
|
---|
38 | #define INCLUDE_ALLOW_VMCORE
|
---|
39 |
|
---|
40 | #include "includeCheck.h"
|
---|
41 | #include "svga3d_types.h"
|
---|
42 |
|
---|
43 | /*
|
---|
44 | * Identifiers for commands in the command FIFO.
|
---|
45 | *
|
---|
46 | * IDs between 1000 and 1039 (inclusive) were used by obsolete versions of
|
---|
47 | * the SVGA3D protocol and remain reserved; they should not be used in the
|
---|
48 | * future.
|
---|
49 | *
|
---|
50 | * IDs between 1040 and 2999 (inclusive) are available for use by the
|
---|
51 | * current SVGA3D protocol.
|
---|
52 | *
|
---|
53 | * FIFO clients other than SVGA3D should stay below 1000, or at 3000
|
---|
54 | * and up.
|
---|
55 | */
|
---|
56 |
|
---|
57 | typedef enum {
|
---|
58 | SVGA_3D_CMD_LEGACY_BASE = 1000,
|
---|
59 | SVGA_3D_CMD_BASE = 1040,
|
---|
60 |
|
---|
61 | SVGA_3D_CMD_SURFACE_DEFINE = 1040,
|
---|
62 | SVGA_3D_CMD_SURFACE_DESTROY = 1041,
|
---|
63 | SVGA_3D_CMD_SURFACE_COPY = 1042,
|
---|
64 | SVGA_3D_CMD_SURFACE_STRETCHBLT = 1043,
|
---|
65 | SVGA_3D_CMD_SURFACE_DMA = 1044,
|
---|
66 | SVGA_3D_CMD_CONTEXT_DEFINE = 1045,
|
---|
67 | SVGA_3D_CMD_CONTEXT_DESTROY = 1046,
|
---|
68 | SVGA_3D_CMD_SETTRANSFORM = 1047,
|
---|
69 | SVGA_3D_CMD_SETZRANGE = 1048,
|
---|
70 | SVGA_3D_CMD_SETRENDERSTATE = 1049,
|
---|
71 | SVGA_3D_CMD_SETRENDERTARGET = 1050,
|
---|
72 | SVGA_3D_CMD_SETTEXTURESTATE = 1051,
|
---|
73 | SVGA_3D_CMD_SETMATERIAL = 1052,
|
---|
74 | SVGA_3D_CMD_SETLIGHTDATA = 1053,
|
---|
75 | SVGA_3D_CMD_SETLIGHTENABLED = 1054,
|
---|
76 | SVGA_3D_CMD_SETVIEWPORT = 1055,
|
---|
77 | SVGA_3D_CMD_SETCLIPPLANE = 1056,
|
---|
78 | SVGA_3D_CMD_CLEAR = 1057,
|
---|
79 | SVGA_3D_CMD_PRESENT = 1058,
|
---|
80 | SVGA_3D_CMD_SHADER_DEFINE = 1059,
|
---|
81 | SVGA_3D_CMD_SHADER_DESTROY = 1060,
|
---|
82 | SVGA_3D_CMD_SET_SHADER = 1061,
|
---|
83 | SVGA_3D_CMD_SET_SHADER_CONST = 1062,
|
---|
84 | SVGA_3D_CMD_DRAW_PRIMITIVES = 1063,
|
---|
85 | SVGA_3D_CMD_SETSCISSORRECT = 1064,
|
---|
86 | SVGA_3D_CMD_BEGIN_QUERY = 1065,
|
---|
87 | SVGA_3D_CMD_END_QUERY = 1066,
|
---|
88 | SVGA_3D_CMD_WAIT_FOR_QUERY = 1067,
|
---|
89 | SVGA_3D_CMD_PRESENT_READBACK = 1068,
|
---|
90 | SVGA_3D_CMD_BLIT_SURFACE_TO_SCREEN = 1069,
|
---|
91 | SVGA_3D_CMD_SURFACE_DEFINE_V2 = 1070,
|
---|
92 | SVGA_3D_CMD_GENERATE_MIPMAPS = 1071,
|
---|
93 | SVGA_3D_CMD_DEAD4 = 1072,
|
---|
94 | SVGA_3D_CMD_DEAD5 = 1073,
|
---|
95 | SVGA_3D_CMD_DEAD6 = 1074,
|
---|
96 | SVGA_3D_CMD_DEAD7 = 1075,
|
---|
97 | SVGA_3D_CMD_DEAD8 = 1076,
|
---|
98 | SVGA_3D_CMD_DEAD9 = 1077,
|
---|
99 | SVGA_3D_CMD_DEAD10 = 1078,
|
---|
100 | SVGA_3D_CMD_DEAD11 = 1079,
|
---|
101 | SVGA_3D_CMD_ACTIVATE_SURFACE = 1080,
|
---|
102 | SVGA_3D_CMD_DEACTIVATE_SURFACE = 1081,
|
---|
103 | SVGA_3D_CMD_SCREEN_DMA = 1082,
|
---|
104 | #ifndef VBOX
|
---|
105 | SVGA_3D_CMD_DEAD1 = 1083,
|
---|
106 | #else
|
---|
107 | SVGA_3D_CMD_VB_DX_CLEAR_RENDERTARGET_VIEW_REGION = 1083,
|
---|
108 | #endif
|
---|
109 | SVGA_3D_CMD_DEAD2 = 1084,
|
---|
110 |
|
---|
111 | SVGA_3D_CMD_DEAD12 = 1085,
|
---|
112 | SVGA_3D_CMD_DEAD13 = 1086,
|
---|
113 | SVGA_3D_CMD_DEAD14 = 1087,
|
---|
114 | SVGA_3D_CMD_DEAD15 = 1088,
|
---|
115 | SVGA_3D_CMD_DEAD16 = 1089,
|
---|
116 | SVGA_3D_CMD_DEAD17 = 1090,
|
---|
117 |
|
---|
118 | SVGA_3D_CMD_SET_OTABLE_BASE = 1091,
|
---|
119 | SVGA_3D_CMD_READBACK_OTABLE = 1092,
|
---|
120 |
|
---|
121 | SVGA_3D_CMD_DEFINE_GB_MOB = 1093,
|
---|
122 | SVGA_3D_CMD_DESTROY_GB_MOB = 1094,
|
---|
123 | SVGA_3D_CMD_DEAD3 = 1095,
|
---|
124 | SVGA_3D_CMD_UPDATE_GB_MOB_MAPPING = 1096,
|
---|
125 |
|
---|
126 | SVGA_3D_CMD_DEFINE_GB_SURFACE = 1097,
|
---|
127 | SVGA_3D_CMD_DESTROY_GB_SURFACE = 1098,
|
---|
128 | SVGA_3D_CMD_BIND_GB_SURFACE = 1099,
|
---|
129 | SVGA_3D_CMD_COND_BIND_GB_SURFACE = 1100,
|
---|
130 | SVGA_3D_CMD_UPDATE_GB_IMAGE = 1101,
|
---|
131 | SVGA_3D_CMD_UPDATE_GB_SURFACE = 1102,
|
---|
132 | SVGA_3D_CMD_READBACK_GB_IMAGE = 1103,
|
---|
133 | SVGA_3D_CMD_READBACK_GB_SURFACE = 1104,
|
---|
134 | SVGA_3D_CMD_INVALIDATE_GB_IMAGE = 1105,
|
---|
135 | SVGA_3D_CMD_INVALIDATE_GB_SURFACE = 1106,
|
---|
136 |
|
---|
137 | SVGA_3D_CMD_DEFINE_GB_CONTEXT = 1107,
|
---|
138 | SVGA_3D_CMD_DESTROY_GB_CONTEXT = 1108,
|
---|
139 | SVGA_3D_CMD_BIND_GB_CONTEXT = 1109,
|
---|
140 | SVGA_3D_CMD_READBACK_GB_CONTEXT = 1110,
|
---|
141 | SVGA_3D_CMD_INVALIDATE_GB_CONTEXT = 1111,
|
---|
142 |
|
---|
143 | SVGA_3D_CMD_DEFINE_GB_SHADER = 1112,
|
---|
144 | SVGA_3D_CMD_DESTROY_GB_SHADER = 1113,
|
---|
145 | SVGA_3D_CMD_BIND_GB_SHADER = 1114,
|
---|
146 |
|
---|
147 | SVGA_3D_CMD_SET_OTABLE_BASE64 = 1115,
|
---|
148 |
|
---|
149 | SVGA_3D_CMD_BEGIN_GB_QUERY = 1116,
|
---|
150 | SVGA_3D_CMD_END_GB_QUERY = 1117,
|
---|
151 | SVGA_3D_CMD_WAIT_FOR_GB_QUERY = 1118,
|
---|
152 |
|
---|
153 | SVGA_3D_CMD_NOP = 1119,
|
---|
154 |
|
---|
155 | SVGA_3D_CMD_ENABLE_GART = 1120,
|
---|
156 | SVGA_3D_CMD_DISABLE_GART = 1121,
|
---|
157 | SVGA_3D_CMD_MAP_MOB_INTO_GART = 1122,
|
---|
158 | SVGA_3D_CMD_UNMAP_GART_RANGE = 1123,
|
---|
159 |
|
---|
160 | SVGA_3D_CMD_DEFINE_GB_SCREENTARGET = 1124,
|
---|
161 | SVGA_3D_CMD_DESTROY_GB_SCREENTARGET = 1125,
|
---|
162 | SVGA_3D_CMD_BIND_GB_SCREENTARGET = 1126,
|
---|
163 | SVGA_3D_CMD_UPDATE_GB_SCREENTARGET = 1127,
|
---|
164 |
|
---|
165 | SVGA_3D_CMD_READBACK_GB_IMAGE_PARTIAL = 1128,
|
---|
166 | SVGA_3D_CMD_INVALIDATE_GB_IMAGE_PARTIAL = 1129,
|
---|
167 |
|
---|
168 | SVGA_3D_CMD_SET_GB_SHADERCONSTS_INLINE = 1130,
|
---|
169 |
|
---|
170 | SVGA_3D_CMD_GB_SCREEN_DMA = 1131,
|
---|
171 | SVGA_3D_CMD_BIND_GB_SURFACE_WITH_PITCH = 1132,
|
---|
172 | SVGA_3D_CMD_GB_MOB_FENCE = 1133,
|
---|
173 | SVGA_3D_CMD_DEFINE_GB_SURFACE_V2 = 1134,
|
---|
174 | SVGA_3D_CMD_DEFINE_GB_MOB64 = 1135,
|
---|
175 | SVGA_3D_CMD_REDEFINE_GB_MOB64 = 1136,
|
---|
176 | SVGA_3D_CMD_NOP_ERROR = 1137,
|
---|
177 |
|
---|
178 | SVGA_3D_CMD_SET_VERTEX_STREAMS = 1138,
|
---|
179 | SVGA_3D_CMD_SET_VERTEX_DECLS = 1139,
|
---|
180 | SVGA_3D_CMD_SET_VERTEX_DIVISORS = 1140,
|
---|
181 | SVGA_3D_CMD_DRAW = 1141,
|
---|
182 | SVGA_3D_CMD_DRAW_INDEXED = 1142,
|
---|
183 |
|
---|
184 | /*
|
---|
185 | * DX10 Commands
|
---|
186 | */
|
---|
187 | SVGA_3D_CMD_DX_MIN = 1143,
|
---|
188 | SVGA_3D_CMD_DX_DEFINE_CONTEXT = 1143,
|
---|
189 | SVGA_3D_CMD_DX_DESTROY_CONTEXT = 1144,
|
---|
190 | SVGA_3D_CMD_DX_BIND_CONTEXT = 1145,
|
---|
191 | SVGA_3D_CMD_DX_READBACK_CONTEXT = 1146,
|
---|
192 | SVGA_3D_CMD_DX_INVALIDATE_CONTEXT = 1147,
|
---|
193 | SVGA_3D_CMD_DX_SET_SINGLE_CONSTANT_BUFFER = 1148,
|
---|
194 | SVGA_3D_CMD_DX_SET_SHADER_RESOURCES = 1149,
|
---|
195 | SVGA_3D_CMD_DX_SET_SHADER = 1150,
|
---|
196 | SVGA_3D_CMD_DX_SET_SAMPLERS = 1151,
|
---|
197 | SVGA_3D_CMD_DX_DRAW = 1152,
|
---|
198 | SVGA_3D_CMD_DX_DRAW_INDEXED = 1153,
|
---|
199 | SVGA_3D_CMD_DX_DRAW_INSTANCED = 1154,
|
---|
200 | SVGA_3D_CMD_DX_DRAW_INDEXED_INSTANCED = 1155,
|
---|
201 | SVGA_3D_CMD_DX_DRAW_AUTO = 1156,
|
---|
202 | SVGA_3D_CMD_DX_SET_INPUT_LAYOUT = 1157,
|
---|
203 | SVGA_3D_CMD_DX_SET_VERTEX_BUFFERS = 1158,
|
---|
204 | SVGA_3D_CMD_DX_SET_INDEX_BUFFER = 1159,
|
---|
205 | SVGA_3D_CMD_DX_SET_TOPOLOGY = 1160,
|
---|
206 | SVGA_3D_CMD_DX_SET_RENDERTARGETS = 1161,
|
---|
207 | SVGA_3D_CMD_DX_SET_BLEND_STATE = 1162,
|
---|
208 | SVGA_3D_CMD_DX_SET_DEPTHSTENCIL_STATE = 1163,
|
---|
209 | SVGA_3D_CMD_DX_SET_RASTERIZER_STATE = 1164,
|
---|
210 | SVGA_3D_CMD_DX_DEFINE_QUERY = 1165,
|
---|
211 | SVGA_3D_CMD_DX_DESTROY_QUERY = 1166,
|
---|
212 | SVGA_3D_CMD_DX_BIND_QUERY = 1167,
|
---|
213 | SVGA_3D_CMD_DX_SET_QUERY_OFFSET = 1168,
|
---|
214 | SVGA_3D_CMD_DX_BEGIN_QUERY = 1169,
|
---|
215 | SVGA_3D_CMD_DX_END_QUERY = 1170,
|
---|
216 | SVGA_3D_CMD_DX_READBACK_QUERY = 1171,
|
---|
217 | SVGA_3D_CMD_DX_SET_PREDICATION = 1172,
|
---|
218 | SVGA_3D_CMD_DX_SET_SOTARGETS = 1173,
|
---|
219 | SVGA_3D_CMD_DX_SET_VIEWPORTS = 1174,
|
---|
220 | SVGA_3D_CMD_DX_SET_SCISSORRECTS = 1175,
|
---|
221 | SVGA_3D_CMD_DX_CLEAR_RENDERTARGET_VIEW = 1176,
|
---|
222 | SVGA_3D_CMD_DX_CLEAR_DEPTHSTENCIL_VIEW = 1177,
|
---|
223 | SVGA_3D_CMD_DX_PRED_COPY_REGION = 1178,
|
---|
224 | SVGA_3D_CMD_DX_PRED_COPY = 1179,
|
---|
225 | SVGA_3D_CMD_DX_PRESENTBLT = 1180,
|
---|
226 | SVGA_3D_CMD_DX_GENMIPS = 1181,
|
---|
227 | SVGA_3D_CMD_DX_UPDATE_SUBRESOURCE = 1182,
|
---|
228 | SVGA_3D_CMD_DX_READBACK_SUBRESOURCE = 1183,
|
---|
229 | SVGA_3D_CMD_DX_INVALIDATE_SUBRESOURCE = 1184,
|
---|
230 | SVGA_3D_CMD_DX_DEFINE_SHADERRESOURCE_VIEW = 1185,
|
---|
231 | SVGA_3D_CMD_DX_DESTROY_SHADERRESOURCE_VIEW = 1186,
|
---|
232 | SVGA_3D_CMD_DX_DEFINE_RENDERTARGET_VIEW = 1187,
|
---|
233 | SVGA_3D_CMD_DX_DESTROY_RENDERTARGET_VIEW = 1188,
|
---|
234 | SVGA_3D_CMD_DX_DEFINE_DEPTHSTENCIL_VIEW = 1189,
|
---|
235 | SVGA_3D_CMD_DX_DESTROY_DEPTHSTENCIL_VIEW = 1190,
|
---|
236 | SVGA_3D_CMD_DX_DEFINE_ELEMENTLAYOUT = 1191,
|
---|
237 | SVGA_3D_CMD_DX_DESTROY_ELEMENTLAYOUT = 1192,
|
---|
238 | SVGA_3D_CMD_DX_DEFINE_BLEND_STATE = 1193,
|
---|
239 | SVGA_3D_CMD_DX_DESTROY_BLEND_STATE = 1194,
|
---|
240 | SVGA_3D_CMD_DX_DEFINE_DEPTHSTENCIL_STATE = 1195,
|
---|
241 | SVGA_3D_CMD_DX_DESTROY_DEPTHSTENCIL_STATE = 1196,
|
---|
242 | SVGA_3D_CMD_DX_DEFINE_RASTERIZER_STATE = 1197,
|
---|
243 | SVGA_3D_CMD_DX_DESTROY_RASTERIZER_STATE = 1198,
|
---|
244 | SVGA_3D_CMD_DX_DEFINE_SAMPLER_STATE = 1199,
|
---|
245 | SVGA_3D_CMD_DX_DESTROY_SAMPLER_STATE = 1200,
|
---|
246 | SVGA_3D_CMD_DX_DEFINE_SHADER = 1201,
|
---|
247 | SVGA_3D_CMD_DX_DESTROY_SHADER = 1202,
|
---|
248 | SVGA_3D_CMD_DX_BIND_SHADER = 1203,
|
---|
249 | SVGA_3D_CMD_DX_DEFINE_STREAMOUTPUT = 1204,
|
---|
250 | SVGA_3D_CMD_DX_DESTROY_STREAMOUTPUT = 1205,
|
---|
251 | SVGA_3D_CMD_DX_SET_STREAMOUTPUT = 1206,
|
---|
252 | SVGA_3D_CMD_DX_SET_COTABLE = 1207,
|
---|
253 | SVGA_3D_CMD_DX_READBACK_COTABLE = 1208,
|
---|
254 | SVGA_3D_CMD_DX_BUFFER_COPY = 1209,
|
---|
255 | SVGA_3D_CMD_DX_TRANSFER_FROM_BUFFER = 1210,
|
---|
256 | SVGA_3D_CMD_DX_SURFACE_COPY_AND_READBACK = 1211,
|
---|
257 | SVGA_3D_CMD_DX_MOVE_QUERY = 1212,
|
---|
258 | SVGA_3D_CMD_DX_BIND_ALL_QUERY = 1213,
|
---|
259 | SVGA_3D_CMD_DX_READBACK_ALL_QUERY = 1214,
|
---|
260 | SVGA_3D_CMD_DX_PRED_TRANSFER_FROM_BUFFER = 1215,
|
---|
261 | SVGA_3D_CMD_DX_MOB_FENCE_64 = 1216,
|
---|
262 | SVGA_3D_CMD_DX_BIND_ALL_SHADER = 1217,
|
---|
263 | SVGA_3D_CMD_DX_HINT = 1218,
|
---|
264 | SVGA_3D_CMD_DX_BUFFER_UPDATE = 1219,
|
---|
265 | SVGA_3D_CMD_DX_SET_VS_CONSTANT_BUFFER_OFFSET = 1220,
|
---|
266 | SVGA_3D_CMD_DX_SET_PS_CONSTANT_BUFFER_OFFSET = 1221,
|
---|
267 | SVGA_3D_CMD_DX_SET_GS_CONSTANT_BUFFER_OFFSET = 1222,
|
---|
268 | SVGA_3D_CMD_DX_SET_HS_CONSTANT_BUFFER_OFFSET = 1223,
|
---|
269 | SVGA_3D_CMD_DX_SET_DS_CONSTANT_BUFFER_OFFSET = 1224,
|
---|
270 | SVGA_3D_CMD_DX_SET_CS_CONSTANT_BUFFER_OFFSET = 1225,
|
---|
271 |
|
---|
272 | SVGA_3D_CMD_DX_COND_BIND_ALL_SHADER = 1226,
|
---|
273 | SVGA_3D_CMD_DX_MAX = 1227,
|
---|
274 |
|
---|
275 | SVGA_3D_CMD_SCREEN_COPY = 1227,
|
---|
276 |
|
---|
277 | SVGA_3D_CMD_RESERVED1 = 1228,
|
---|
278 | SVGA_3D_CMD_RESERVED2 = 1229,
|
---|
279 | SVGA_3D_CMD_RESERVED3 = 1230,
|
---|
280 | SVGA_3D_CMD_RESERVED4 = 1231,
|
---|
281 | SVGA_3D_CMD_RESERVED5 = 1232,
|
---|
282 | SVGA_3D_CMD_RESERVED6 = 1233,
|
---|
283 | SVGA_3D_CMD_RESERVED7 = 1234,
|
---|
284 | SVGA_3D_CMD_RESERVED8 = 1235,
|
---|
285 |
|
---|
286 | SVGA_3D_CMD_GROW_OTABLE = 1236,
|
---|
287 | SVGA_3D_CMD_DX_GROW_COTABLE = 1237,
|
---|
288 | SVGA_3D_CMD_INTRA_SURFACE_COPY = 1238,
|
---|
289 |
|
---|
290 | SVGA_3D_CMD_DEFINE_GB_SURFACE_V3 = 1239,
|
---|
291 |
|
---|
292 | SVGA_3D_CMD_DX_RESOLVE_COPY = 1240,
|
---|
293 | SVGA_3D_CMD_DX_PRED_RESOLVE_COPY = 1241,
|
---|
294 | SVGA_3D_CMD_DX_PRED_CONVERT_REGION = 1242,
|
---|
295 | SVGA_3D_CMD_DX_PRED_CONVERT = 1243,
|
---|
296 | SVGA_3D_CMD_WHOLE_SURFACE_COPY = 1244,
|
---|
297 |
|
---|
298 | SVGA_3D_CMD_DX_DEFINE_UA_VIEW = 1245,
|
---|
299 | SVGA_3D_CMD_DX_DESTROY_UA_VIEW = 1246,
|
---|
300 | SVGA_3D_CMD_DX_CLEAR_UA_VIEW_UINT = 1247,
|
---|
301 | SVGA_3D_CMD_DX_CLEAR_UA_VIEW_FLOAT = 1248,
|
---|
302 | SVGA_3D_CMD_DX_COPY_STRUCTURE_COUNT = 1249,
|
---|
303 | SVGA_3D_CMD_DX_SET_UA_VIEWS = 1250,
|
---|
304 |
|
---|
305 | SVGA_3D_CMD_DX_DRAW_INDEXED_INSTANCED_INDIRECT = 1251,
|
---|
306 | SVGA_3D_CMD_DX_DRAW_INSTANCED_INDIRECT = 1252,
|
---|
307 | SVGA_3D_CMD_DX_DISPATCH = 1253,
|
---|
308 | SVGA_3D_CMD_DX_DISPATCH_INDIRECT = 1254,
|
---|
309 |
|
---|
310 | SVGA_3D_CMD_WRITE_ZERO_SURFACE = 1255,
|
---|
311 | SVGA_3D_CMD_HINT_ZERO_SURFACE = 1256,
|
---|
312 | SVGA_3D_CMD_DX_TRANSFER_TO_BUFFER = 1257,
|
---|
313 | SVGA_3D_CMD_DX_SET_STRUCTURE_COUNT = 1258,
|
---|
314 |
|
---|
315 | SVGA_3D_CMD_LOGICOPS_BITBLT = 1259,
|
---|
316 | SVGA_3D_CMD_LOGICOPS_TRANSBLT = 1260,
|
---|
317 | SVGA_3D_CMD_LOGICOPS_STRETCHBLT = 1261,
|
---|
318 | SVGA_3D_CMD_LOGICOPS_COLORFILL = 1262,
|
---|
319 | SVGA_3D_CMD_LOGICOPS_ALPHABLEND = 1263,
|
---|
320 | SVGA_3D_CMD_LOGICOPS_CLEARTYPEBLEND = 1264,
|
---|
321 |
|
---|
322 | SVGA_3D_CMD_RESERVED2_1 = 1265,
|
---|
323 |
|
---|
324 | SVGA_3D_CMD_RESERVED2_2 = 1266,
|
---|
325 | SVGA_3D_CMD_DEFINE_GB_SURFACE_V4 = 1267,
|
---|
326 | SVGA_3D_CMD_DX_SET_CS_UA_VIEWS = 1268,
|
---|
327 | SVGA_3D_CMD_DX_SET_MIN_LOD = 1269,
|
---|
328 | SVGA_3D_CMD_RESERVED2_3 = 1270,
|
---|
329 | SVGA_3D_CMD_RESERVED2_4 = 1271,
|
---|
330 | SVGA_3D_CMD_DX_DEFINE_DEPTHSTENCIL_VIEW_V2 = 1272,
|
---|
331 | SVGA_3D_CMD_DX_DEFINE_STREAMOUTPUT_WITH_MOB = 1273,
|
---|
332 | SVGA_3D_CMD_DX_SET_SHADER_IFACE = 1274,
|
---|
333 | SVGA_3D_CMD_DX_BIND_STREAMOUTPUT = 1275,
|
---|
334 | SVGA_3D_CMD_SURFACE_STRETCHBLT_NON_MS_TO_MS = 1276,
|
---|
335 | SVGA_3D_CMD_DX_BIND_SHADER_IFACE = 1277,
|
---|
336 |
|
---|
337 | SVGA_3D_CMD_MAX = 1278,
|
---|
338 | SVGA_3D_CMD_FUTURE_MAX = 3000
|
---|
339 | } SVGAFifo3dCmdId;
|
---|
340 |
|
---|
341 | #define SVGA_NUM_3D_CMD (SVGA_3D_CMD_MAX - SVGA_3D_CMD_BASE)
|
---|
342 |
|
---|
343 | /*
|
---|
344 | * FIFO command format definitions:
|
---|
345 | */
|
---|
346 |
|
---|
347 | /*
|
---|
348 | * The data size header following cmdNum for every 3d command
|
---|
349 | */
|
---|
350 | typedef
|
---|
351 | #include "vmware_pack_begin.h"
|
---|
352 | struct {
|
---|
353 | uint32 id;
|
---|
354 | uint32 size;
|
---|
355 | }
|
---|
356 | #include "vmware_pack_end.h"
|
---|
357 | SVGA3dCmdHeader;
|
---|
358 |
|
---|
359 | typedef
|
---|
360 | #include "vmware_pack_begin.h"
|
---|
361 | struct {
|
---|
362 | uint32 numMipLevels;
|
---|
363 | }
|
---|
364 | #include "vmware_pack_end.h"
|
---|
365 | SVGA3dSurfaceFace;
|
---|
366 |
|
---|
367 | typedef
|
---|
368 | #include "vmware_pack_begin.h"
|
---|
369 | struct {
|
---|
370 | uint32 sid;
|
---|
371 | SVGA3dSurface1Flags surfaceFlags;
|
---|
372 | SVGA3dSurfaceFormat format;
|
---|
373 |
|
---|
374 | /*
|
---|
375 | * If surfaceFlags has SVGA3D_SURFACE_CUBEMAP bit set, all SVGA3dSurfaceFace
|
---|
376 | * structures must have the same value of numMipLevels field.
|
---|
377 | * Otherwise, all but the first SVGA3dSurfaceFace structures must have the
|
---|
378 | * numMipLevels set to 0.
|
---|
379 | */
|
---|
380 | SVGA3dSurfaceFace face[SVGA3D_MAX_SURFACE_FACES];
|
---|
381 |
|
---|
382 | /*
|
---|
383 | * Followed by an SVGA3dSize structure for each mip level in each face.
|
---|
384 | *
|
---|
385 | * A note on surface sizes: Sizes are always specified in pixels,
|
---|
386 | * even if the true surface size is not a multiple of the minimum
|
---|
387 | * block size of the surface's format. For example, a 3x3x1 DXT1
|
---|
388 | * compressed texture would actually be stored as a 4x4x1 image in
|
---|
389 | * memory.
|
---|
390 | */
|
---|
391 | }
|
---|
392 | #include "vmware_pack_end.h"
|
---|
393 | SVGA3dCmdDefineSurface; /* SVGA_3D_CMD_SURFACE_DEFINE */
|
---|
394 |
|
---|
395 | typedef
|
---|
396 | #include "vmware_pack_begin.h"
|
---|
397 | struct {
|
---|
398 | uint32 sid;
|
---|
399 | SVGA3dSurface1Flags surfaceFlags;
|
---|
400 | SVGA3dSurfaceFormat format;
|
---|
401 |
|
---|
402 | /*
|
---|
403 | * If surfaceFlags has SVGA3D_SURFACE_CUBEMAP bit set, all SVGA3dSurfaceFace
|
---|
404 | * structures must have the same value of numMipLevels field.
|
---|
405 | * Otherwise, all but the first SVGA3dSurfaceFace structures must have the
|
---|
406 | * numMipLevels set to 0.
|
---|
407 | */
|
---|
408 | SVGA3dSurfaceFace face[SVGA3D_MAX_SURFACE_FACES];
|
---|
409 | uint32 multisampleCount;
|
---|
410 | SVGA3dTextureFilter autogenFilter;
|
---|
411 |
|
---|
412 | /*
|
---|
413 | * Followed by an SVGA3dSize structure for each mip level in each face.
|
---|
414 | *
|
---|
415 | * A note on surface sizes: Sizes are always specified in pixels,
|
---|
416 | * even if the true surface size is not a multiple of the minimum
|
---|
417 | * block size of the surface's format. For example, a 3x3x1 DXT1
|
---|
418 | * compressed texture would actually be stored as a 4x4x1 image in
|
---|
419 | * memory.
|
---|
420 | */
|
---|
421 | }
|
---|
422 | #include "vmware_pack_end.h"
|
---|
423 | SVGA3dCmdDefineSurface_v2; /* SVGA_3D_CMD_SURFACE_DEFINE_V2 */
|
---|
424 |
|
---|
425 | typedef
|
---|
426 | #include "vmware_pack_begin.h"
|
---|
427 | struct {
|
---|
428 | uint32 sid;
|
---|
429 | }
|
---|
430 | #include "vmware_pack_end.h"
|
---|
431 | SVGA3dCmdDestroySurface; /* SVGA_3D_CMD_SURFACE_DESTROY */
|
---|
432 |
|
---|
433 | typedef
|
---|
434 | #include "vmware_pack_begin.h"
|
---|
435 | struct {
|
---|
436 | uint32 cid;
|
---|
437 | }
|
---|
438 | #include "vmware_pack_end.h"
|
---|
439 | SVGA3dCmdDefineContext; /* SVGA_3D_CMD_CONTEXT_DEFINE */
|
---|
440 |
|
---|
441 | typedef
|
---|
442 | #include "vmware_pack_begin.h"
|
---|
443 | struct {
|
---|
444 | uint32 cid;
|
---|
445 | }
|
---|
446 | #include "vmware_pack_end.h"
|
---|
447 | SVGA3dCmdDestroyContext; /* SVGA_3D_CMD_CONTEXT_DESTROY */
|
---|
448 |
|
---|
449 | typedef
|
---|
450 | #include "vmware_pack_begin.h"
|
---|
451 | struct {
|
---|
452 | uint32 cid;
|
---|
453 | SVGA3dClearFlag clearFlag;
|
---|
454 | uint32 color;
|
---|
455 | float depth;
|
---|
456 | uint32 stencil;
|
---|
457 | /* Followed by variable number of SVGA3dRect structures */
|
---|
458 | }
|
---|
459 | #include "vmware_pack_end.h"
|
---|
460 | SVGA3dCmdClear; /* SVGA_3D_CMD_CLEAR */
|
---|
461 |
|
---|
462 | typedef
|
---|
463 | #include "vmware_pack_begin.h"
|
---|
464 | struct {
|
---|
465 | SVGA3dLightType type;
|
---|
466 | SVGA3dBool inWorldSpace;
|
---|
467 | float diffuse[4];
|
---|
468 | float specular[4];
|
---|
469 | float ambient[4];
|
---|
470 | float position[4];
|
---|
471 | float direction[4];
|
---|
472 | float range;
|
---|
473 | float falloff;
|
---|
474 | float attenuation0;
|
---|
475 | float attenuation1;
|
---|
476 | float attenuation2;
|
---|
477 | float theta;
|
---|
478 | float phi;
|
---|
479 | }
|
---|
480 | #include "vmware_pack_end.h"
|
---|
481 | SVGA3dLightData;
|
---|
482 |
|
---|
483 | typedef
|
---|
484 | #include "vmware_pack_begin.h"
|
---|
485 | struct {
|
---|
486 | uint32 sid;
|
---|
487 | /* Followed by variable number of SVGA3dCopyRect structures */
|
---|
488 | }
|
---|
489 | #include "vmware_pack_end.h"
|
---|
490 | SVGA3dCmdPresent; /* SVGA_3D_CMD_PRESENT */
|
---|
491 |
|
---|
492 | typedef
|
---|
493 | #include "vmware_pack_begin.h"
|
---|
494 | struct {
|
---|
495 | SVGA3dRenderStateName state;
|
---|
496 | union {
|
---|
497 | uint32 uintValue;
|
---|
498 | float floatValue;
|
---|
499 | };
|
---|
500 | }
|
---|
501 | #include "vmware_pack_end.h"
|
---|
502 | SVGA3dRenderState;
|
---|
503 |
|
---|
504 | typedef
|
---|
505 | #include "vmware_pack_begin.h"
|
---|
506 | struct {
|
---|
507 | uint32 cid;
|
---|
508 | /* Followed by variable number of SVGA3dRenderState structures */
|
---|
509 | }
|
---|
510 | #include "vmware_pack_end.h"
|
---|
511 | SVGA3dCmdSetRenderState; /* SVGA_3D_CMD_SETRENDERSTATE */
|
---|
512 |
|
---|
513 | typedef
|
---|
514 | #include "vmware_pack_begin.h"
|
---|
515 | struct {
|
---|
516 | uint32 cid;
|
---|
517 | SVGA3dRenderTargetType type;
|
---|
518 | SVGA3dSurfaceImageId target;
|
---|
519 | }
|
---|
520 | #include "vmware_pack_end.h"
|
---|
521 | SVGA3dCmdSetRenderTarget; /* SVGA_3D_CMD_SETRENDERTARGET */
|
---|
522 |
|
---|
523 | typedef
|
---|
524 | #include "vmware_pack_begin.h"
|
---|
525 | struct {
|
---|
526 | SVGA3dSurfaceImageId src;
|
---|
527 | SVGA3dSurfaceImageId dest;
|
---|
528 | /* Followed by variable number of SVGA3dCopyBox structures */
|
---|
529 | }
|
---|
530 | #include "vmware_pack_end.h"
|
---|
531 | SVGA3dCmdSurfaceCopy; /* SVGA_3D_CMD_SURFACE_COPY */
|
---|
532 |
|
---|
533 | /*
|
---|
534 | * Perform a surface copy within the same image.
|
---|
535 | * The src/dest boxes are allowed to overlap.
|
---|
536 | */
|
---|
537 | typedef
|
---|
538 | #include "vmware_pack_begin.h"
|
---|
539 | struct {
|
---|
540 | SVGA3dSurfaceImageId surface;
|
---|
541 | SVGA3dCopyBox box;
|
---|
542 | }
|
---|
543 | #include "vmware_pack_end.h"
|
---|
544 | SVGA3dCmdIntraSurfaceCopy; /* SVGA_3D_CMD_INTRA_SURFACE_COPY */
|
---|
545 |
|
---|
546 | typedef
|
---|
547 | #include "vmware_pack_begin.h"
|
---|
548 | struct {
|
---|
549 | uint32 srcSid;
|
---|
550 | uint32 destSid;
|
---|
551 | }
|
---|
552 | #include "vmware_pack_end.h"
|
---|
553 | SVGA3dCmdWholeSurfaceCopy; /* SVGA_3D_CMD_WHOLE_SURFACE_COPY */
|
---|
554 |
|
---|
555 | typedef
|
---|
556 | #include "vmware_pack_begin.h"
|
---|
557 | struct {
|
---|
558 | SVGA3dSurfaceImageId src;
|
---|
559 | SVGA3dSurfaceImageId dest;
|
---|
560 | SVGA3dBox boxSrc;
|
---|
561 | SVGA3dBox boxDest;
|
---|
562 | }
|
---|
563 | #include "vmware_pack_end.h"
|
---|
564 | SVGA3dCmdSurfaceStretchBltNonMSToMS;
|
---|
565 | /* SVGA_3D_CMD_SURFACE_STRETCHBLT_NON_MS_TO_MS */
|
---|
566 |
|
---|
567 | typedef
|
---|
568 | #include "vmware_pack_begin.h"
|
---|
569 | struct {
|
---|
570 | SVGA3dSurfaceImageId src;
|
---|
571 | SVGA3dSurfaceImageId dest;
|
---|
572 | SVGA3dBox boxSrc;
|
---|
573 | SVGA3dBox boxDest;
|
---|
574 | SVGA3dStretchBltMode mode;
|
---|
575 | }
|
---|
576 | #include "vmware_pack_end.h"
|
---|
577 | SVGA3dCmdSurfaceStretchBlt; /* SVGA_3D_CMD_SURFACE_STRETCHBLT */
|
---|
578 |
|
---|
579 | typedef
|
---|
580 | #include "vmware_pack_begin.h"
|
---|
581 | struct {
|
---|
582 | /*
|
---|
583 | * If the discard flag is present in a surface DMA operation, the host may
|
---|
584 | * discard the contents of the current mipmap level and face of the target
|
---|
585 | * surface before applying the surface DMA contents.
|
---|
586 | */
|
---|
587 | uint32 discard : 1;
|
---|
588 |
|
---|
589 | /*
|
---|
590 | * If the unsynchronized flag is present, the host may perform this upload
|
---|
591 | * without syncing to pending reads on this surface.
|
---|
592 | */
|
---|
593 | uint32 unsynchronized : 1;
|
---|
594 |
|
---|
595 | /*
|
---|
596 | * Guests *MUST* set the reserved bits to 0 before submitting the command
|
---|
597 | * suffix as future flags may occupy these bits.
|
---|
598 | */
|
---|
599 | uint32 reserved : 30;
|
---|
600 | }
|
---|
601 | #include "vmware_pack_end.h"
|
---|
602 | SVGA3dSurfaceDMAFlags;
|
---|
603 |
|
---|
604 | typedef
|
---|
605 | #include "vmware_pack_begin.h"
|
---|
606 | struct {
|
---|
607 | SVGAGuestImage guest;
|
---|
608 | SVGA3dSurfaceImageId host;
|
---|
609 | SVGA3dTransferType transfer;
|
---|
610 |
|
---|
611 | /*
|
---|
612 | * Followed by variable number of SVGA3dCopyBox structures. For consistency
|
---|
613 | * in all clipping logic and coordinate translation, we define the
|
---|
614 | * "source" in each copyBox as the guest image and the
|
---|
615 | * "destination" as the host image, regardless of transfer
|
---|
616 | * direction.
|
---|
617 | *
|
---|
618 | * For efficiency, the SVGA3D device is free to copy more data than
|
---|
619 | * specified. For example, it may round copy boxes outwards such
|
---|
620 | * that they lie on particular alignment boundaries.
|
---|
621 | */
|
---|
622 | }
|
---|
623 | #include "vmware_pack_end.h"
|
---|
624 | SVGA3dCmdSurfaceDMA; /* SVGA_3D_CMD_SURFACE_DMA */
|
---|
625 |
|
---|
626 | /*
|
---|
627 | * SVGA3dCmdSurfaceDMASuffix --
|
---|
628 | *
|
---|
629 | * This is a command suffix that will appear after a SurfaceDMA command in
|
---|
630 | * the FIFO. It contains some extra information that hosts may use to
|
---|
631 | * optimize performance or protect the guest. This suffix exists to preserve
|
---|
632 | * backwards compatibility while also allowing for new functionality to be
|
---|
633 | * implemented.
|
---|
634 | */
|
---|
635 |
|
---|
636 | typedef
|
---|
637 | #include "vmware_pack_begin.h"
|
---|
638 | struct {
|
---|
639 | uint32 suffixSize;
|
---|
640 |
|
---|
641 | /*
|
---|
642 | * The maximum offset is used to determine the maximum offset from the
|
---|
643 | * guestPtr base address that will be accessed or written to during this
|
---|
644 | * surfaceDMA. If the suffix is supported, the host will respect this
|
---|
645 | * boundary while performing surface DMAs.
|
---|
646 | *
|
---|
647 | * Defaults to MAX_UINT32
|
---|
648 | */
|
---|
649 | uint32 maximumOffset;
|
---|
650 |
|
---|
651 | /*
|
---|
652 | * A set of flags that describes optimizations that the host may perform
|
---|
653 | * while performing this surface DMA operation. The guest should never rely
|
---|
654 | * on behaviour that is different when these flags are set for correctness.
|
---|
655 | *
|
---|
656 | * Defaults to 0
|
---|
657 | */
|
---|
658 | SVGA3dSurfaceDMAFlags flags;
|
---|
659 | }
|
---|
660 | #include "vmware_pack_end.h"
|
---|
661 | SVGA3dCmdSurfaceDMASuffix;
|
---|
662 |
|
---|
663 | /*
|
---|
664 | * SVGA_3D_CMD_DRAW_PRIMITIVES --
|
---|
665 | *
|
---|
666 | * This command is the SVGA3D device's generic drawing entry point.
|
---|
667 | * It can draw multiple ranges of primitives, optionally using an
|
---|
668 | * index buffer, using an arbitrary collection of vertex buffers.
|
---|
669 | *
|
---|
670 | * Each SVGA3dVertexDecl defines a distinct vertex array to bind
|
---|
671 | * during this draw call. The declarations specify which surface
|
---|
672 | * the vertex data lives in, what that vertex data is used for,
|
---|
673 | * and how to interpret it.
|
---|
674 | *
|
---|
675 | * Each SVGA3dPrimitiveRange defines a collection of primitives
|
---|
676 | * to render using the same vertex arrays. An index buffer is
|
---|
677 | * optional.
|
---|
678 | */
|
---|
679 |
|
---|
680 | typedef
|
---|
681 | #include "vmware_pack_begin.h"
|
---|
682 | struct {
|
---|
683 | /*
|
---|
684 | * A range hint is an optional specification for the range of indices
|
---|
685 | * in an SVGA3dArray that will be used. If 'last' is zero, it is assumed
|
---|
686 | * that the entire array will be used.
|
---|
687 | *
|
---|
688 | * These are only hints. The SVGA3D device may use them for
|
---|
689 | * performance optimization if possible, but it's also allowed to
|
---|
690 | * ignore these values.
|
---|
691 | */
|
---|
692 | uint32 first;
|
---|
693 | uint32 last;
|
---|
694 | }
|
---|
695 | #include "vmware_pack_end.h"
|
---|
696 | SVGA3dArrayRangeHint;
|
---|
697 |
|
---|
698 | typedef
|
---|
699 | #include "vmware_pack_begin.h"
|
---|
700 | struct {
|
---|
701 | /*
|
---|
702 | * Define the origin and shape of a vertex or index array. Both
|
---|
703 | * 'offset' and 'stride' are in bytes. The provided surface will be
|
---|
704 | * reinterpreted as a flat array of bytes in the same format used
|
---|
705 | * by surface DMA operations. To avoid unnecessary conversions, the
|
---|
706 | * surface should be created with the SVGA3D_BUFFER format.
|
---|
707 | *
|
---|
708 | * Index 0 in the array starts 'offset' bytes into the surface.
|
---|
709 | * Index 1 begins at byte 'offset + stride', etc. Array indices may
|
---|
710 | * not be negative.
|
---|
711 | */
|
---|
712 | uint32 surfaceId;
|
---|
713 | uint32 offset;
|
---|
714 | uint32 stride;
|
---|
715 | }
|
---|
716 | #include "vmware_pack_end.h"
|
---|
717 | SVGA3dArray;
|
---|
718 |
|
---|
719 | typedef
|
---|
720 | #include "vmware_pack_begin.h"
|
---|
721 | struct {
|
---|
722 | /*
|
---|
723 | * Describe a vertex array's data type, and define how it is to be
|
---|
724 | * used by the fixed function pipeline or the vertex shader. It
|
---|
725 | * isn't useful to have two VertexDecls with the same
|
---|
726 | * VertexArrayIdentity in one draw call.
|
---|
727 | */
|
---|
728 | SVGA3dDeclType type;
|
---|
729 | SVGA3dDeclMethod method;
|
---|
730 | SVGA3dDeclUsage usage;
|
---|
731 | uint32 usageIndex;
|
---|
732 | }
|
---|
733 | #include "vmware_pack_end.h"
|
---|
734 | SVGA3dVertexArrayIdentity;
|
---|
735 |
|
---|
736 | typedef
|
---|
737 | #include "vmware_pack_begin.h"
|
---|
738 | struct SVGA3dVertexDecl {
|
---|
739 | SVGA3dVertexArrayIdentity identity;
|
---|
740 | SVGA3dArray array;
|
---|
741 | SVGA3dArrayRangeHint rangeHint;
|
---|
742 | }
|
---|
743 | #include "vmware_pack_end.h"
|
---|
744 | SVGA3dVertexDecl;
|
---|
745 |
|
---|
746 | typedef
|
---|
747 | #include "vmware_pack_begin.h"
|
---|
748 | struct SVGA3dPrimitiveRange {
|
---|
749 | /*
|
---|
750 | * Define a group of primitives to render, from sequential indices.
|
---|
751 | *
|
---|
752 | * The value of 'primitiveType' and 'primitiveCount' imply the
|
---|
753 | * total number of vertices that will be rendered.
|
---|
754 | */
|
---|
755 | SVGA3dPrimitiveType primType;
|
---|
756 | uint32 primitiveCount;
|
---|
757 |
|
---|
758 | /*
|
---|
759 | * Optional index buffer. If indexArray.surfaceId is
|
---|
760 | * SVGA3D_INVALID_ID, we render without an index buffer. Rendering
|
---|
761 | * without an index buffer is identical to rendering with an index
|
---|
762 | * buffer containing the sequence [0, 1, 2, 3, ...].
|
---|
763 | *
|
---|
764 | * If an index buffer is in use, indexWidth specifies the width in
|
---|
765 | * bytes of each index value. It must be less than or equal to
|
---|
766 | * indexArray.stride.
|
---|
767 | *
|
---|
768 | * (Currently, the SVGA3D device requires index buffers to be tightly
|
---|
769 | * packed. In other words, indexWidth == indexArray.stride)
|
---|
770 | */
|
---|
771 | SVGA3dArray indexArray;
|
---|
772 | uint32 indexWidth;
|
---|
773 |
|
---|
774 | /*
|
---|
775 | * Optional index bias. This number is added to all indices from
|
---|
776 | * indexArray before they are used as vertex array indices. This
|
---|
777 | * can be used in multiple ways:
|
---|
778 | *
|
---|
779 | * - When not using an indexArray, this bias can be used to
|
---|
780 | * specify where in the vertex arrays to begin rendering.
|
---|
781 | *
|
---|
782 | * - A positive number here is equivalent to increasing the
|
---|
783 | * offset in each vertex array.
|
---|
784 | *
|
---|
785 | * - A negative number can be used to render using a small
|
---|
786 | * vertex array and an index buffer that contains large
|
---|
787 | * values. This may be used by some applications that
|
---|
788 | * crop a vertex buffer without modifying their index
|
---|
789 | * buffer.
|
---|
790 | *
|
---|
791 | * Note that rendering with a negative bias value may be slower and
|
---|
792 | * use more memory than rendering with a positive or zero bias.
|
---|
793 | */
|
---|
794 | int32 indexBias;
|
---|
795 | }
|
---|
796 | #include "vmware_pack_end.h"
|
---|
797 | SVGA3dPrimitiveRange;
|
---|
798 |
|
---|
799 | typedef
|
---|
800 | #include "vmware_pack_begin.h"
|
---|
801 | struct {
|
---|
802 | uint32 cid;
|
---|
803 | uint32 numVertexDecls;
|
---|
804 | uint32 numRanges;
|
---|
805 |
|
---|
806 | /*
|
---|
807 | * There are two variable size arrays after the
|
---|
808 | * SVGA3dCmdDrawPrimitives structure. In order,
|
---|
809 | * they are:
|
---|
810 | *
|
---|
811 | * 1. SVGA3dVertexDecl, quantity 'numVertexDecls', but no more than
|
---|
812 | * SVGA3D_MAX_VERTEX_ARRAYS;
|
---|
813 | * 2. SVGA3dPrimitiveRange, quantity 'numRanges', but no more than
|
---|
814 | * SVGA3D_MAX_DRAW_PRIMITIVE_RANGES;
|
---|
815 | * 3. Optionally, SVGA3dVertexDivisor, quantity 'numVertexDecls' (contains
|
---|
816 | * the frequency divisor for the corresponding vertex decl).
|
---|
817 | */
|
---|
818 | }
|
---|
819 | #include "vmware_pack_end.h"
|
---|
820 | SVGA3dCmdDrawPrimitives; /* SVGA_3D_CMD_DRAWPRIMITIVES */
|
---|
821 |
|
---|
822 | typedef
|
---|
823 | #include "vmware_pack_begin.h"
|
---|
824 | struct {
|
---|
825 | uint32 cid;
|
---|
826 |
|
---|
827 | uint32 primitiveCount; /* How many primitives to render */
|
---|
828 | uint32 startVertexLocation; /* Which vertex do we start rendering at. */
|
---|
829 |
|
---|
830 | uint8 primitiveType; /* SVGA3dPrimitiveType */
|
---|
831 | uint8 padding[3];
|
---|
832 | }
|
---|
833 | #include "vmware_pack_end.h"
|
---|
834 | SVGA3dCmdDraw;
|
---|
835 |
|
---|
836 | typedef
|
---|
837 | #include "vmware_pack_begin.h"
|
---|
838 | struct {
|
---|
839 | uint32 cid;
|
---|
840 |
|
---|
841 | uint8 primitiveType; /* SVGA3dPrimitiveType */
|
---|
842 |
|
---|
843 | uint32 indexBufferSid; /* Valid index buffer sid. */
|
---|
844 | uint32 indexBufferOffset; /* Byte offset into the vertex buffer, almost */
|
---|
845 | /* always 0 for pre SM guests, non-zero for OpenGL */
|
---|
846 | /* guests. We can't represent non-multiple of */
|
---|
847 | /* stride offsets in D3D9Renderer... */
|
---|
848 | uint8 indexBufferStride; /* Allowable values = 1, 2, or 4 */
|
---|
849 |
|
---|
850 | int32 baseVertexLocation; /* Bias applied to the index when selecting a */
|
---|
851 | /* vertex from the streams, may be negative */
|
---|
852 |
|
---|
853 | uint32 primitiveCount; /* How many primitives to render */
|
---|
854 | uint32 pad0;
|
---|
855 | uint16 pad1;
|
---|
856 | }
|
---|
857 | #include "vmware_pack_end.h"
|
---|
858 | SVGA3dCmdDrawIndexed;
|
---|
859 |
|
---|
860 | typedef
|
---|
861 | #include "vmware_pack_begin.h"
|
---|
862 | struct {
|
---|
863 | /*
|
---|
864 | * Describe a vertex array's data type, and define how it is to be
|
---|
865 | * used by the fixed function pipeline or the vertex shader. It
|
---|
866 | * isn't useful to have two VertexDecls with the same
|
---|
867 | * VertexArrayIdentity in one draw call.
|
---|
868 | */
|
---|
869 | uint16 streamOffset;
|
---|
870 | uint8 stream;
|
---|
871 | uint8 type; /* SVGA3dDeclType */
|
---|
872 | uint8 method; /* SVGA3dDeclMethod */
|
---|
873 | uint8 usage; /* SVGA3dDeclUsage */
|
---|
874 | uint8 usageIndex;
|
---|
875 | uint8 padding;
|
---|
876 |
|
---|
877 | }
|
---|
878 | #include "vmware_pack_end.h"
|
---|
879 | SVGA3dVertexElement;
|
---|
880 |
|
---|
881 | /*
|
---|
882 | * Should the vertex element respect the stream value? The high bit of the
|
---|
883 | * stream should be set to indicate that the stream should be respected. If
|
---|
884 | * the high bit is not set, the stream will be ignored and replaced by the index
|
---|
885 | * of the position of the currently considered vertex element.
|
---|
886 | *
|
---|
887 | * All guests should set this bit and correctly specify the stream going
|
---|
888 | * forward.
|
---|
889 | */
|
---|
890 | #define SVGA3D_VERTEX_ELEMENT_RESPECT_STREAM (1 << 7)
|
---|
891 |
|
---|
892 | typedef
|
---|
893 | #include "vmware_pack_begin.h"
|
---|
894 | struct {
|
---|
895 | uint32 cid;
|
---|
896 |
|
---|
897 | uint32 numElements;
|
---|
898 |
|
---|
899 | /*
|
---|
900 | * Followed by numElements SVGA3dVertexElement structures.
|
---|
901 | *
|
---|
902 | * If numElements < SVGA3D_MAX_VERTEX_ARRAYS, the remaining elements
|
---|
903 | * are cleared and will not be used by following draws.
|
---|
904 | */
|
---|
905 | }
|
---|
906 | #include "vmware_pack_end.h"
|
---|
907 | SVGA3dCmdSetVertexDecls;
|
---|
908 |
|
---|
909 | typedef
|
---|
910 | #include "vmware_pack_begin.h"
|
---|
911 | struct {
|
---|
912 | uint32 sid;
|
---|
913 | uint32 stride;
|
---|
914 | uint32 offset;
|
---|
915 | }
|
---|
916 | #include "vmware_pack_end.h"
|
---|
917 | SVGA3dVertexStream;
|
---|
918 |
|
---|
919 | typedef
|
---|
920 | #include "vmware_pack_begin.h"
|
---|
921 | struct {
|
---|
922 | uint32 cid;
|
---|
923 |
|
---|
924 | uint32 numStreams;
|
---|
925 | /*
|
---|
926 | * Followed by numStream SVGA3dVertexStream structures.
|
---|
927 | *
|
---|
928 | * If numStreams < SVGA3D_MAX_VERTEX_ARRAYS, the remaining streams
|
---|
929 | * are cleared and will not be used by following draws.
|
---|
930 | */
|
---|
931 | }
|
---|
932 | #include "vmware_pack_end.h"
|
---|
933 | SVGA3dCmdSetVertexStreams;
|
---|
934 |
|
---|
935 | typedef
|
---|
936 | #include "vmware_pack_begin.h"
|
---|
937 | struct {
|
---|
938 | uint32 cid;
|
---|
939 | uint32 numDivisors;
|
---|
940 | }
|
---|
941 | #include "vmware_pack_end.h"
|
---|
942 | SVGA3dCmdSetVertexDivisors;
|
---|
943 |
|
---|
944 | typedef
|
---|
945 | #include "vmware_pack_begin.h"
|
---|
946 | struct {
|
---|
947 | uint32 stage;
|
---|
948 | SVGA3dTextureStateName name;
|
---|
949 | union {
|
---|
950 | uint32 value;
|
---|
951 | float floatValue;
|
---|
952 | };
|
---|
953 | }
|
---|
954 | #include "vmware_pack_end.h"
|
---|
955 | SVGA3dTextureState;
|
---|
956 |
|
---|
957 | typedef
|
---|
958 | #include "vmware_pack_begin.h"
|
---|
959 | struct {
|
---|
960 | uint32 cid;
|
---|
961 | /* Followed by variable number of SVGA3dTextureState structures */
|
---|
962 | }
|
---|
963 | #include "vmware_pack_end.h"
|
---|
964 | SVGA3dCmdSetTextureState; /* SVGA_3D_CMD_SETTEXTURESTATE */
|
---|
965 |
|
---|
966 | typedef
|
---|
967 | #include "vmware_pack_begin.h"
|
---|
968 | struct {
|
---|
969 | uint32 cid;
|
---|
970 | SVGA3dTransformType type;
|
---|
971 | float matrix[16];
|
---|
972 | }
|
---|
973 | #include "vmware_pack_end.h"
|
---|
974 | SVGA3dCmdSetTransform; /* SVGA_3D_CMD_SETTRANSFORM */
|
---|
975 |
|
---|
976 | typedef
|
---|
977 | #include "vmware_pack_begin.h"
|
---|
978 | struct {
|
---|
979 | float min;
|
---|
980 | float max;
|
---|
981 | }
|
---|
982 | #include "vmware_pack_end.h"
|
---|
983 | SVGA3dZRange;
|
---|
984 |
|
---|
985 | typedef
|
---|
986 | #include "vmware_pack_begin.h"
|
---|
987 | struct {
|
---|
988 | uint32 cid;
|
---|
989 | SVGA3dZRange zRange;
|
---|
990 | }
|
---|
991 | #include "vmware_pack_end.h"
|
---|
992 | SVGA3dCmdSetZRange; /* SVGA_3D_CMD_SETZRANGE */
|
---|
993 |
|
---|
994 | typedef
|
---|
995 | #include "vmware_pack_begin.h"
|
---|
996 | struct {
|
---|
997 | float diffuse[4];
|
---|
998 | float ambient[4];
|
---|
999 | float specular[4];
|
---|
1000 | float emissive[4];
|
---|
1001 | float shininess;
|
---|
1002 | }
|
---|
1003 | #include "vmware_pack_end.h"
|
---|
1004 | SVGA3dMaterial;
|
---|
1005 |
|
---|
1006 | typedef
|
---|
1007 | #include "vmware_pack_begin.h"
|
---|
1008 | struct {
|
---|
1009 | uint32 cid;
|
---|
1010 | SVGA3dFace face;
|
---|
1011 | SVGA3dMaterial material;
|
---|
1012 | }
|
---|
1013 | #include "vmware_pack_end.h"
|
---|
1014 | SVGA3dCmdSetMaterial; /* SVGA_3D_CMD_SETMATERIAL */
|
---|
1015 |
|
---|
1016 | typedef
|
---|
1017 | #include "vmware_pack_begin.h"
|
---|
1018 | struct {
|
---|
1019 | uint32 cid;
|
---|
1020 | uint32 index;
|
---|
1021 | SVGA3dLightData data;
|
---|
1022 | }
|
---|
1023 | #include "vmware_pack_end.h"
|
---|
1024 | SVGA3dCmdSetLightData; /* SVGA_3D_CMD_SETLIGHTDATA */
|
---|
1025 |
|
---|
1026 | typedef
|
---|
1027 | #include "vmware_pack_begin.h"
|
---|
1028 | struct {
|
---|
1029 | uint32 cid;
|
---|
1030 | uint32 index;
|
---|
1031 | uint32 enabled;
|
---|
1032 | }
|
---|
1033 | #include "vmware_pack_end.h"
|
---|
1034 | SVGA3dCmdSetLightEnabled; /* SVGA_3D_CMD_SETLIGHTENABLED */
|
---|
1035 |
|
---|
1036 | typedef
|
---|
1037 | #include "vmware_pack_begin.h"
|
---|
1038 | struct {
|
---|
1039 | uint32 cid;
|
---|
1040 | SVGA3dRect rect;
|
---|
1041 | }
|
---|
1042 | #include "vmware_pack_end.h"
|
---|
1043 | SVGA3dCmdSetViewport; /* SVGA_3D_CMD_SETVIEWPORT */
|
---|
1044 |
|
---|
1045 | typedef
|
---|
1046 | #include "vmware_pack_begin.h"
|
---|
1047 | struct {
|
---|
1048 | uint32 cid;
|
---|
1049 | SVGA3dRect rect;
|
---|
1050 | }
|
---|
1051 | #include "vmware_pack_end.h"
|
---|
1052 | SVGA3dCmdSetScissorRect; /* SVGA_3D_CMD_SETSCISSORRECT */
|
---|
1053 |
|
---|
1054 | typedef
|
---|
1055 | #include "vmware_pack_begin.h"
|
---|
1056 | struct {
|
---|
1057 | uint32 cid;
|
---|
1058 | uint32 index;
|
---|
1059 | float plane[4];
|
---|
1060 | }
|
---|
1061 | #include "vmware_pack_end.h"
|
---|
1062 | SVGA3dCmdSetClipPlane; /* SVGA_3D_CMD_SETCLIPPLANE */
|
---|
1063 |
|
---|
1064 | typedef
|
---|
1065 | #include "vmware_pack_begin.h"
|
---|
1066 | struct {
|
---|
1067 | uint32 cid;
|
---|
1068 | uint32 shid;
|
---|
1069 | SVGA3dShaderType type;
|
---|
1070 | /* Followed by variable number of DWORDs for shader bycode */
|
---|
1071 | }
|
---|
1072 | #include "vmware_pack_end.h"
|
---|
1073 | SVGA3dCmdDefineShader; /* SVGA_3D_CMD_SHADER_DEFINE */
|
---|
1074 |
|
---|
1075 | typedef
|
---|
1076 | #include "vmware_pack_begin.h"
|
---|
1077 | struct {
|
---|
1078 | uint32 cid;
|
---|
1079 | uint32 shid;
|
---|
1080 | SVGA3dShaderType type;
|
---|
1081 | }
|
---|
1082 | #include "vmware_pack_end.h"
|
---|
1083 | SVGA3dCmdDestroyShader; /* SVGA_3D_CMD_SHADER_DESTROY */
|
---|
1084 |
|
---|
1085 | typedef
|
---|
1086 | #include "vmware_pack_begin.h"
|
---|
1087 | struct {
|
---|
1088 | uint32 cid;
|
---|
1089 | uint32 reg; /* register number */
|
---|
1090 | SVGA3dShaderType type;
|
---|
1091 | SVGA3dShaderConstType ctype;
|
---|
1092 | uint32 values[4];
|
---|
1093 |
|
---|
1094 | /*
|
---|
1095 | * Followed by a variable number of additional values.
|
---|
1096 | */
|
---|
1097 | }
|
---|
1098 | #include "vmware_pack_end.h"
|
---|
1099 | SVGA3dCmdSetShaderConst; /* SVGA_3D_CMD_SET_SHADER_CONST */
|
---|
1100 |
|
---|
1101 | typedef
|
---|
1102 | #include "vmware_pack_begin.h"
|
---|
1103 | struct {
|
---|
1104 | uint32 cid;
|
---|
1105 | SVGA3dShaderType type;
|
---|
1106 | uint32 shid;
|
---|
1107 | }
|
---|
1108 | #include "vmware_pack_end.h"
|
---|
1109 | SVGA3dCmdSetShader; /* SVGA_3D_CMD_SET_SHADER */
|
---|
1110 |
|
---|
1111 | typedef
|
---|
1112 | #include "vmware_pack_begin.h"
|
---|
1113 | struct {
|
---|
1114 | uint32 cid;
|
---|
1115 | SVGA3dQueryType type;
|
---|
1116 | }
|
---|
1117 | #include "vmware_pack_end.h"
|
---|
1118 | SVGA3dCmdBeginQuery; /* SVGA_3D_CMD_BEGIN_QUERY */
|
---|
1119 |
|
---|
1120 | typedef
|
---|
1121 | #include "vmware_pack_begin.h"
|
---|
1122 | struct {
|
---|
1123 | uint32 cid;
|
---|
1124 | SVGA3dQueryType type;
|
---|
1125 | SVGAGuestPtr guestResult; /* Points to an SVGA3dQueryResult structure */
|
---|
1126 | }
|
---|
1127 | #include "vmware_pack_end.h"
|
---|
1128 | SVGA3dCmdEndQuery; /* SVGA_3D_CMD_END_QUERY */
|
---|
1129 |
|
---|
1130 |
|
---|
1131 | /*
|
---|
1132 | * SVGA3D_CMD_WAIT_FOR_QUERY --
|
---|
1133 | *
|
---|
1134 | * Will read the SVGA3dQueryResult structure pointed to by guestResult,
|
---|
1135 | * and if the state member is set to anything else than
|
---|
1136 | * SVGA3D_QUERYSTATE_PENDING, this command will always be a no-op.
|
---|
1137 | *
|
---|
1138 | * Otherwise, in addition to the query explicitly waited for,
|
---|
1139 | * All queries with the same type and issued with the same cid, for which
|
---|
1140 | * an SVGA_3D_CMD_END_QUERY command has previously been sent, will
|
---|
1141 | * be finished after execution of this command.
|
---|
1142 | *
|
---|
1143 | * A query will be identified by the gmrId and offset of the guestResult
|
---|
1144 | * member. If the device can't find an SVGA_3D_CMD_END_QUERY that has
|
---|
1145 | * been sent previously with an indentical gmrId and offset, it will
|
---|
1146 | * effectively end all queries with an identical type issued with the
|
---|
1147 | * same cid, and the SVGA3dQueryResult structure pointed to by
|
---|
1148 | * guestResult will not be written to. This property can be used to
|
---|
1149 | * implement a query barrier for a given cid and query type.
|
---|
1150 | */
|
---|
1151 |
|
---|
1152 | typedef
|
---|
1153 | #include "vmware_pack_begin.h"
|
---|
1154 | struct {
|
---|
1155 | uint32 cid; /* Same parameters passed to END_QUERY */
|
---|
1156 | SVGA3dQueryType type;
|
---|
1157 | SVGAGuestPtr guestResult;
|
---|
1158 | }
|
---|
1159 | #include "vmware_pack_end.h"
|
---|
1160 | SVGA3dCmdWaitForQuery; /* SVGA_3D_CMD_WAIT_FOR_QUERY */
|
---|
1161 |
|
---|
1162 | typedef
|
---|
1163 | #include "vmware_pack_begin.h"
|
---|
1164 | struct {
|
---|
1165 | uint32 totalSize; /* Set by guest before query is ended. */
|
---|
1166 | SVGA3dQueryState state; /* Set by host or guest. See SVGA3dQueryState. */
|
---|
1167 | union { /* Set by host on exit from PENDING state */
|
---|
1168 | uint32 result32;
|
---|
1169 | uint32 queryCookie; /* May be used to identify which QueryGetData this
|
---|
1170 | result corresponds to. */
|
---|
1171 | };
|
---|
1172 | }
|
---|
1173 | #include "vmware_pack_end.h"
|
---|
1174 | SVGA3dQueryResult;
|
---|
1175 |
|
---|
1176 |
|
---|
1177 | /*
|
---|
1178 | * SVGA_3D_CMD_BLIT_SURFACE_TO_SCREEN --
|
---|
1179 | *
|
---|
1180 | * This is a blit from an SVGA3D surface to a Screen Object.
|
---|
1181 | * This blit must be directed at a specific screen.
|
---|
1182 | *
|
---|
1183 | * The blit copies from a rectangular region of an SVGA3D surface
|
---|
1184 | * image to a rectangular region of a screen.
|
---|
1185 | *
|
---|
1186 | * This command takes an optional variable-length list of clipping
|
---|
1187 | * rectangles after the body of the command. If no rectangles are
|
---|
1188 | * specified, there is no clipping region. The entire destRect is
|
---|
1189 | * drawn to. If one or more rectangles are included, they describe
|
---|
1190 | * a clipping region. The clip rectangle coordinates are measured
|
---|
1191 | * relative to the top-left corner of destRect.
|
---|
1192 | *
|
---|
1193 | * The srcImage must be from mip=0 face=0.
|
---|
1194 | *
|
---|
1195 | * This supports scaling if the src and dest are of different sizes.
|
---|
1196 | *
|
---|
1197 | * Availability:
|
---|
1198 | * SVGA_FIFO_CAP_SCREEN_OBJECT
|
---|
1199 | */
|
---|
1200 |
|
---|
1201 | typedef
|
---|
1202 | #include "vmware_pack_begin.h"
|
---|
1203 | struct {
|
---|
1204 | SVGA3dSurfaceImageId srcImage;
|
---|
1205 | SVGASignedRect srcRect;
|
---|
1206 | uint32 destScreenId; /* Screen Object ID */
|
---|
1207 | SVGASignedRect destRect;
|
---|
1208 | /* Clipping: zero or more SVGASignedRects follow */
|
---|
1209 | }
|
---|
1210 | #include "vmware_pack_end.h"
|
---|
1211 | SVGA3dCmdBlitSurfaceToScreen; /* SVGA_3D_CMD_BLIT_SURFACE_TO_SCREEN */
|
---|
1212 |
|
---|
1213 | typedef
|
---|
1214 | #include "vmware_pack_begin.h"
|
---|
1215 | struct {
|
---|
1216 | uint32 sid;
|
---|
1217 | SVGA3dTextureFilter filter;
|
---|
1218 | }
|
---|
1219 | #include "vmware_pack_end.h"
|
---|
1220 | SVGA3dCmdGenerateMipmaps; /* SVGA_3D_CMD_GENERATE_MIPMAPS */
|
---|
1221 |
|
---|
1222 | typedef
|
---|
1223 | #include "vmware_pack_begin.h"
|
---|
1224 | struct {
|
---|
1225 | uint32 sid;
|
---|
1226 | }
|
---|
1227 | #include "vmware_pack_end.h"
|
---|
1228 | SVGA3dCmdActivateSurface; /* SVGA_3D_CMD_ACTIVATE_SURFACE */
|
---|
1229 |
|
---|
1230 | typedef
|
---|
1231 | #include "vmware_pack_begin.h"
|
---|
1232 | struct {
|
---|
1233 | uint32 sid;
|
---|
1234 | }
|
---|
1235 | #include "vmware_pack_end.h"
|
---|
1236 | SVGA3dCmdDeactivateSurface; /* SVGA_3D_CMD_DEACTIVATE_SURFACE */
|
---|
1237 |
|
---|
1238 | /*
|
---|
1239 | * Screen DMA command
|
---|
1240 | *
|
---|
1241 | * Available with SVGA_FIFO_CAP_SCREEN_OBJECT_2. The SVGA_CAP_3D device
|
---|
1242 | * cap bit is not required.
|
---|
1243 | *
|
---|
1244 | * - refBuffer and destBuffer are 32bit BGRX; refBuffer and destBuffer could
|
---|
1245 | * be different, but it is required that guest makes sure refBuffer has
|
---|
1246 | * exactly the same contents that were written to when last time screen DMA
|
---|
1247 | * command is received by host.
|
---|
1248 | *
|
---|
1249 | * - changemap is generated by lib/blit, and it has the changes from last
|
---|
1250 | * received screen DMA or more.
|
---|
1251 | */
|
---|
1252 |
|
---|
1253 | typedef
|
---|
1254 | #include "vmware_pack_begin.h"
|
---|
1255 | struct SVGA3dCmdScreenDMA {
|
---|
1256 | uint32 screenId;
|
---|
1257 | SVGAGuestImage refBuffer;
|
---|
1258 | SVGAGuestImage destBuffer;
|
---|
1259 | SVGAGuestImage changeMap;
|
---|
1260 | }
|
---|
1261 | #include "vmware_pack_end.h"
|
---|
1262 | SVGA3dCmdScreenDMA; /* SVGA_3D_CMD_SCREEN_DMA */
|
---|
1263 |
|
---|
1264 | /*
|
---|
1265 | * Logic ops
|
---|
1266 | */
|
---|
1267 |
|
---|
1268 | #define SVGA3D_LOTRANSBLT_HONORALPHA (0x01)
|
---|
1269 | #define SVGA3D_LOSTRETCHBLT_MIRRORX (0x01)
|
---|
1270 | #define SVGA3D_LOSTRETCHBLT_MIRRORY (0x02)
|
---|
1271 | #define SVGA3D_LOALPHABLEND_SRCHASALPHA (0x01)
|
---|
1272 |
|
---|
1273 | typedef
|
---|
1274 | #include "vmware_pack_begin.h"
|
---|
1275 | struct SVGA3dCmdLogicOpsBitBlt {
|
---|
1276 | /*
|
---|
1277 | * All LogicOps surfaces are one-level
|
---|
1278 | * surfaces so mipmap & face should always
|
---|
1279 | * be zero.
|
---|
1280 | */
|
---|
1281 | SVGA3dSurfaceImageId src;
|
---|
1282 | SVGA3dSurfaceImageId dst;
|
---|
1283 | SVGA3dLogicOp logicOp;
|
---|
1284 | SVGA3dLogicOpRop3 logicOpRop3;
|
---|
1285 | /* Followed by variable number of SVGA3dCopyBox structures */
|
---|
1286 | }
|
---|
1287 | #include "vmware_pack_end.h"
|
---|
1288 | SVGA3dCmdLogicOpsBitBlt; /* SVGA_3D_CMD_LOGICOPS_BITBLT */
|
---|
1289 |
|
---|
1290 |
|
---|
1291 | typedef
|
---|
1292 | #include "vmware_pack_begin.h"
|
---|
1293 | struct SVGA3dCmdLogicOpsTransBlt {
|
---|
1294 | /*
|
---|
1295 | * All LogicOps surfaces are one-level
|
---|
1296 | * surfaces so mipmap & face should always
|
---|
1297 | * be zero.
|
---|
1298 | */
|
---|
1299 | SVGA3dSurfaceImageId src;
|
---|
1300 | SVGA3dSurfaceImageId dst;
|
---|
1301 | uint32 color;
|
---|
1302 | uint32 flags;
|
---|
1303 | SVGA3dBox srcBox;
|
---|
1304 | SVGA3dSignedBox dstBox;
|
---|
1305 | SVGA3dBox clipBox;
|
---|
1306 | }
|
---|
1307 | #include "vmware_pack_end.h"
|
---|
1308 | SVGA3dCmdLogicOpsTransBlt; /* SVGA_3D_CMD_LOGICOPS_TRANSBLT */
|
---|
1309 |
|
---|
1310 |
|
---|
1311 | typedef
|
---|
1312 | #include "vmware_pack_begin.h"
|
---|
1313 | struct SVGA3dCmdLogicOpsStretchBlt {
|
---|
1314 | /*
|
---|
1315 | * All LogicOps surfaces are one-level
|
---|
1316 | * surfaces so mipmap & face should always
|
---|
1317 | * be zero.
|
---|
1318 | */
|
---|
1319 | SVGA3dSurfaceImageId src;
|
---|
1320 | SVGA3dSurfaceImageId dst;
|
---|
1321 | uint16 mode;
|
---|
1322 | uint16 flags;
|
---|
1323 | SVGA3dBox srcBox;
|
---|
1324 | SVGA3dSignedBox dstBox;
|
---|
1325 | SVGA3dBox clipBox;
|
---|
1326 | }
|
---|
1327 | #include "vmware_pack_end.h"
|
---|
1328 | SVGA3dCmdLogicOpsStretchBlt; /* SVGA_3D_CMD_LOGICOPS_STRETCHBLT */
|
---|
1329 |
|
---|
1330 |
|
---|
1331 | typedef
|
---|
1332 | #include "vmware_pack_begin.h"
|
---|
1333 | struct SVGA3dCmdLogicOpsColorFill {
|
---|
1334 | /*
|
---|
1335 | * All LogicOps surfaces are one-level
|
---|
1336 | * surfaces so mipmap & face should always
|
---|
1337 | * be zero.
|
---|
1338 | */
|
---|
1339 | SVGA3dSurfaceImageId dst;
|
---|
1340 | uint32 color;
|
---|
1341 | SVGA3dLogicOp logicOp;
|
---|
1342 | SVGA3dLogicOpRop3 logicOpRop3;
|
---|
1343 | /* Followed by variable number of SVGA3dRect structures. */
|
---|
1344 | }
|
---|
1345 | #include "vmware_pack_end.h"
|
---|
1346 | SVGA3dCmdLogicOpsColorFill; /* SVGA_3D_CMD_LOGICOPS_COLORFILL */
|
---|
1347 |
|
---|
1348 |
|
---|
1349 | typedef
|
---|
1350 | #include "vmware_pack_begin.h"
|
---|
1351 | struct SVGA3dCmdLogicOpsAlphaBlend {
|
---|
1352 | /*
|
---|
1353 | * All LogicOps surfaces are one-level
|
---|
1354 | * surfaces so mipmap & face should always
|
---|
1355 | * be zero.
|
---|
1356 | */
|
---|
1357 | SVGA3dSurfaceImageId src;
|
---|
1358 | SVGA3dSurfaceImageId dst;
|
---|
1359 | uint32 alphaVal;
|
---|
1360 | uint32 flags;
|
---|
1361 | SVGA3dBox srcBox;
|
---|
1362 | SVGA3dSignedBox dstBox;
|
---|
1363 | SVGA3dBox clipBox;
|
---|
1364 | }
|
---|
1365 | #include "vmware_pack_end.h"
|
---|
1366 | SVGA3dCmdLogicOpsAlphaBlend; /* SVGA_3D_CMD_LOGICOPS_ALPHABLEND */
|
---|
1367 |
|
---|
1368 | #define SVGA3D_CLEARTYPE_INVALID_GAMMA_INDEX 0xFFFFFFFF
|
---|
1369 |
|
---|
1370 | #define SVGA3D_CLEARTYPE_GAMMA_WIDTH 512
|
---|
1371 | #define SVGA3D_CLEARTYPE_GAMMA_HEIGHT 16
|
---|
1372 |
|
---|
1373 | typedef
|
---|
1374 | #include "vmware_pack_begin.h"
|
---|
1375 | struct SVGA3dCmdLogicOpsClearTypeBlend {
|
---|
1376 | /*
|
---|
1377 | * All LogicOps surfaces are one-level
|
---|
1378 | * surfaces so mipmap & face should always
|
---|
1379 | * be zero.
|
---|
1380 | */
|
---|
1381 | SVGA3dSurfaceImageId tmp;
|
---|
1382 | SVGA3dSurfaceImageId dst;
|
---|
1383 | SVGA3dSurfaceImageId gammaSurf;
|
---|
1384 | SVGA3dSurfaceImageId alphaSurf;
|
---|
1385 | uint32 gamma;
|
---|
1386 | uint32 color;
|
---|
1387 | uint32 color2;
|
---|
1388 | int32 alphaOffsetX;
|
---|
1389 | int32 alphaOffsetY;
|
---|
1390 | /* Followed by variable number of SVGA3dBox structures */
|
---|
1391 | }
|
---|
1392 | #include "vmware_pack_end.h"
|
---|
1393 | SVGA3dCmdLogicOpsClearTypeBlend; /* SVGA_3D_CMD_LOGICOPS_CLEARTYPEBLEND */
|
---|
1394 |
|
---|
1395 |
|
---|
1396 | /*
|
---|
1397 | * Guest-backed objects definitions.
|
---|
1398 | */
|
---|
1399 |
|
---|
1400 | typedef
|
---|
1401 | #include "vmware_pack_begin.h"
|
---|
1402 | struct {
|
---|
1403 | SVGAMobFormat ptDepth;
|
---|
1404 | uint32 sizeInBytes;
|
---|
1405 | PPN64 base;
|
---|
1406 | }
|
---|
1407 | #include "vmware_pack_end.h"
|
---|
1408 | SVGAOTableMobEntry;
|
---|
1409 | #define SVGA3D_OTABLE_MOB_ENTRY_SIZE (sizeof(SVGAOTableMobEntry))
|
---|
1410 |
|
---|
1411 | typedef
|
---|
1412 | #include "vmware_pack_begin.h"
|
---|
1413 | struct {
|
---|
1414 | SVGA3dSurfaceFormat format;
|
---|
1415 | SVGA3dSurface1Flags surface1Flags;
|
---|
1416 | uint32 numMipLevels;
|
---|
1417 | uint32 multisampleCount;
|
---|
1418 | SVGA3dTextureFilter autogenFilter;
|
---|
1419 | SVGA3dSize size;
|
---|
1420 | SVGAMobId mobid;
|
---|
1421 | uint32 arraySize;
|
---|
1422 | uint32 mobPitch;
|
---|
1423 | SVGA3dSurface2Flags surface2Flags;
|
---|
1424 | uint8 multisamplePattern;
|
---|
1425 | uint8 qualityLevel;
|
---|
1426 | uint16 bufferByteStride;
|
---|
1427 | float minLOD;
|
---|
1428 | uint32 pad0[2];
|
---|
1429 | }
|
---|
1430 | #include "vmware_pack_end.h"
|
---|
1431 | SVGAOTableSurfaceEntry;
|
---|
1432 | #define SVGA3D_OTABLE_SURFACE_ENTRY_SIZE (sizeof(SVGAOTableSurfaceEntry))
|
---|
1433 |
|
---|
1434 | typedef
|
---|
1435 | #include "vmware_pack_begin.h"
|
---|
1436 | struct {
|
---|
1437 | uint32 cid;
|
---|
1438 | SVGAMobId mobid;
|
---|
1439 | }
|
---|
1440 | #include "vmware_pack_end.h"
|
---|
1441 | SVGAOTableContextEntry;
|
---|
1442 | #define SVGA3D_OTABLE_CONTEXT_ENTRY_SIZE (sizeof(SVGAOTableContextEntry))
|
---|
1443 |
|
---|
1444 | typedef
|
---|
1445 | #include "vmware_pack_begin.h"
|
---|
1446 | struct {
|
---|
1447 | SVGA3dShaderType type;
|
---|
1448 | uint32 sizeInBytes;
|
---|
1449 | uint32 offsetInBytes;
|
---|
1450 | SVGAMobId mobid;
|
---|
1451 | }
|
---|
1452 | #include "vmware_pack_end.h"
|
---|
1453 | SVGAOTableShaderEntry;
|
---|
1454 | #define SVGA3D_OTABLE_SHADER_ENTRY_SIZE (sizeof(SVGAOTableShaderEntry))
|
---|
1455 |
|
---|
1456 | #define SVGA_STFLAG_PRIMARY (1 << 0)
|
---|
1457 | #define SVGA_STFLAG_RESERVED (1 << 1) /* Added with cap SVGA_CAP_HP_CMD_QUEUE */
|
---|
1458 | typedef uint32 SVGAScreenTargetFlags;
|
---|
1459 |
|
---|
1460 | typedef
|
---|
1461 | #include "vmware_pack_begin.h"
|
---|
1462 | struct {
|
---|
1463 | SVGA3dSurfaceImageId image;
|
---|
1464 | uint32 width;
|
---|
1465 | uint32 height;
|
---|
1466 | int32 xRoot;
|
---|
1467 | int32 yRoot;
|
---|
1468 | SVGAScreenTargetFlags flags;
|
---|
1469 | uint32 dpi;
|
---|
1470 | uint32 pad[7];
|
---|
1471 | }
|
---|
1472 | #include "vmware_pack_end.h"
|
---|
1473 | SVGAOTableScreenTargetEntry;
|
---|
1474 | #define SVGA3D_OTABLE_SCREEN_TARGET_ENTRY_SIZE \
|
---|
1475 | (sizeof(SVGAOTableScreenTargetEntry))
|
---|
1476 |
|
---|
1477 | typedef
|
---|
1478 | #include "vmware_pack_begin.h"
|
---|
1479 | struct {
|
---|
1480 | float value[4];
|
---|
1481 | }
|
---|
1482 | #include "vmware_pack_end.h"
|
---|
1483 | SVGA3dShaderConstFloat;
|
---|
1484 |
|
---|
1485 | typedef
|
---|
1486 | #include "vmware_pack_begin.h"
|
---|
1487 | struct {
|
---|
1488 | int32 value[4];
|
---|
1489 | }
|
---|
1490 | #include "vmware_pack_end.h"
|
---|
1491 | SVGA3dShaderConstInt;
|
---|
1492 |
|
---|
1493 | typedef
|
---|
1494 | #include "vmware_pack_begin.h"
|
---|
1495 | struct {
|
---|
1496 | uint32 value;
|
---|
1497 | }
|
---|
1498 | #include "vmware_pack_end.h"
|
---|
1499 | SVGA3dShaderConstBool;
|
---|
1500 |
|
---|
1501 | typedef
|
---|
1502 | #include "vmware_pack_begin.h"
|
---|
1503 | struct {
|
---|
1504 | uint16 streamOffset;
|
---|
1505 | uint8 stream;
|
---|
1506 | uint8 type;
|
---|
1507 | uint8 methodUsage;
|
---|
1508 | uint8 usageIndex;
|
---|
1509 | }
|
---|
1510 | #include "vmware_pack_end.h"
|
---|
1511 | SVGAGBVertexElement;
|
---|
1512 |
|
---|
1513 | typedef
|
---|
1514 | #include "vmware_pack_begin.h"
|
---|
1515 | struct {
|
---|
1516 | uint32 sid;
|
---|
1517 | uint16 stride;
|
---|
1518 | uint32 offset;
|
---|
1519 | }
|
---|
1520 | #include "vmware_pack_end.h"
|
---|
1521 | SVGAGBVertexStream;
|
---|
1522 | typedef
|
---|
1523 | #include "vmware_pack_begin.h"
|
---|
1524 | struct {
|
---|
1525 | SVGA3dRect viewport;
|
---|
1526 | SVGA3dRect scissorRect;
|
---|
1527 | SVGA3dZRange zRange;
|
---|
1528 |
|
---|
1529 | SVGA3dSurfaceImageId renderTargets[SVGA3D_RT_MAX];
|
---|
1530 | SVGAGBVertexElement decl1[4];
|
---|
1531 |
|
---|
1532 | uint32 renderStates[SVGA3D_RS_MAX];
|
---|
1533 | SVGAGBVertexElement decl2[18];
|
---|
1534 | uint32 pad0[2];
|
---|
1535 |
|
---|
1536 | struct {
|
---|
1537 | SVGA3dFace face;
|
---|
1538 | SVGA3dMaterial material;
|
---|
1539 | } material;
|
---|
1540 |
|
---|
1541 | float clipPlanes[SVGA3D_NUM_CLIPPLANES][4];
|
---|
1542 | float matrices[SVGA3D_TRANSFORM_MAX][16];
|
---|
1543 |
|
---|
1544 | SVGA3dBool lightEnabled[SVGA3D_NUM_LIGHTS];
|
---|
1545 | SVGA3dLightData lightData[SVGA3D_NUM_LIGHTS];
|
---|
1546 |
|
---|
1547 | /*
|
---|
1548 | * Shaders currently bound
|
---|
1549 | */
|
---|
1550 | uint32 shaders[SVGA3D_NUM_SHADERTYPE_PREDX];
|
---|
1551 | SVGAGBVertexElement decl3[10];
|
---|
1552 | uint32 pad1[3];
|
---|
1553 |
|
---|
1554 | uint32 occQueryActive;
|
---|
1555 | uint32 occQueryValue;
|
---|
1556 |
|
---|
1557 | /*
|
---|
1558 | * Int/Bool Shader constants
|
---|
1559 | */
|
---|
1560 | SVGA3dShaderConstInt pShaderIValues[SVGA3D_CONSTINTREG_MAX];
|
---|
1561 | SVGA3dShaderConstInt vShaderIValues[SVGA3D_CONSTINTREG_MAX];
|
---|
1562 | uint16 pShaderBValues;
|
---|
1563 | uint16 vShaderBValues;
|
---|
1564 |
|
---|
1565 |
|
---|
1566 | SVGAGBVertexStream streams[SVGA3D_MAX_VERTEX_ARRAYS];
|
---|
1567 | SVGA3dVertexDivisor divisors[SVGA3D_MAX_VERTEX_ARRAYS];
|
---|
1568 | uint32 numVertexDecls;
|
---|
1569 | uint32 numVertexStreams;
|
---|
1570 | uint32 numVertexDivisors;
|
---|
1571 | uint32 pad2[30];
|
---|
1572 |
|
---|
1573 | /*
|
---|
1574 | * Texture Stages
|
---|
1575 | *
|
---|
1576 | * SVGA3D_TS_INVALID through SVGA3D_TS_CONSTANT are in the
|
---|
1577 | * textureStages array.
|
---|
1578 | * SVGA3D_TS_COLOR_KEY is in tsColorKey.
|
---|
1579 | */
|
---|
1580 | uint32 tsColorKey[SVGA3D_NUM_TEXTURE_UNITS];
|
---|
1581 | uint32 textureStages[SVGA3D_NUM_TEXTURE_UNITS][SVGA3D_TS_CONSTANT + 1];
|
---|
1582 | uint32 tsColorKeyEnable[SVGA3D_NUM_TEXTURE_UNITS];
|
---|
1583 |
|
---|
1584 | /*
|
---|
1585 | * Float Shader constants.
|
---|
1586 | */
|
---|
1587 | SVGA3dShaderConstFloat pShaderFValues[SVGA3D_CONSTREG_MAX];
|
---|
1588 | SVGA3dShaderConstFloat vShaderFValues[SVGA3D_CONSTREG_MAX];
|
---|
1589 | }
|
---|
1590 | #include "vmware_pack_end.h"
|
---|
1591 | SVGAGBContextData;
|
---|
1592 | #define SVGA3D_CONTEXT_DATA_SIZE (sizeof(SVGAGBContextData))
|
---|
1593 |
|
---|
1594 | /*
|
---|
1595 | * SVGA3dCmdSetOTableBase --
|
---|
1596 | *
|
---|
1597 | * This command allows the guest to specify the base PPN of the
|
---|
1598 | * specified object table.
|
---|
1599 | */
|
---|
1600 |
|
---|
1601 | typedef
|
---|
1602 | #include "vmware_pack_begin.h"
|
---|
1603 | struct {
|
---|
1604 | SVGAOTableType type;
|
---|
1605 | PPN32 baseAddress;
|
---|
1606 | uint32 sizeInBytes;
|
---|
1607 | uint32 validSizeInBytes;
|
---|
1608 | SVGAMobFormat ptDepth;
|
---|
1609 | }
|
---|
1610 | #include "vmware_pack_end.h"
|
---|
1611 | SVGA3dCmdSetOTableBase; /* SVGA_3D_CMD_SET_OTABLE_BASE */
|
---|
1612 |
|
---|
1613 | typedef
|
---|
1614 | #include "vmware_pack_begin.h"
|
---|
1615 | struct {
|
---|
1616 | SVGAOTableType type;
|
---|
1617 | PPN64 baseAddress;
|
---|
1618 | uint32 sizeInBytes;
|
---|
1619 | uint32 validSizeInBytes;
|
---|
1620 | SVGAMobFormat ptDepth;
|
---|
1621 | }
|
---|
1622 | #include "vmware_pack_end.h"
|
---|
1623 | SVGA3dCmdSetOTableBase64; /* SVGA_3D_CMD_SET_OTABLE_BASE64 */
|
---|
1624 |
|
---|
1625 | /*
|
---|
1626 | * Guests using SVGA_3D_CMD_GROW_OTABLE are promising that
|
---|
1627 | * the new OTable contains the same contents as the old one, except possibly
|
---|
1628 | * for some new invalid entries at the end.
|
---|
1629 | *
|
---|
1630 | * (Otherwise, guests should use one of the SetOTableBase commands.)
|
---|
1631 | */
|
---|
1632 | typedef
|
---|
1633 | #include "vmware_pack_begin.h"
|
---|
1634 | struct {
|
---|
1635 | SVGAOTableType type;
|
---|
1636 | PPN64 baseAddress;
|
---|
1637 | uint32 sizeInBytes;
|
---|
1638 | uint32 validSizeInBytes;
|
---|
1639 | SVGAMobFormat ptDepth;
|
---|
1640 | }
|
---|
1641 | #include "vmware_pack_end.h"
|
---|
1642 | SVGA3dCmdGrowOTable; /* SVGA_3D_CMD_GROW_OTABLE */
|
---|
1643 |
|
---|
1644 | typedef
|
---|
1645 | #include "vmware_pack_begin.h"
|
---|
1646 | struct {
|
---|
1647 | SVGAOTableType type;
|
---|
1648 | }
|
---|
1649 | #include "vmware_pack_end.h"
|
---|
1650 | SVGA3dCmdReadbackOTable; /* SVGA_3D_CMD_READBACK_OTABLE */
|
---|
1651 |
|
---|
1652 | /*
|
---|
1653 | * Define a memory object (Mob) in the OTable.
|
---|
1654 | */
|
---|
1655 |
|
---|
1656 | typedef
|
---|
1657 | #include "vmware_pack_begin.h"
|
---|
1658 | struct SVGA3dCmdDefineGBMob {
|
---|
1659 | SVGAMobId mobid;
|
---|
1660 | SVGAMobFormat ptDepth;
|
---|
1661 | PPN32 base;
|
---|
1662 | uint32 sizeInBytes;
|
---|
1663 | }
|
---|
1664 | #include "vmware_pack_end.h"
|
---|
1665 | SVGA3dCmdDefineGBMob; /* SVGA_3D_CMD_DEFINE_GB_MOB */
|
---|
1666 |
|
---|
1667 |
|
---|
1668 | /*
|
---|
1669 | * Destroys an object in the OTable.
|
---|
1670 | */
|
---|
1671 |
|
---|
1672 | typedef
|
---|
1673 | #include "vmware_pack_begin.h"
|
---|
1674 | struct SVGA3dCmdDestroyGBMob {
|
---|
1675 | SVGAMobId mobid;
|
---|
1676 | }
|
---|
1677 | #include "vmware_pack_end.h"
|
---|
1678 | SVGA3dCmdDestroyGBMob; /* SVGA_3D_CMD_DESTROY_GB_MOB */
|
---|
1679 |
|
---|
1680 | /*
|
---|
1681 | * Define a memory object (Mob) in the OTable with a PPN64 base.
|
---|
1682 | */
|
---|
1683 |
|
---|
1684 | typedef
|
---|
1685 | #include "vmware_pack_begin.h"
|
---|
1686 | struct SVGA3dCmdDefineGBMob64 {
|
---|
1687 | SVGAMobId mobid;
|
---|
1688 | SVGAMobFormat ptDepth;
|
---|
1689 | PPN64 base;
|
---|
1690 | uint32 sizeInBytes;
|
---|
1691 | }
|
---|
1692 | #include "vmware_pack_end.h"
|
---|
1693 | SVGA3dCmdDefineGBMob64; /* SVGA_3D_CMD_DEFINE_GB_MOB64 */
|
---|
1694 |
|
---|
1695 | /*
|
---|
1696 | * Redefine an object in the OTable with PPN64 base.
|
---|
1697 | */
|
---|
1698 |
|
---|
1699 | typedef
|
---|
1700 | #include "vmware_pack_begin.h"
|
---|
1701 | struct SVGA3dCmdRedefineGBMob64 {
|
---|
1702 | SVGAMobId mobid;
|
---|
1703 | SVGAMobFormat ptDepth;
|
---|
1704 | PPN64 base;
|
---|
1705 | uint32 sizeInBytes;
|
---|
1706 | }
|
---|
1707 | #include "vmware_pack_end.h"
|
---|
1708 | SVGA3dCmdRedefineGBMob64; /* SVGA_3D_CMD_REDEFINE_GB_MOB64 */
|
---|
1709 |
|
---|
1710 | /*
|
---|
1711 | * Notification that the page tables have been modified.
|
---|
1712 | */
|
---|
1713 |
|
---|
1714 | typedef
|
---|
1715 | #include "vmware_pack_begin.h"
|
---|
1716 | struct SVGA3dCmdUpdateGBMobMapping {
|
---|
1717 | SVGAMobId mobid;
|
---|
1718 | }
|
---|
1719 | #include "vmware_pack_end.h"
|
---|
1720 | SVGA3dCmdUpdateGBMobMapping; /* SVGA_3D_CMD_UPDATE_GB_MOB_MAPPING */
|
---|
1721 |
|
---|
1722 | /*
|
---|
1723 | * Define a guest-backed surface.
|
---|
1724 | */
|
---|
1725 |
|
---|
1726 | typedef
|
---|
1727 | #include "vmware_pack_begin.h"
|
---|
1728 | struct SVGA3dCmdDefineGBSurface {
|
---|
1729 | uint32 sid;
|
---|
1730 | SVGA3dSurface1Flags surfaceFlags;
|
---|
1731 | SVGA3dSurfaceFormat format;
|
---|
1732 | uint32 numMipLevels;
|
---|
1733 | uint32 multisampleCount;
|
---|
1734 | SVGA3dTextureFilter autogenFilter;
|
---|
1735 | SVGA3dSize size;
|
---|
1736 | }
|
---|
1737 | #include "vmware_pack_end.h"
|
---|
1738 | SVGA3dCmdDefineGBSurface; /* SVGA_3D_CMD_DEFINE_GB_SURFACE */
|
---|
1739 |
|
---|
1740 | /*
|
---|
1741 | * Defines a guest-backed surface, adding the arraySize field.
|
---|
1742 | */
|
---|
1743 | typedef
|
---|
1744 | #include "vmware_pack_begin.h"
|
---|
1745 | struct SVGA3dCmdDefineGBSurface_v2 {
|
---|
1746 | uint32 sid;
|
---|
1747 | SVGA3dSurface1Flags surfaceFlags;
|
---|
1748 | SVGA3dSurfaceFormat format;
|
---|
1749 | uint32 numMipLevels;
|
---|
1750 | uint32 multisampleCount;
|
---|
1751 | SVGA3dTextureFilter autogenFilter;
|
---|
1752 | SVGA3dSize size;
|
---|
1753 | uint32 arraySize;
|
---|
1754 | uint32 pad;
|
---|
1755 | }
|
---|
1756 | #include "vmware_pack_end.h"
|
---|
1757 | SVGA3dCmdDefineGBSurface_v2; /* SVGA_3D_CMD_DEFINE_GB_SURFACE_V2 */
|
---|
1758 |
|
---|
1759 | /*
|
---|
1760 | * Defines a guest-backed surface, adding the larger flags.
|
---|
1761 | */
|
---|
1762 | typedef
|
---|
1763 | #include "vmware_pack_begin.h"
|
---|
1764 | struct SVGA3dCmdDefineGBSurface_v3 {
|
---|
1765 | uint32 sid;
|
---|
1766 | SVGA3dSurfaceAllFlags surfaceFlags;
|
---|
1767 | SVGA3dSurfaceFormat format;
|
---|
1768 | uint32 numMipLevels;
|
---|
1769 | uint32 multisampleCount;
|
---|
1770 | SVGA3dMSPattern multisamplePattern;
|
---|
1771 | SVGA3dMSQualityLevel qualityLevel;
|
---|
1772 | SVGA3dTextureFilter autogenFilter;
|
---|
1773 | SVGA3dSize size;
|
---|
1774 | uint32 arraySize;
|
---|
1775 | }
|
---|
1776 | #include "vmware_pack_end.h"
|
---|
1777 | SVGA3dCmdDefineGBSurface_v3; /* SVGA_3D_CMD_DEFINE_GB_SURFACE_V3 */
|
---|
1778 |
|
---|
1779 | /*
|
---|
1780 | * Defines a guest-backed surface, adding buffer byte stride.
|
---|
1781 | */
|
---|
1782 | typedef
|
---|
1783 | #include "vmware_pack_begin.h"
|
---|
1784 | struct SVGA3dCmdDefineGBSurface_v4 {
|
---|
1785 | uint32 sid;
|
---|
1786 | SVGA3dSurfaceAllFlags surfaceFlags;
|
---|
1787 | SVGA3dSurfaceFormat format;
|
---|
1788 | uint32 numMipLevels;
|
---|
1789 | uint32 multisampleCount;
|
---|
1790 | SVGA3dMSPattern multisamplePattern;
|
---|
1791 | SVGA3dMSQualityLevel qualityLevel;
|
---|
1792 | SVGA3dTextureFilter autogenFilter;
|
---|
1793 | SVGA3dSize size;
|
---|
1794 | uint32 arraySize;
|
---|
1795 | uint32 bufferByteStride;
|
---|
1796 | }
|
---|
1797 | #include "vmware_pack_end.h"
|
---|
1798 | SVGA3dCmdDefineGBSurface_v4; /* SVGA_3D_CMD_DEFINE_GB_SURFACE_V4 */
|
---|
1799 |
|
---|
1800 | /*
|
---|
1801 | * Destroy a guest-backed surface.
|
---|
1802 | */
|
---|
1803 |
|
---|
1804 | typedef
|
---|
1805 | #include "vmware_pack_begin.h"
|
---|
1806 | struct SVGA3dCmdDestroyGBSurface {
|
---|
1807 | uint32 sid;
|
---|
1808 | }
|
---|
1809 | #include "vmware_pack_end.h"
|
---|
1810 | SVGA3dCmdDestroyGBSurface; /* SVGA_3D_CMD_DESTROY_GB_SURFACE */
|
---|
1811 |
|
---|
1812 | /*
|
---|
1813 | * Bind a guest-backed surface to a mob.
|
---|
1814 | */
|
---|
1815 |
|
---|
1816 | typedef
|
---|
1817 | #include "vmware_pack_begin.h"
|
---|
1818 | struct SVGA3dCmdBindGBSurface {
|
---|
1819 | uint32 sid;
|
---|
1820 | SVGAMobId mobid;
|
---|
1821 | }
|
---|
1822 | #include "vmware_pack_end.h"
|
---|
1823 | SVGA3dCmdBindGBSurface; /* SVGA_3D_CMD_BIND_GB_SURFACE */
|
---|
1824 |
|
---|
1825 | typedef
|
---|
1826 | #include "vmware_pack_begin.h"
|
---|
1827 | struct SVGA3dCmdBindGBSurfaceWithPitch {
|
---|
1828 | uint32 sid;
|
---|
1829 | SVGAMobId mobid;
|
---|
1830 | uint32 baseLevelPitch;
|
---|
1831 | }
|
---|
1832 | #include "vmware_pack_end.h"
|
---|
1833 | SVGA3dCmdBindGBSurfaceWithPitch; /* SVGA_3D_CMD_BIND_GB_SURFACE_WITH_PITCH */
|
---|
1834 |
|
---|
1835 | /*
|
---|
1836 | * Conditionally bind a mob to a guest-backed surface if testMobid
|
---|
1837 | * matches the currently bound mob. Optionally issue a
|
---|
1838 | * readback/update on the surface while it is still bound to the old
|
---|
1839 | * mobid if the mobid is changed by this command.
|
---|
1840 | */
|
---|
1841 |
|
---|
1842 | #define SVGA3D_COND_BIND_GB_SURFACE_FLAG_READBACK (1 << 0)
|
---|
1843 | #define SVGA3D_COND_BIND_GB_SURFACE_FLAG_UPDATE (1 << 1)
|
---|
1844 |
|
---|
1845 | typedef
|
---|
1846 | #include "vmware_pack_begin.h"
|
---|
1847 | struct SVGA3dCmdCondBindGBSurface {
|
---|
1848 | uint32 sid;
|
---|
1849 | SVGAMobId testMobid;
|
---|
1850 | SVGAMobId mobid;
|
---|
1851 | uint32 flags;
|
---|
1852 | }
|
---|
1853 | #include "vmware_pack_end.h"
|
---|
1854 | SVGA3dCmdCondBindGBSurface; /* SVGA_3D_CMD_COND_BIND_GB_SURFACE */
|
---|
1855 |
|
---|
1856 | /*
|
---|
1857 | * Update an image in a guest-backed surface.
|
---|
1858 | * (Inform the device that the guest-contents have been updated.)
|
---|
1859 | */
|
---|
1860 |
|
---|
1861 | typedef
|
---|
1862 | #include "vmware_pack_begin.h"
|
---|
1863 | struct SVGA3dCmdUpdateGBImage {
|
---|
1864 | SVGA3dSurfaceImageId image;
|
---|
1865 | SVGA3dBox box;
|
---|
1866 | }
|
---|
1867 | #include "vmware_pack_end.h"
|
---|
1868 | SVGA3dCmdUpdateGBImage; /* SVGA_3D_CMD_UPDATE_GB_IMAGE */
|
---|
1869 |
|
---|
1870 | /*
|
---|
1871 | * Update an entire guest-backed surface.
|
---|
1872 | * (Inform the device that the guest-contents have been updated.)
|
---|
1873 | */
|
---|
1874 |
|
---|
1875 | typedef
|
---|
1876 | #include "vmware_pack_begin.h"
|
---|
1877 | struct SVGA3dCmdUpdateGBSurface {
|
---|
1878 | uint32 sid;
|
---|
1879 | }
|
---|
1880 | #include "vmware_pack_end.h"
|
---|
1881 | SVGA3dCmdUpdateGBSurface; /* SVGA_3D_CMD_UPDATE_GB_SURFACE */
|
---|
1882 |
|
---|
1883 | /*
|
---|
1884 | * Readback an image in a guest-backed surface.
|
---|
1885 | * (Request the device to flush the dirty contents into the guest.)
|
---|
1886 | */
|
---|
1887 |
|
---|
1888 | typedef
|
---|
1889 | #include "vmware_pack_begin.h"
|
---|
1890 | struct SVGA3dCmdReadbackGBImage {
|
---|
1891 | SVGA3dSurfaceImageId image;
|
---|
1892 | }
|
---|
1893 | #include "vmware_pack_end.h"
|
---|
1894 | SVGA3dCmdReadbackGBImage; /* SVGA_3D_CMD_READBACK_GB_IMAGE */
|
---|
1895 |
|
---|
1896 | /*
|
---|
1897 | * Readback an entire guest-backed surface.
|
---|
1898 | * (Request the device to flush the dirty contents into the guest.)
|
---|
1899 | */
|
---|
1900 |
|
---|
1901 | typedef
|
---|
1902 | #include "vmware_pack_begin.h"
|
---|
1903 | struct SVGA3dCmdReadbackGBSurface {
|
---|
1904 | uint32 sid;
|
---|
1905 | }
|
---|
1906 | #include "vmware_pack_end.h"
|
---|
1907 | SVGA3dCmdReadbackGBSurface; /* SVGA_3D_CMD_READBACK_GB_SURFACE */
|
---|
1908 |
|
---|
1909 | /*
|
---|
1910 | * Readback a sub rect of an image in a guest-backed surface. After
|
---|
1911 | * issuing this command the driver is required to issue an update call
|
---|
1912 | * of the same region before issuing any other commands that reference
|
---|
1913 | * this surface or rendering is not guaranteed.
|
---|
1914 | */
|
---|
1915 |
|
---|
1916 | typedef
|
---|
1917 | #include "vmware_pack_begin.h"
|
---|
1918 | struct SVGA3dCmdReadbackGBImagePartial {
|
---|
1919 | SVGA3dSurfaceImageId image;
|
---|
1920 | SVGA3dBox box;
|
---|
1921 | uint32 invertBox;
|
---|
1922 | }
|
---|
1923 | #include "vmware_pack_end.h"
|
---|
1924 | SVGA3dCmdReadbackGBImagePartial; /* SVGA_3D_CMD_READBACK_GB_IMAGE_PARTIAL */
|
---|
1925 |
|
---|
1926 |
|
---|
1927 | /*
|
---|
1928 | * Invalidate an image in a guest-backed surface.
|
---|
1929 | * (Notify the device that the contents can be lost.)
|
---|
1930 | */
|
---|
1931 |
|
---|
1932 | typedef
|
---|
1933 | #include "vmware_pack_begin.h"
|
---|
1934 | struct SVGA3dCmdInvalidateGBImage {
|
---|
1935 | SVGA3dSurfaceImageId image;
|
---|
1936 | }
|
---|
1937 | #include "vmware_pack_end.h"
|
---|
1938 | SVGA3dCmdInvalidateGBImage; /* SVGA_3D_CMD_INVALIDATE_GB_IMAGE */
|
---|
1939 |
|
---|
1940 | /*
|
---|
1941 | * Invalidate an entire guest-backed surface.
|
---|
1942 | * (Notify the device that the contents if all images can be lost.)
|
---|
1943 | */
|
---|
1944 |
|
---|
1945 | typedef
|
---|
1946 | #include "vmware_pack_begin.h"
|
---|
1947 | struct SVGA3dCmdInvalidateGBSurface {
|
---|
1948 | uint32 sid;
|
---|
1949 | }
|
---|
1950 | #include "vmware_pack_end.h"
|
---|
1951 | SVGA3dCmdInvalidateGBSurface; /* SVGA_3D_CMD_INVALIDATE_GB_SURFACE */
|
---|
1952 |
|
---|
1953 | /*
|
---|
1954 | * Invalidate a sub rect of an image in a guest-backed surface. After
|
---|
1955 | * issuing this command the driver is required to issue an update call
|
---|
1956 | * of the same region before issuing any other commands that reference
|
---|
1957 | * this surface or rendering is not guaranteed.
|
---|
1958 | */
|
---|
1959 |
|
---|
1960 | typedef
|
---|
1961 | #include "vmware_pack_begin.h"
|
---|
1962 | struct SVGA3dCmdInvalidateGBImagePartial {
|
---|
1963 | SVGA3dSurfaceImageId image;
|
---|
1964 | SVGA3dBox box;
|
---|
1965 | uint32 invertBox;
|
---|
1966 | }
|
---|
1967 | #include "vmware_pack_end.h"
|
---|
1968 | SVGA3dCmdInvalidateGBImagePartial; /* SVGA_3D_CMD_INVALIDATE_GB_IMAGE_PARTIAL */
|
---|
1969 |
|
---|
1970 |
|
---|
1971 | /*
|
---|
1972 | * Define a guest-backed context.
|
---|
1973 | */
|
---|
1974 |
|
---|
1975 | typedef
|
---|
1976 | #include "vmware_pack_begin.h"
|
---|
1977 | struct SVGA3dCmdDefineGBContext {
|
---|
1978 | uint32 cid;
|
---|
1979 | }
|
---|
1980 | #include "vmware_pack_end.h"
|
---|
1981 | SVGA3dCmdDefineGBContext; /* SVGA_3D_CMD_DEFINE_GB_CONTEXT */
|
---|
1982 |
|
---|
1983 | /*
|
---|
1984 | * Destroy a guest-backed context.
|
---|
1985 | */
|
---|
1986 |
|
---|
1987 | typedef
|
---|
1988 | #include "vmware_pack_begin.h"
|
---|
1989 | struct SVGA3dCmdDestroyGBContext {
|
---|
1990 | uint32 cid;
|
---|
1991 | }
|
---|
1992 | #include "vmware_pack_end.h"
|
---|
1993 | SVGA3dCmdDestroyGBContext; /* SVGA_3D_CMD_DESTROY_GB_CONTEXT */
|
---|
1994 |
|
---|
1995 | /*
|
---|
1996 | * Bind a guest-backed context.
|
---|
1997 | *
|
---|
1998 | * validContents should be set to 0 for new contexts,
|
---|
1999 | * and 1 if this is an old context which is getting paged
|
---|
2000 | * back on to the device.
|
---|
2001 | *
|
---|
2002 | * For new contexts, it is recommended that the driver
|
---|
2003 | * issue commands to initialize all interesting state
|
---|
2004 | * prior to rendering.
|
---|
2005 | */
|
---|
2006 |
|
---|
2007 | typedef
|
---|
2008 | #include "vmware_pack_begin.h"
|
---|
2009 | struct SVGA3dCmdBindGBContext {
|
---|
2010 | uint32 cid;
|
---|
2011 | SVGAMobId mobid;
|
---|
2012 | uint32 validContents;
|
---|
2013 | }
|
---|
2014 | #include "vmware_pack_end.h"
|
---|
2015 | SVGA3dCmdBindGBContext; /* SVGA_3D_CMD_BIND_GB_CONTEXT */
|
---|
2016 |
|
---|
2017 | /*
|
---|
2018 | * Readback a guest-backed context.
|
---|
2019 | * (Request that the device flush the contents back into guest memory.)
|
---|
2020 | */
|
---|
2021 |
|
---|
2022 | typedef
|
---|
2023 | #include "vmware_pack_begin.h"
|
---|
2024 | struct SVGA3dCmdReadbackGBContext {
|
---|
2025 | uint32 cid;
|
---|
2026 | }
|
---|
2027 | #include "vmware_pack_end.h"
|
---|
2028 | SVGA3dCmdReadbackGBContext; /* SVGA_3D_CMD_READBACK_GB_CONTEXT */
|
---|
2029 |
|
---|
2030 | /*
|
---|
2031 | * Invalidate a guest-backed context.
|
---|
2032 | */
|
---|
2033 | typedef
|
---|
2034 | #include "vmware_pack_begin.h"
|
---|
2035 | struct SVGA3dCmdInvalidateGBContext {
|
---|
2036 | uint32 cid;
|
---|
2037 | }
|
---|
2038 | #include "vmware_pack_end.h"
|
---|
2039 | SVGA3dCmdInvalidateGBContext; /* SVGA_3D_CMD_INVALIDATE_GB_CONTEXT */
|
---|
2040 |
|
---|
2041 | /*
|
---|
2042 | * Define a guest-backed shader.
|
---|
2043 | */
|
---|
2044 |
|
---|
2045 | typedef
|
---|
2046 | #include "vmware_pack_begin.h"
|
---|
2047 | struct SVGA3dCmdDefineGBShader {
|
---|
2048 | uint32 shid;
|
---|
2049 | SVGA3dShaderType type;
|
---|
2050 | uint32 sizeInBytes;
|
---|
2051 | }
|
---|
2052 | #include "vmware_pack_end.h"
|
---|
2053 | SVGA3dCmdDefineGBShader; /* SVGA_3D_CMD_DEFINE_GB_SHADER */
|
---|
2054 |
|
---|
2055 | /*
|
---|
2056 | * Bind a guest-backed shader.
|
---|
2057 | */
|
---|
2058 |
|
---|
2059 | typedef
|
---|
2060 | #include "vmware_pack_begin.h"
|
---|
2061 | struct SVGA3dCmdBindGBShader {
|
---|
2062 | uint32 shid;
|
---|
2063 | SVGAMobId mobid;
|
---|
2064 | uint32 offsetInBytes;
|
---|
2065 | }
|
---|
2066 | #include "vmware_pack_end.h"
|
---|
2067 | SVGA3dCmdBindGBShader; /* SVGA_3D_CMD_BIND_GB_SHADER */
|
---|
2068 |
|
---|
2069 | /*
|
---|
2070 | * Destroy a guest-backed shader.
|
---|
2071 | */
|
---|
2072 |
|
---|
2073 | typedef
|
---|
2074 | #include "vmware_pack_begin.h"
|
---|
2075 | struct SVGA3dCmdDestroyGBShader {
|
---|
2076 | uint32 shid;
|
---|
2077 | }
|
---|
2078 | #include "vmware_pack_end.h"
|
---|
2079 | SVGA3dCmdDestroyGBShader; /* SVGA_3D_CMD_DESTROY_GB_SHADER */
|
---|
2080 |
|
---|
2081 | typedef
|
---|
2082 | #include "vmware_pack_begin.h"
|
---|
2083 | struct {
|
---|
2084 | uint32 cid;
|
---|
2085 | uint32 regStart;
|
---|
2086 | SVGA3dShaderType shaderType;
|
---|
2087 | SVGA3dShaderConstType constType;
|
---|
2088 |
|
---|
2089 | /*
|
---|
2090 | * Followed by a variable number of shader constants.
|
---|
2091 | *
|
---|
2092 | * Note that FLOAT and INT constants are 4-dwords in length, while
|
---|
2093 | * BOOL constants are 1-dword in length.
|
---|
2094 | */
|
---|
2095 | }
|
---|
2096 | #include "vmware_pack_end.h"
|
---|
2097 | SVGA3dCmdSetGBShaderConstInline; /* SVGA_3D_CMD_SET_GB_SHADERCONSTS_INLINE */
|
---|
2098 |
|
---|
2099 |
|
---|
2100 | typedef
|
---|
2101 | #include "vmware_pack_begin.h"
|
---|
2102 | struct {
|
---|
2103 | uint32 cid;
|
---|
2104 | SVGA3dQueryType type;
|
---|
2105 | }
|
---|
2106 | #include "vmware_pack_end.h"
|
---|
2107 | SVGA3dCmdBeginGBQuery; /* SVGA_3D_CMD_BEGIN_GB_QUERY */
|
---|
2108 |
|
---|
2109 | typedef
|
---|
2110 | #include "vmware_pack_begin.h"
|
---|
2111 | struct {
|
---|
2112 | uint32 cid;
|
---|
2113 | SVGA3dQueryType type;
|
---|
2114 | SVGAMobId mobid;
|
---|
2115 | uint32 offset;
|
---|
2116 | }
|
---|
2117 | #include "vmware_pack_end.h"
|
---|
2118 | SVGA3dCmdEndGBQuery; /* SVGA_3D_CMD_END_GB_QUERY */
|
---|
2119 |
|
---|
2120 |
|
---|
2121 | /*
|
---|
2122 | * SVGA_3D_CMD_WAIT_FOR_GB_QUERY --
|
---|
2123 | *
|
---|
2124 | * The semantics of this command are identical to the
|
---|
2125 | * SVGA_3D_CMD_WAIT_FOR_QUERY except that the results are written
|
---|
2126 | * to a Mob instead of a GMR.
|
---|
2127 | */
|
---|
2128 |
|
---|
2129 | typedef
|
---|
2130 | #include "vmware_pack_begin.h"
|
---|
2131 | struct {
|
---|
2132 | uint32 cid;
|
---|
2133 | SVGA3dQueryType type;
|
---|
2134 | SVGAMobId mobid;
|
---|
2135 | uint32 offset;
|
---|
2136 | }
|
---|
2137 | #include "vmware_pack_end.h"
|
---|
2138 | SVGA3dCmdWaitForGBQuery; /* SVGA_3D_CMD_WAIT_FOR_GB_QUERY */
|
---|
2139 |
|
---|
2140 |
|
---|
2141 | typedef
|
---|
2142 | #include "vmware_pack_begin.h"
|
---|
2143 | struct {
|
---|
2144 | SVGAMobId mobid;
|
---|
2145 | uint32 mustBeZero;
|
---|
2146 | uint32 initialized;
|
---|
2147 | }
|
---|
2148 | #include "vmware_pack_end.h"
|
---|
2149 | SVGA3dCmdEnableGart; /* SVGA_3D_CMD_ENABLE_GART */
|
---|
2150 |
|
---|
2151 | typedef
|
---|
2152 | #include "vmware_pack_begin.h"
|
---|
2153 | struct {
|
---|
2154 | SVGAMobId mobid;
|
---|
2155 | uint32 gartOffset;
|
---|
2156 | }
|
---|
2157 | #include "vmware_pack_end.h"
|
---|
2158 | SVGA3dCmdMapMobIntoGart; /* SVGA_3D_CMD_MAP_MOB_INTO_GART */
|
---|
2159 |
|
---|
2160 |
|
---|
2161 | typedef
|
---|
2162 | #include "vmware_pack_begin.h"
|
---|
2163 | struct {
|
---|
2164 | uint32 gartOffset;
|
---|
2165 | uint32 numPages;
|
---|
2166 | }
|
---|
2167 | #include "vmware_pack_end.h"
|
---|
2168 | SVGA3dCmdUnmapGartRange; /* SVGA_3D_CMD_UNMAP_GART_RANGE */
|
---|
2169 |
|
---|
2170 |
|
---|
2171 | /*
|
---|
2172 | * Screen Targets
|
---|
2173 | */
|
---|
2174 |
|
---|
2175 | typedef
|
---|
2176 | #include "vmware_pack_begin.h"
|
---|
2177 | struct {
|
---|
2178 | uint32 stid;
|
---|
2179 | uint32 width;
|
---|
2180 | uint32 height;
|
---|
2181 | int32 xRoot;
|
---|
2182 | int32 yRoot;
|
---|
2183 | SVGAScreenTargetFlags flags;
|
---|
2184 |
|
---|
2185 | /*
|
---|
2186 | * The physical DPI that the guest expects this screen displayed at.
|
---|
2187 | *
|
---|
2188 | * Guests which are not DPI-aware should set this to zero.
|
---|
2189 | */
|
---|
2190 | uint32 dpi;
|
---|
2191 | }
|
---|
2192 | #include "vmware_pack_end.h"
|
---|
2193 | SVGA3dCmdDefineGBScreenTarget; /* SVGA_3D_CMD_DEFINE_GB_SCREENTARGET */
|
---|
2194 |
|
---|
2195 | typedef
|
---|
2196 | #include "vmware_pack_begin.h"
|
---|
2197 | struct {
|
---|
2198 | uint32 stid;
|
---|
2199 | }
|
---|
2200 | #include "vmware_pack_end.h"
|
---|
2201 | SVGA3dCmdDestroyGBScreenTarget; /* SVGA_3D_CMD_DESTROY_GB_SCREENTARGET */
|
---|
2202 |
|
---|
2203 | typedef
|
---|
2204 | #include "vmware_pack_begin.h"
|
---|
2205 | struct {
|
---|
2206 | uint32 stid;
|
---|
2207 | SVGA3dSurfaceImageId image;
|
---|
2208 | }
|
---|
2209 | #include "vmware_pack_end.h"
|
---|
2210 | SVGA3dCmdBindGBScreenTarget; /* SVGA_3D_CMD_BIND_GB_SCREENTARGET */
|
---|
2211 |
|
---|
2212 | typedef
|
---|
2213 | #include "vmware_pack_begin.h"
|
---|
2214 | struct {
|
---|
2215 | uint32 stid;
|
---|
2216 | SVGA3dRect rect;
|
---|
2217 | }
|
---|
2218 | #include "vmware_pack_end.h"
|
---|
2219 | SVGA3dCmdUpdateGBScreenTarget; /* SVGA_3D_CMD_UPDATE_GB_SCREENTARGET */
|
---|
2220 |
|
---|
2221 | typedef
|
---|
2222 | #include "vmware_pack_begin.h"
|
---|
2223 | struct SVGA3dCmdGBScreenDMA {
|
---|
2224 | uint32 screenId;
|
---|
2225 | uint32 dead;
|
---|
2226 | SVGAMobId destMobID;
|
---|
2227 | uint32 destPitch;
|
---|
2228 | SVGAMobId changeMapMobID;
|
---|
2229 | }
|
---|
2230 | #include "vmware_pack_end.h"
|
---|
2231 | SVGA3dCmdGBScreenDMA; /* SVGA_3D_CMD_GB_SCREEN_DMA */
|
---|
2232 |
|
---|
2233 | typedef
|
---|
2234 | #include "vmware_pack_begin.h"
|
---|
2235 | struct {
|
---|
2236 | uint32 value;
|
---|
2237 | uint32 mobId;
|
---|
2238 | uint32 mobOffset;
|
---|
2239 | }
|
---|
2240 | #include "vmware_pack_end.h"
|
---|
2241 | SVGA3dCmdGBMobFence; /* SVGA_3D_CMD_GB_MOB_FENCE */
|
---|
2242 |
|
---|
2243 | typedef
|
---|
2244 | #include "vmware_pack_begin.h"
|
---|
2245 | struct {
|
---|
2246 | uint32 stid;
|
---|
2247 | SVGA3dSurfaceImageId dest;
|
---|
2248 |
|
---|
2249 | uint32 statusMobId;
|
---|
2250 | uint32 statusMobOffset;
|
---|
2251 |
|
---|
2252 | /* Reserved fields */
|
---|
2253 | uint32 mustBeInvalidId;
|
---|
2254 | uint32 mustBeZero;
|
---|
2255 | }
|
---|
2256 | #include "vmware_pack_end.h"
|
---|
2257 | SVGA3dCmdScreenCopy; /* SVGA_3D_CMD_SCREEN_COPY */
|
---|
2258 |
|
---|
2259 | #define SVGA_SCREEN_COPY_STATUS_FAILURE 0x00
|
---|
2260 | #define SVGA_SCREEN_COPY_STATUS_SUCCESS 0x01
|
---|
2261 | #define SVGA_SCREEN_COPY_STATUS_INVALID 0xFFFFFFFF
|
---|
2262 |
|
---|
2263 | typedef
|
---|
2264 | #include "vmware_pack_begin.h"
|
---|
2265 | struct {
|
---|
2266 | uint32 sid;
|
---|
2267 | }
|
---|
2268 | #include "vmware_pack_end.h"
|
---|
2269 | SVGA3dCmdWriteZeroSurface; /* SVGA_3D_CMD_WRITE_ZERO_SURFACE */
|
---|
2270 |
|
---|
2271 | typedef
|
---|
2272 | #include "vmware_pack_begin.h"
|
---|
2273 | struct {
|
---|
2274 | uint32 sid;
|
---|
2275 | }
|
---|
2276 | #include "vmware_pack_end.h"
|
---|
2277 | SVGA3dCmdHintZeroSurface; /* SVGA_3D_CMD_HINT_ZERO_SURFACE */
|
---|
2278 |
|
---|
2279 | #endif /* _SVGA3D_CMD_H_ */
|
---|