VirtualBox

source: vbox/trunk/src/VBox/Devices/Graphics/DevVGA-SVGA3d.h@ 88787

Last change on this file since 88787 was 88787, checked in by vboxsync, 4 years ago

Devices/Graphics: a few DX commands. bugref:9830

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 40.3 KB
Line 
1/* $Id: DevVGA-SVGA3d.h 88787 2021-04-29 15:51:13Z vboxsync $ */
2/** @file
3 * DevVMWare - VMWare SVGA device - 3D part.
4 */
5
6/*
7 * Copyright (C) 2013-2020 Oracle Corporation
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.virtualbox.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License (GPL) as published by the Free Software
13 * Foundation, in version 2 as it comes in the "COPYING" file of the
14 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16 */
17
18#ifndef VBOX_INCLUDED_SRC_Graphics_DevVGA_SVGA3d_h
19#define VBOX_INCLUDED_SRC_Graphics_DevVGA_SVGA3d_h
20#ifndef RT_WITHOUT_PRAGMA_ONCE
21# pragma once
22#endif
23
24#include "DevVGA-SVGA.h"
25
26
27/** Arbitrary limit */
28#define SVGA3D_MAX_SHADER_IDS 0x800
29/** D3D allows up to 8 texture stages. */
30#define SVGA3D_MAX_TEXTURE_STAGES 8
31/** Samplers: 16 Pixel Shader + 1 Displacement Map + 4 Vertex Shader */
32#define SVGA3D_MAX_SAMPLERS_PS 16
33#define SVGA3D_MAX_SAMPLERS_DMAP 1
34#define SVGA3D_MAX_SAMPLERS_VS 4
35#define SVGA3D_MAX_SAMPLERS (SVGA3D_MAX_SAMPLERS_PS + SVGA3D_MAX_SAMPLERS_DMAP + SVGA3D_MAX_SAMPLERS_VS)
36/** Arbitrary upper limit; seen 8 so far. */
37#define SVGA3D_MAX_LIGHTS 32
38/** Arbitrary upper limit; 2GB enough for 32768x16384*4. */
39#define SVGA3D_MAX_SURFACE_MEM_SIZE 0x80000000
40
41
42/**@def FLOAT_FMT_STR
43 * Format string bits to go with FLOAT_FMT_ARGS. */
44#define FLOAT_FMT_STR "%s%u.%06u"
45/** @def FLOAT_FMT_ARGS
46 * Format arguments for a float value, corresponding to FLOAT_FMT_STR.
47 * @param r The floating point value to format. */
48#define FLOAT_FMT_ARGS(r) (r) >= 0.0f ? "" : "-", (unsigned)RT_ABS(r), (unsigned)(RT_ABS((r) - (unsigned)(r)) * 1000000.0f)
49
50
51typedef enum VMSVGA3D_SURFACE_MAP
52{
53 VMSVGA3D_SURFACE_MAP_READ,
54 VMSVGA3D_SURFACE_MAP_WRITE,
55 VMSVGA3D_SURFACE_MAP_READ_WRITE,
56 VMSVGA3D_SURFACE_MAP_WRITE_DISCARD,
57} VMSVGA3D_SURFACE_MAP;
58
59typedef struct VMSVGA3D_MAPPED_SURFACE
60{
61 VMSVGA3D_SURFACE_MAP enmMapType;
62 SVGA3dBox box;
63 uint32_t cbPixel;
64 uint32_t cbRowPitch;
65 uint32_t cbDepthPitch;
66 void *pvData;
67} VMSVGA3D_MAPPED_SURFACE;
68
69#ifdef DUMP_BITMAPS
70void vmsvga3dMapWriteBmpFile(VMSVGA3D_MAPPED_SURFACE const *pMap, char const *pszPrefix);
71#endif
72
73/* DevVGA-SVGA.cpp: */
74void vmsvgaR33dSurfaceUpdateHeapBuffersOnFifoThread(PPDMDEVINS pDevIns, PVGASTATE pThis, PVGASTATECC pThisCC, uint32_t sid);
75
76
77/* DevVGA-SVGA3d-ogl.cpp & DevVGA-SVGA3d-win.cpp: */
78int vmsvga3dInit(PPDMDEVINS pDevIns, PVGASTATE pThis, PVGASTATECC pThisCC);
79int vmsvga3dPowerOn(PPDMDEVINS pDevIns, PVGASTATE pThis, PVGASTATECC pThisCC);
80int vmsvga3dLoadExec(PPDMDEVINS pDevIns, PVGASTATE pThis, PVGASTATECC pThisCC, PSSMHANDLE pSSM, uint32_t uVersion, uint32_t uPass);
81int vmsvga3dSaveExec(PPDMDEVINS pDevIns, PVGASTATECC pThisCC, PSSMHANDLE pSSM);
82int vmsvga3dTerminate(PVGASTATECC pThisCC);
83int vmsvga3dReset(PVGASTATECC pThisCC);
84void vmsvga3dUpdateHostScreenViewport(PVGASTATECC pThisCC, uint32_t idScreen, VMSVGAVIEWPORT const *pOldViewport);
85int vmsvga3dQueryCaps(PVGASTATECC pThisCC, SVGA3dDevCapIndex idx3dCaps, uint32_t *pu32Val);
86
87int vmsvga3dSurfaceDefine(PVGASTATECC pThisCC, uint32_t sid, SVGA3dSurface1Flags surfaceFlags, SVGA3dSurfaceFormat format,
88 uint32_t multisampleCount, SVGA3dTextureFilter autogenFilter,
89 uint32_t cMipLevels, SVGA3dSize const *pMipLevel0Size);
90int vmsvga3dSurfaceDestroy(PVGASTATECC pThisCC, uint32_t sid);
91int vmsvga3dSurfaceCopy(PVGASTATECC pThisCC, SVGA3dSurfaceImageId dest, SVGA3dSurfaceImageId src,
92 uint32_t cCopyBoxes, SVGA3dCopyBox *pBox);
93int vmsvga3dSurfaceStretchBlt(PVGASTATE pThis, PVGASTATECC pThisCC,
94 SVGA3dSurfaceImageId const *pDstSfcImg, SVGA3dBox const *pDstBox,
95 SVGA3dSurfaceImageId const *pSrcSfcImg, SVGA3dBox const *pSrcBox, SVGA3dStretchBltMode enmMode);
96int vmsvga3dSurfaceDMA(PVGASTATE pThis, PVGASTATECC pThisCC, SVGAGuestImage guest, SVGA3dSurfaceImageId host, SVGA3dTransferType transfer, uint32_t cCopyBoxes, SVGA3dCopyBox *pBoxes);
97int vmsvga3dSurfaceBlitToScreen(PVGASTATE pThis, PVGASTATECC pThisCC, uint32_t dest, SVGASignedRect destRect, SVGA3dSurfaceImageId srcImage, SVGASignedRect srcRect, uint32_t cRects, SVGASignedRect *pRect);
98
99int vmsvga3dContextDefine(PVGASTATECC pThisCC, uint32_t cid);
100int vmsvga3dContextDestroy(PVGASTATECC pThisCC, uint32_t cid);
101
102int vmsvga3dChangeMode(PVGASTATECC pThisCC);
103
104int vmsvga3dDefineScreen(PVGASTATE pThis, PVGASTATECC pThisCC, VMSVGASCREENOBJECT *pScreen);
105int vmsvga3dDestroyScreen(PVGASTATECC pThisCC, VMSVGASCREENOBJECT *pScreen);
106
107int vmsvga3dSetTransform(PVGASTATECC pThisCC, uint32_t cid, SVGA3dTransformType type, float matrix[16]);
108int vmsvga3dSetZRange(PVGASTATECC pThisCC, uint32_t cid, SVGA3dZRange zRange);
109int vmsvga3dSetRenderState(PVGASTATECC pThisCC, uint32_t cid, uint32_t cRenderStates, SVGA3dRenderState *pRenderState);
110int vmsvga3dSetRenderTarget(PVGASTATECC pThisCC, uint32_t cid, SVGA3dRenderTargetType type, SVGA3dSurfaceImageId target);
111int vmsvga3dSetTextureState(PVGASTATECC pThisCC, uint32_t cid, uint32_t cTextureStates, SVGA3dTextureState *pTextureState);
112int vmsvga3dSetMaterial(PVGASTATECC pThisCC, uint32_t cid, SVGA3dFace face, SVGA3dMaterial *pMaterial);
113int vmsvga3dSetLightData(PVGASTATECC pThisCC, uint32_t cid, uint32_t index, SVGA3dLightData *pData);
114int vmsvga3dSetLightEnabled(PVGASTATECC pThisCC, uint32_t cid, uint32_t index, uint32_t enabled);
115int vmsvga3dSetViewPort(PVGASTATECC pThisCC, uint32_t cid, SVGA3dRect *pRect);
116int vmsvga3dSetClipPlane(PVGASTATECC pThisCC, uint32_t cid, uint32_t index, float plane[4]);
117int vmsvga3dCommandClear(PVGASTATECC pThisCC, uint32_t cid, SVGA3dClearFlag clearFlag, uint32_t color, float depth, uint32_t stencil, uint32_t cRects, SVGA3dRect *pRect);
118int vmsvga3dCommandPresent(PVGASTATE pThis, PVGASTATECC pThisCC, uint32_t sid, uint32_t cRects, SVGA3dCopyRect *pRect);
119int vmsvga3dDrawPrimitives(PVGASTATECC pThisCC, uint32_t cid, uint32_t numVertexDecls, SVGA3dVertexDecl *pVertexDecl, uint32_t numRanges, SVGA3dPrimitiveRange *pNumRange, uint32_t cVertexDivisor, SVGA3dVertexDivisor *pVertexDivisor);
120int vmsvga3dSetScissorRect(PVGASTATECC pThisCC, uint32_t cid, SVGA3dRect *pRect);
121int vmsvga3dGenerateMipmaps(PVGASTATECC pThisCC, uint32_t sid, SVGA3dTextureFilter filter);
122
123int vmsvga3dShaderDefine(PVGASTATECC pThisCC, uint32_t cid, uint32_t shid, SVGA3dShaderType type, uint32_t cbData, uint32_t *pShaderData);
124int vmsvga3dShaderDestroy(PVGASTATECC pThisCC, uint32_t cid, uint32_t shid, SVGA3dShaderType type);
125int vmsvga3dShaderSet(PVGASTATECC pThisCC, struct VMSVGA3DCONTEXT *pContext, uint32_t cid, SVGA3dShaderType type, uint32_t shid);
126int vmsvga3dShaderSetConst(PVGASTATECC pThisCC, uint32_t cid, uint32_t reg, SVGA3dShaderType type, SVGA3dShaderConstType ctype, uint32_t cRegisters, uint32_t *pValues);
127
128int vmsvga3dQueryBegin(PVGASTATECC pThisCC, uint32_t cid, SVGA3dQueryType type);
129int vmsvga3dQueryEnd(PVGASTATECC pThisCC, uint32_t cid, SVGA3dQueryType type, SVGAGuestPtr guestResult);
130int vmsvga3dQueryWait(PVGASTATE pThis, PVGASTATECC pThisCC, uint32_t cid, SVGA3dQueryType type, SVGAGuestPtr guestResult);
131
132int vmsvga3dSurfaceInvalidate(PVGASTATECC pThisCC, uint32_t sid, uint32_t face, uint32_t mipmap);
133
134/* DevVGA-SVGA3d-shared.h: */
135#if defined(RT_OS_WINDOWS) && defined(IN_RING3)
136# include <iprt/win/windows.h>
137
138# define WM_VMSVGA3D_WAKEUP (WM_APP+1)
139# define WM_VMSVGA3D_CREATEWINDOW (WM_APP+2)
140# define WM_VMSVGA3D_DESTROYWINDOW (WM_APP+3)
141# define WM_VMSVGA3D_EXIT (WM_APP+5)
142# if 0
143# define WM_VMSVGA3D_CREATE_DEVICE (WM_APP+6)
144typedef struct VMSVGA3DCREATEDEVICEPARAMS
145{
146 struct VMSVGA3DSTATE *pState;
147 struct VMSVGA3DCONTEXT *pContext;
148 struct _D3DPRESENT_PARAMETERS_ *pPresParams;
149 HRESULT hrc;
150} VMSVGA3DCREATEDEVICEPARAMS;
151# endif
152
153DECLCALLBACK(int) vmsvga3dWindowThread(RTTHREAD ThreadSelf, void *pvUser);
154int vmsvga3dSendThreadMessage(RTTHREAD pWindowThread, RTSEMEVENT WndRequestSem, UINT msg, WPARAM wParam, LPARAM lParam);
155int vmsvga3dContextWindowCreate(HINSTANCE hInstance, RTTHREAD pWindowThread, RTSEMEVENT WndRequestSem, HWND *pHwnd);
156
157#endif
158
159void vmsvga3dUpdateHeapBuffersForSurfaces(PVGASTATECC pThisCC, uint32_t sid);
160void vmsvga3dInfoContextWorker(PVGASTATECC pThisCC, PCDBGFINFOHLP pHlp, uint32_t cid, bool fVerbose);
161void vmsvga3dInfoSurfaceWorker(PPDMDEVINS pDevIns, PVGASTATE pThis, PVGASTATECC pThisCC, PCDBGFINFOHLP pHlp, uint32_t sid,
162 bool fVerbose, uint32_t cxAscii, bool fInvY, const char *pszBitmapPath);
163
164/* DevVGA-SVGA3d-shared.cpp: */
165
166/**
167 * Structure for use with vmsvga3dInfoU32Flags.
168 */
169typedef struct VMSVGAINFOFLAGS32
170{
171 /** The flags. */
172 uint32_t fFlags;
173 /** The corresponding mnemonic. */
174 const char *pszJohnny;
175} VMSVGAINFOFLAGS32;
176/** Pointer to a read-only flag translation entry. */
177typedef VMSVGAINFOFLAGS32 const *PCVMSVGAINFOFLAGS32;
178void vmsvga3dInfoU32Flags(PCDBGFINFOHLP pHlp, uint32_t fFlags, const char *pszPrefix, PCVMSVGAINFOFLAGS32 paFlags, uint32_t cFlags);
179
180/**
181 * Structure for use with vmsvgaFormatEnumValueEx and vmsvgaFormatEnumValue.
182 */
183typedef struct VMSVGAINFOENUM
184{
185 /** The enum value. */
186 int32_t iValue;
187 /** The corresponding value name. */
188 const char *pszName;
189} VMSVGAINFOENUM;
190/** Pointer to a read-only enum value translation entry. */
191typedef VMSVGAINFOENUM const *PCVMSVGAINFOENUM;
192/**
193 * Structure for use with vmsvgaFormatEnumValueEx and vmsvgaFormatEnumValue.
194 */
195typedef struct VMSVGAINFOENUMMAP
196{
197 /** Pointer to the value mapping array. */
198 PCVMSVGAINFOENUM paValues;
199 /** The number of value mappings. */
200 size_t cValues;
201 /** The prefix. */
202 const char *pszPrefix;
203#ifdef RT_STRICT
204 /** Indicates whether we've checked that it's sorted or not. */
205 bool *pfAsserted;
206#endif
207} VMSVGAINFOENUMMAP;
208typedef VMSVGAINFOENUMMAP const *PCVMSVGAINFOENUMMAP;
209/** @def VMSVGAINFOENUMMAP_MAKE
210 * Macro for defining a VMSVGAINFOENUMMAP, silently dealing with pfAsserted.
211 *
212 * @param a_Scope The scope. RT_NOTHING or static.
213 * @param a_VarName The variable name for this map.
214 * @param a_aValues The variable name of the value mapping array.
215 * @param a_pszPrefix The value name prefix.
216 */
217#ifdef VBOX_STRICT
218# define VMSVGAINFOENUMMAP_MAKE(a_Scope, a_VarName, a_aValues, a_pszPrefix) \
219 static bool RT_CONCAT(a_VarName,_AssertedSorted) = false; \
220 a_Scope VMSVGAINFOENUMMAP const a_VarName = { \
221 a_aValues, RT_ELEMENTS(a_aValues), a_pszPrefix, &RT_CONCAT(a_VarName,_AssertedSorted) \
222 }
223#else
224# define VMSVGAINFOENUMMAP_MAKE(a_Scope, a_VarName, a_aValues, a_pszPrefix) \
225 a_Scope VMSVGAINFOENUMMAP const a_VarName = { a_aValues, RT_ELEMENTS(a_aValues), a_pszPrefix }
226#endif
227extern VMSVGAINFOENUMMAP const g_SVGA3dSurfaceFormat2String;
228const char *vmsvgaLookupEnum(int32_t iValue, PCVMSVGAINFOENUMMAP pEnumMap);
229char *vmsvgaFormatEnumValueEx(char *pszBuffer, size_t cbBuffer, const char *pszName, int32_t iValue,
230 bool fPrefix, PCVMSVGAINFOENUMMAP pEnumMap);
231char *vmsvgaFormatEnumValue(char *pszBuffer, size_t cbBuffer, const char *pszName, uint32_t uValue,
232 const char *pszPrefix, const char * const *papszValues, size_t cValues);
233
234/**
235 * ASCII "art" scanline printer callback.
236 *
237 * @param pszLine The line to output.
238 * @param pvUser The user argument.
239 */
240typedef DECLCALLBACKTYPE(void, FNVMSVGAASCIIPRINTLN,(const char *pszLine, void *pvUser));
241/** Pointer to an ASCII "art" print line callback. */
242typedef FNVMSVGAASCIIPRINTLN *PFNVMSVGAASCIIPRINTLN;
243void vmsvga3dAsciiPrint(PFNVMSVGAASCIIPRINTLN pfnPrintLine, void *pvUser, void const *pvImage, size_t cbImage,
244 uint32_t cx, uint32_t cy, uint32_t cbScanline, SVGA3dSurfaceFormat enmFormat, bool fInvY,
245 uint32_t cchMaxX, uint32_t cchMaxY);
246DECLCALLBACK(void) vmsvga3dAsciiPrintlnInfo(const char *pszLine, void *pvUser);
247DECLCALLBACK(void) vmsvga3dAsciiPrintlnLog(const char *pszLine, void *pvUser);
248
249char *vmsvga3dFormatRenderState(char *pszBuffer, size_t cbBuffer, SVGA3dRenderState const *pRenderState);
250char *vmsvga3dFormatTextureState(char *pszBuffer, size_t cbBuffer, SVGA3dTextureState const *pTextureState);
251void vmsvga3dInfoHostWindow(PCDBGFINFOHLP pHlp, uint64_t idHostWindow);
252
253uint32_t vmsvga3dSurfaceFormatSize(SVGA3dSurfaceFormat format,
254 uint32_t *pu32BlockWidth,
255 uint32_t *pu32BlockHeight);
256
257#ifdef LOG_ENABLED
258const char *vmsvga3dGetCapString(uint32_t idxCap);
259const char *vmsvga3dGet3dFormatString(uint32_t format);
260const char *vmsvga3dGetRenderStateName(uint32_t state);
261const char *vmsvga3dTextureStateToString(SVGA3dTextureStateName textureState);
262const char *vmsvgaTransformToString(SVGA3dTransformType type);
263const char *vmsvgaDeclUsage2String(SVGA3dDeclUsage usage);
264const char *vmsvgaDeclType2String(SVGA3dDeclType type);
265const char *vmsvgaDeclMethod2String(SVGA3dDeclMethod method);
266const char *vmsvgaSurfaceType2String(SVGA3dSurfaceFormat format);
267const char *vmsvga3dPrimitiveType2String(SVGA3dPrimitiveType PrimitiveType);
268#endif
269
270
271#define VMSVGA3D_BACKEND_INTERFACE_NAME_GBO "GBO"
272typedef struct
273{
274 DECLCALLBACKMEMBER(int, pfnScreenTargetBind, (PVGASTATECC pThisCC, VMSVGASCREENOBJECT *pScreen, uint32_t sid));
275 DECLCALLBACKMEMBER(int, pfnScreenTargetUpdate, (PVGASTATECC pThisCC, VMSVGASCREENOBJECT *pScreen, SVGA3dRect const *pRect));
276} VMSVGA3DBACKENDFUNCSGBO;
277
278#define VMSVGA3D_BACKEND_INTERFACE_NAME_MAP "MAP"
279typedef struct
280{
281 DECLCALLBACKMEMBER(int, pfnSurfaceMap, (PVGASTATECC pThisCC, SVGA3dSurfaceImageId const *pImage, SVGA3dBox const *pBox, VMSVGA3D_SURFACE_MAP enmMapType, VMSVGA3D_MAPPED_SURFACE *pMap));
282 DECLCALLBACKMEMBER(int, pfnSurfaceUnmap, (PVGASTATECC pThisCC, SVGA3dSurfaceImageId const *pImage, VMSVGA3D_MAPPED_SURFACE *pMap, bool fWritten));
283} VMSVGA3DBACKENDFUNCSMAP;
284
285typedef struct VMSVGA3DSHADER *PVMSVGA3DSHADER;
286typedef struct VMSVGA3DDXCONTEXT *PVMSVGA3DDXCONTEXT;
287#define VMSVGA3D_BACKEND_INTERFACE_NAME_DX "DX"
288typedef struct
289{
290 DECLCALLBACKMEMBER(int, pfnDXDefineContext, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
291 DECLCALLBACKMEMBER(int, pfnDXDestroyContext, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
292 DECLCALLBACKMEMBER(int, pfnDXBindContext, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
293 DECLCALLBACKMEMBER(int, pfnDXReadbackContext, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
294 DECLCALLBACKMEMBER(int, pfnDXInvalidateContext, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
295 DECLCALLBACKMEMBER(int, pfnDXSetSingleConstantBuffer, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, uint32_t slot, SVGA3dShaderType type, SVGA3dSurfaceId sid, uint32_t offsetInBytes, uint32_t sizeInBytes));
296 DECLCALLBACKMEMBER(int, pfnDXSetShaderResources, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
297 DECLCALLBACKMEMBER(int, pfnDXSetShader, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, PVMSVGA3DSHADER pShader));
298 DECLCALLBACKMEMBER(int, pfnDXSetSamplers, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, uint32_t startSampler, SVGA3dShaderType type, uint32_t cSamplerId, SVGA3dSamplerId const *paSamplerId));
299 DECLCALLBACKMEMBER(int, pfnDXDraw, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, uint32_t vertexCount, uint32_t startVertexLocation));
300 DECLCALLBACKMEMBER(int, pfnDXDrawIndexed, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, uint32_t indexCount, uint32_t startIndexLocation, int32_t baseVertexLocation));
301 DECLCALLBACKMEMBER(int, pfnDXDrawInstanced, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
302 DECLCALLBACKMEMBER(int, pfnDXDrawIndexedInstanced, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
303 DECLCALLBACKMEMBER(int, pfnDXDrawAuto, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
304 DECLCALLBACKMEMBER(int, pfnDXSetInputLayout, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dElementLayoutId elementLayoutId));
305 DECLCALLBACKMEMBER(int, pfnDXSetVertexBuffers, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, uint32_t startBuffer, uint32_t cVertexBuffer, SVGA3dVertexBuffer const *paVertexBuffer));
306 DECLCALLBACKMEMBER(int, pfnDXSetIndexBuffer, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dSurfaceId sid, SVGA3dSurfaceFormat format, uint32_t offset));
307 DECLCALLBACKMEMBER(int, pfnDXSetTopology, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dPrimitiveType topology));
308 DECLCALLBACKMEMBER(int, pfnDXSetRenderTargets, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dDepthStencilViewId depthStencilViewId, uint32_t cRenderTargetViewId, SVGA3dRenderTargetViewId const *paRenderTargetViewId));
309 DECLCALLBACKMEMBER(int, pfnDXSetBlendState, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dBlendStateId blendId, float const blendFactor[4], uint32_t sampleMask));
310 DECLCALLBACKMEMBER(int, pfnDXSetDepthStencilState, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dDepthStencilStateId depthStencilId, uint32_t stencilRef));
311 DECLCALLBACKMEMBER(int, pfnDXSetRasterizerState, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dRasterizerStateId rasterizerId));
312 DECLCALLBACKMEMBER(int, pfnDXDefineQuery, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
313 DECLCALLBACKMEMBER(int, pfnDXDestroyQuery, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
314 DECLCALLBACKMEMBER(int, pfnDXBindQuery, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
315 DECLCALLBACKMEMBER(int, pfnDXSetQueryOffset, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
316 DECLCALLBACKMEMBER(int, pfnDXBeginQuery, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
317 DECLCALLBACKMEMBER(int, pfnDXEndQuery, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
318 DECLCALLBACKMEMBER(int, pfnDXReadbackQuery, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
319 DECLCALLBACKMEMBER(int, pfnDXSetPredication, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
320 DECLCALLBACKMEMBER(int, pfnDXSetSOTargets, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
321 DECLCALLBACKMEMBER(int, pfnDXSetViewports, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, uint32_t cViewport, SVGA3dViewport const *paViewport));
322 DECLCALLBACKMEMBER(int, pfnDXSetScissorRects, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, uint32_t cRect, SVGASignedRect const *paRect));
323 DECLCALLBACKMEMBER(int, pfnDXClearRenderTargetView, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
324 DECLCALLBACKMEMBER(int, pfnDXClearDepthStencilView, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
325 DECLCALLBACKMEMBER(int, pfnDXPredCopyRegion, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
326 DECLCALLBACKMEMBER(int, pfnDXPredCopy, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
327 DECLCALLBACKMEMBER(int, pfnDXPresentBlt, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
328 DECLCALLBACKMEMBER(int, pfnDXGenMips, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
329 DECLCALLBACKMEMBER(int, pfnDXUpdateSubResource, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
330 DECLCALLBACKMEMBER(int, pfnDXReadbackSubResource, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
331 DECLCALLBACKMEMBER(int, pfnDXInvalidateSubResource, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
332 DECLCALLBACKMEMBER(int, pfnDXDefineShaderResourceView, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dShaderResourceViewId shaderResourceViewId, SVGACOTableDXSRViewEntry const *pEntry));
333 DECLCALLBACKMEMBER(int, pfnDXDestroyShaderResourceView, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
334 DECLCALLBACKMEMBER(int, pfnDXDefineRenderTargetView, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dRenderTargetViewId renderTargetViewId, SVGACOTableDXRTViewEntry const *pEntry));
335 DECLCALLBACKMEMBER(int, pfnDXDestroyRenderTargetView, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
336 DECLCALLBACKMEMBER(int, pfnDXDefineDepthStencilView, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
337 DECLCALLBACKMEMBER(int, pfnDXDestroyDepthStencilView, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
338 DECLCALLBACKMEMBER(int, pfnDXDefineElementLayout, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dElementLayoutId elementLayoutId, SVGACOTableDXElementLayoutEntry const *pEntry));
339 DECLCALLBACKMEMBER(int, pfnDXDestroyElementLayout, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
340 DECLCALLBACKMEMBER(int, pfnDXDefineBlendState, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dBlendStateId blendId, SVGACOTableDXBlendStateEntry const *pEntry));
341 DECLCALLBACKMEMBER(int, pfnDXDestroyBlendState, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
342 DECLCALLBACKMEMBER(int, pfnDXDefineDepthStencilState, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dDepthStencilStateId depthStencilId, SVGACOTableDXDepthStencilEntry *pEntry));
343 DECLCALLBACKMEMBER(int, pfnDXDestroyDepthStencilState, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
344 DECLCALLBACKMEMBER(int, pfnDXDefineRasterizerState, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dRasterizerStateId rasterizerId, SVGACOTableDXRasterizerStateEntry const *pEntry));
345 DECLCALLBACKMEMBER(int, pfnDXDestroyRasterizerState, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
346 DECLCALLBACKMEMBER(int, pfnDXDefineSamplerState, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGA3dSamplerId samplerId, SVGACOTableDXSamplerEntry const *pEntry));
347 DECLCALLBACKMEMBER(int, pfnDXDestroySamplerState, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
348 DECLCALLBACKMEMBER(int, pfnDXDefineShader, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, PVMSVGA3DSHADER pShader));
349 DECLCALLBACKMEMBER(int, pfnDXDestroyShader, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
350 DECLCALLBACKMEMBER(int, pfnDXBindShader, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, PVMSVGA3DSHADER pShader, void const *pvShaderBytecode));
351 DECLCALLBACKMEMBER(int, pfnDXDefineStreamOutput, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
352 DECLCALLBACKMEMBER(int, pfnDXDestroyStreamOutput, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
353 DECLCALLBACKMEMBER(int, pfnDXSetStreamOutput, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
354 DECLCALLBACKMEMBER(int, pfnDXSetCOTable, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext, SVGACOTableType type, uint32_t cEntries));
355 DECLCALLBACKMEMBER(int, pfnDXReadbackCOTable, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
356 DECLCALLBACKMEMBER(int, pfnDXBufferCopy, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
357 DECLCALLBACKMEMBER(int, pfnDXTransferFromBuffer, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
358 DECLCALLBACKMEMBER(int, pfnDXSurfaceCopyAndReadback, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
359 DECLCALLBACKMEMBER(int, pfnDXMoveQuery, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
360 DECLCALLBACKMEMBER(int, pfnDXBindAllQuery, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
361 DECLCALLBACKMEMBER(int, pfnDXReadbackAllQuery, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
362 DECLCALLBACKMEMBER(int, pfnDXPredTransferFromBuffer, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
363 DECLCALLBACKMEMBER(int, pfnDXMobFence64, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
364 DECLCALLBACKMEMBER(int, pfnDXBindAllShader, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
365 DECLCALLBACKMEMBER(int, pfnDXHint, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
366 DECLCALLBACKMEMBER(int, pfnDXBufferUpdate, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
367 DECLCALLBACKMEMBER(int, pfnDXSetVSConstantBufferOffset, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
368 DECLCALLBACKMEMBER(int, pfnDXSetPSConstantBufferOffset, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
369 DECLCALLBACKMEMBER(int, pfnDXSetGSConstantBufferOffset, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
370 DECLCALLBACKMEMBER(int, pfnDXSetHSConstantBufferOffset, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
371 DECLCALLBACKMEMBER(int, pfnDXSetDSConstantBufferOffset, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
372 DECLCALLBACKMEMBER(int, pfnDXSetCSConstantBufferOffset, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
373 DECLCALLBACKMEMBER(int, pfnDXCondBindAllShader, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
374 DECLCALLBACKMEMBER(int, pfnScreenCopy, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
375 DECLCALLBACKMEMBER(int, pfnGrowOTable, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
376 DECLCALLBACKMEMBER(int, pfnDXGrowCOTable, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
377 DECLCALLBACKMEMBER(int, pfnIntraSurfaceCopy, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
378 DECLCALLBACKMEMBER(int, pfnDefineGBSurface_v3, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
379 DECLCALLBACKMEMBER(int, pfnDXResolveCopy, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
380 DECLCALLBACKMEMBER(int, pfnDXPredResolveCopy, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
381 DECLCALLBACKMEMBER(int, pfnDXPredConvertRegion, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
382 DECLCALLBACKMEMBER(int, pfnDXPredConvert, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
383 DECLCALLBACKMEMBER(int, pfnWholeSurfaceCopy, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
384 DECLCALLBACKMEMBER(int, pfnDXDefineUAView, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
385 DECLCALLBACKMEMBER(int, pfnDXDestroyUAView, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
386 DECLCALLBACKMEMBER(int, pfnDXClearUAViewUint, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
387 DECLCALLBACKMEMBER(int, pfnDXClearUAViewFloat, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
388 DECLCALLBACKMEMBER(int, pfnDXCopyStructureCount, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
389 DECLCALLBACKMEMBER(int, pfnDXSetUAViews, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
390 DECLCALLBACKMEMBER(int, pfnDXDrawIndexedInstancedIndirect, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
391 DECLCALLBACKMEMBER(int, pfnDXDrawInstancedIndirect, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
392 DECLCALLBACKMEMBER(int, pfnDXDispatch, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
393 DECLCALLBACKMEMBER(int, pfnDXDispatchIndirect, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
394 DECLCALLBACKMEMBER(int, pfnWriteZeroSurface, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
395 DECLCALLBACKMEMBER(int, pfnHintZeroSurface, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
396 DECLCALLBACKMEMBER(int, pfnDXTransferToBuffer, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
397 DECLCALLBACKMEMBER(int, pfnDXSetStructureCount, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
398 DECLCALLBACKMEMBER(int, pfnLogicOpsBitBlt, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
399 DECLCALLBACKMEMBER(int, pfnLogicOpsTransBlt, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
400 DECLCALLBACKMEMBER(int, pfnLogicOpsStretchBlt, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
401 DECLCALLBACKMEMBER(int, pfnLogicOpsColorFill, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
402 DECLCALLBACKMEMBER(int, pfnLogicOpsAlphaBlend, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
403 DECLCALLBACKMEMBER(int, pfnLogicOpsClearTypeBlend, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
404 DECLCALLBACKMEMBER(int, pfnDefineGBSurface_v4, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
405 DECLCALLBACKMEMBER(int, pfnDXSetCSUAViews, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
406 DECLCALLBACKMEMBER(int, pfnDXSetMinLOD, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
407 DECLCALLBACKMEMBER(int, pfnDXDefineDepthStencilView_v2, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
408 DECLCALLBACKMEMBER(int, pfnDXDefineStreamOutputWithMob, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
409 DECLCALLBACKMEMBER(int, pfnDXSetShaderIface, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
410 DECLCALLBACKMEMBER(int, pfnDXBindStreamOutput, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
411 DECLCALLBACKMEMBER(int, pfnSurfaceStretchBltNonMSToMS, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
412 DECLCALLBACKMEMBER(int, pfnDXBindShaderIface, (PVGASTATECC pThisCC, PVMSVGA3DDXCONTEXT pDXContext));
413} VMSVGA3DBACKENDFUNCSDX;
414
415int vmsvga3dQueryInterface(PVGASTATECC pThisCC, char const *pszInterfaceName, void *pvInterfaceFuncs, size_t cbInterfaceFuncs);
416
417#ifdef VMSVGA3D_DX
418/* Helpers. */
419int vmsvga3dDXUnbindContext(PVGASTATECC pThisCC, uint32_t cid, SVGADXContextMobFormat *pSvgaDXContext);
420
421/* Command handlers. */
422int vmsvga3dDXDefineContext(PVGASTATECC pThisCC, uint32_t cid);
423int vmsvga3dDXDestroyContext(PVGASTATECC pThisCC, uint32_t cid);
424int vmsvga3dDXBindContext(PVGASTATECC pThisCC, uint32_t cid, SVGADXContextMobFormat *pSvgaDXContext);
425int vmsvga3dDXReadbackContext(PVGASTATECC pThisCC, uint32_t idDXContext);
426int vmsvga3dDXInvalidateContext(PVGASTATECC pThisCC, uint32_t idDXContext);
427int vmsvga3dDXSetSingleConstantBuffer(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXSetSingleConstantBuffer const *pCmd);
428int vmsvga3dDXSetShaderResources(PVGASTATECC pThisCC, uint32_t idDXContext);
429int vmsvga3dDXSetShader(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXSetShader const *pCmd);
430int vmsvga3dDXSetSamplers(PVGASTATECC pThisCC, uint32_t idDXContext, uint32_t startSampler, SVGA3dShaderType type, uint32_t cSamplerId, SVGA3dSamplerId const *paSamplerId);
431int vmsvga3dDXDraw(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXDraw const *pCmd);
432int vmsvga3dDXDrawIndexed(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXDrawIndexed const *pCmd);
433int vmsvga3dDXDrawInstanced(PVGASTATECC pThisCC, uint32_t idDXContext);
434int vmsvga3dDXDrawIndexedInstanced(PVGASTATECC pThisCC, uint32_t idDXContext);
435int vmsvga3dDXDrawAuto(PVGASTATECC pThisCC, uint32_t idDXContext);
436int vmsvga3dDXSetInputLayout(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dElementLayoutId elementLayoutId);
437int vmsvga3dDXSetVertexBuffers(PVGASTATECC pThisCC, uint32_t idDXContext, uint32_t startBuffer, uint32_t cVertexBuffer, SVGA3dVertexBuffer const *paVertexBuffer);
438int vmsvga3dDXSetIndexBuffer(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXSetIndexBuffer const *pCmd);
439int vmsvga3dDXSetTopology(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dPrimitiveType topology);
440int vmsvga3dDXSetRenderTargets(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dDepthStencilViewId depthStencilViewId, uint32_t cRenderTargetViewId, SVGA3dRenderTargetViewId const *paRenderTargetViewId);
441int vmsvga3dDXSetBlendState(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXSetBlendState const *pCmd);
442int vmsvga3dDXSetDepthStencilState(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXSetDepthStencilState const *pCmd);
443int vmsvga3dDXSetRasterizerState(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dRasterizerStateId rasterizerId);
444int vmsvga3dDXDefineQuery(PVGASTATECC pThisCC, uint32_t idDXContext);
445int vmsvga3dDXDestroyQuery(PVGASTATECC pThisCC, uint32_t idDXContext);
446int vmsvga3dDXBindQuery(PVGASTATECC pThisCC, uint32_t idDXContext);
447int vmsvga3dDXSetQueryOffset(PVGASTATECC pThisCC, uint32_t idDXContext);
448int vmsvga3dDXBeginQuery(PVGASTATECC pThisCC, uint32_t idDXContext);
449int vmsvga3dDXEndQuery(PVGASTATECC pThisCC, uint32_t idDXContext);
450int vmsvga3dDXReadbackQuery(PVGASTATECC pThisCC, uint32_t idDXContext);
451int vmsvga3dDXSetPredication(PVGASTATECC pThisCC, uint32_t idDXContext);
452int vmsvga3dDXSetSOTargets(PVGASTATECC pThisCC, uint32_t idDXContext);
453int vmsvga3dDXSetViewports(PVGASTATECC pThisCC, uint32_t idDXContext, uint32_t cViewport, SVGA3dViewport const *paViewport);
454int vmsvga3dDXSetScissorRects(PVGASTATECC pThisCC, uint32_t idDXContext, uint32_t cRect, SVGASignedRect const *paRect);
455int vmsvga3dDXClearRenderTargetView(PVGASTATECC pThisCC, uint32_t idDXContext);
456int vmsvga3dDXClearDepthStencilView(PVGASTATECC pThisCC, uint32_t idDXContext);
457int vmsvga3dDXPredCopyRegion(PVGASTATECC pThisCC, uint32_t idDXContext);
458int vmsvga3dDXPredCopy(PVGASTATECC pThisCC, uint32_t idDXContext);
459int vmsvga3dDXPresentBlt(PVGASTATECC pThisCC, uint32_t idDXContext);
460int vmsvga3dDXGenMips(PVGASTATECC pThisCC, uint32_t idDXContext);
461int vmsvga3dDXUpdateSubResource(PVGASTATECC pThisCC, uint32_t idDXContext);
462int vmsvga3dDXReadbackSubResource(PVGASTATECC pThisCC, uint32_t idDXContext);
463int vmsvga3dDXInvalidateSubResource(PVGASTATECC pThisCC, uint32_t idDXContext);
464int vmsvga3dDXDefineShaderResourceView(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXDefineShaderResourceView const *pCmd);
465int vmsvga3dDXDestroyShaderResourceView(PVGASTATECC pThisCC, uint32_t idDXContext);
466int vmsvga3dDXDefineRenderTargetView(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXDefineRenderTargetView const *pCmd);
467int vmsvga3dDXDestroyRenderTargetView(PVGASTATECC pThisCC, uint32_t idDXContext);
468int vmsvga3dDXDefineDepthStencilView(PVGASTATECC pThisCC, uint32_t idDXContext);
469int vmsvga3dDXDestroyDepthStencilView(PVGASTATECC pThisCC, uint32_t idDXContext);
470int vmsvga3dDXDefineElementLayout(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dElementLayoutId elementLayoutId, uint32_t cDesc, SVGA3dInputElementDesc const *paDesc);
471int vmsvga3dDXDestroyElementLayout(PVGASTATECC pThisCC, uint32_t idDXContext);
472int vmsvga3dDXDefineBlendState(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXDefineBlendState const *pCmd);
473int vmsvga3dDXDestroyBlendState(PVGASTATECC pThisCC, uint32_t idDXContext);
474int vmsvga3dDXDefineDepthStencilState(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXDefineDepthStencilState const *pCmd);
475int vmsvga3dDXDestroyDepthStencilState(PVGASTATECC pThisCC, uint32_t idDXContext);
476int vmsvga3dDXDefineRasterizerState(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXDefineRasterizerState const *pCmd);
477int vmsvga3dDXDestroyRasterizerState(PVGASTATECC pThisCC, uint32_t idDXContext);
478int vmsvga3dDXDefineSamplerState(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXDefineSamplerState const *pCmd);
479int vmsvga3dDXDestroySamplerState(PVGASTATECC pThisCC, uint32_t idDXContext);
480int vmsvga3dDXDefineShader(PVGASTATECC pThisCC, uint32_t idDXContext, SVGA3dCmdDXDefineShader const *pCmd);
481int vmsvga3dDXDestroyShader(PVGASTATECC pThisCC, uint32_t idDXContext);
482int vmsvga3dDXBindShader(PVGASTATECC pThisCC, uint32_t cid, PVMSVGAMOB pMob, uint32_t shid, uint32_t offsetInBytes);
483int vmsvga3dDXDefineStreamOutput(PVGASTATECC pThisCC, uint32_t idDXContext);
484int vmsvga3dDXDestroyStreamOutput(PVGASTATECC pThisCC, uint32_t idDXContext);
485int vmsvga3dDXSetStreamOutput(PVGASTATECC pThisCC, uint32_t idDXContext);
486int vmsvga3dDXSetCOTable(PVGASTATECC pThisCC, uint32_t cid, PVMSVGAMOB pMob, SVGACOTableType type, uint32_t validSizeInBytes);
487int vmsvga3dDXReadbackCOTable(PVGASTATECC pThisCC, uint32_t idDXContext);
488int vmsvga3dDXBufferCopy(PVGASTATECC pThisCC, uint32_t idDXContext);
489int vmsvga3dDXTransferFromBuffer(PVGASTATECC pThisCC, uint32_t idDXContext);
490int vmsvga3dDXSurfaceCopyAndReadback(PVGASTATECC pThisCC, uint32_t idDXContext);
491int vmsvga3dDXMoveQuery(PVGASTATECC pThisCC, uint32_t idDXContext);
492int vmsvga3dDXBindAllQuery(PVGASTATECC pThisCC, uint32_t idDXContext);
493int vmsvga3dDXReadbackAllQuery(PVGASTATECC pThisCC, uint32_t idDXContext);
494int vmsvga3dDXPredTransferFromBuffer(PVGASTATECC pThisCC, uint32_t idDXContext);
495int vmsvga3dDXMobFence64(PVGASTATECC pThisCC, uint32_t idDXContext);
496int vmsvga3dDXBindAllShader(PVGASTATECC pThisCC, uint32_t idDXContext);
497int vmsvga3dDXHint(PVGASTATECC pThisCC, uint32_t idDXContext);
498int vmsvga3dDXBufferUpdate(PVGASTATECC pThisCC, uint32_t idDXContext);
499int vmsvga3dDXSetVSConstantBufferOffset(PVGASTATECC pThisCC, uint32_t idDXContext);
500int vmsvga3dDXSetPSConstantBufferOffset(PVGASTATECC pThisCC, uint32_t idDXContext);
501int vmsvga3dDXSetGSConstantBufferOffset(PVGASTATECC pThisCC, uint32_t idDXContext);
502int vmsvga3dDXSetHSConstantBufferOffset(PVGASTATECC pThisCC, uint32_t idDXContext);
503int vmsvga3dDXSetDSConstantBufferOffset(PVGASTATECC pThisCC, uint32_t idDXContext);
504int vmsvga3dDXSetCSConstantBufferOffset(PVGASTATECC pThisCC, uint32_t idDXContext);
505int vmsvga3dDXCondBindAllShader(PVGASTATECC pThisCC, uint32_t idDXContext);
506int vmsvga3dScreenCopy(PVGASTATECC pThisCC, uint32_t idDXContext);
507int vmsvga3dGrowOTable(PVGASTATECC pThisCC, uint32_t idDXContext);
508int vmsvga3dDXGrowCOTable(PVGASTATECC pThisCC, uint32_t idDXContext);
509int vmsvga3dIntraSurfaceCopy(PVGASTATECC pThisCC, uint32_t idDXContext);
510int vmsvga3dDefineGBSurface_v3(PVGASTATECC pThisCC, uint32_t idDXContext);
511int vmsvga3dDXResolveCopy(PVGASTATECC pThisCC, uint32_t idDXContext);
512int vmsvga3dDXPredResolveCopy(PVGASTATECC pThisCC, uint32_t idDXContext);
513int vmsvga3dDXPredConvertRegion(PVGASTATECC pThisCC, uint32_t idDXContext);
514int vmsvga3dDXPredConvert(PVGASTATECC pThisCC, uint32_t idDXContext);
515int vmsvga3dWholeSurfaceCopy(PVGASTATECC pThisCC, uint32_t idDXContext);
516int vmsvga3dDXDefineUAView(PVGASTATECC pThisCC, uint32_t idDXContext);
517int vmsvga3dDXDestroyUAView(PVGASTATECC pThisCC, uint32_t idDXContext);
518int vmsvga3dDXClearUAViewUint(PVGASTATECC pThisCC, uint32_t idDXContext);
519int vmsvga3dDXClearUAViewFloat(PVGASTATECC pThisCC, uint32_t idDXContext);
520int vmsvga3dDXCopyStructureCount(PVGASTATECC pThisCC, uint32_t idDXContext);
521int vmsvga3dDXSetUAViews(PVGASTATECC pThisCC, uint32_t idDXContext);
522int vmsvga3dDXDrawIndexedInstancedIndirect(PVGASTATECC pThisCC, uint32_t idDXContext);
523int vmsvga3dDXDrawInstancedIndirect(PVGASTATECC pThisCC, uint32_t idDXContext);
524int vmsvga3dDXDispatch(PVGASTATECC pThisCC, uint32_t idDXContext);
525int vmsvga3dDXDispatchIndirect(PVGASTATECC pThisCC, uint32_t idDXContext);
526int vmsvga3dWriteZeroSurface(PVGASTATECC pThisCC, uint32_t idDXContext);
527int vmsvga3dHintZeroSurface(PVGASTATECC pThisCC, uint32_t idDXContext);
528int vmsvga3dDXTransferToBuffer(PVGASTATECC pThisCC, uint32_t idDXContext);
529int vmsvga3dDXSetStructureCount(PVGASTATECC pThisCC, uint32_t idDXContext);
530int vmsvga3dLogicOpsBitBlt(PVGASTATECC pThisCC, uint32_t idDXContext);
531int vmsvga3dLogicOpsTransBlt(PVGASTATECC pThisCC, uint32_t idDXContext);
532int vmsvga3dLogicOpsStretchBlt(PVGASTATECC pThisCC, uint32_t idDXContext);
533int vmsvga3dLogicOpsColorFill(PVGASTATECC pThisCC, uint32_t idDXContext);
534int vmsvga3dLogicOpsAlphaBlend(PVGASTATECC pThisCC, uint32_t idDXContext);
535int vmsvga3dLogicOpsClearTypeBlend(PVGASTATECC pThisCC, uint32_t idDXContext);
536int vmsvga3dDefineGBSurface_v4(PVGASTATECC pThisCC, uint32_t idDXContext);
537int vmsvga3dDXSetCSUAViews(PVGASTATECC pThisCC, uint32_t idDXContext);
538int vmsvga3dDXSetMinLOD(PVGASTATECC pThisCC, uint32_t idDXContext);
539int vmsvga3dDXDefineDepthStencilView_v2(PVGASTATECC pThisCC, uint32_t idDXContext);
540int vmsvga3dDXDefineStreamOutputWithMob(PVGASTATECC pThisCC, uint32_t idDXContext);
541int vmsvga3dDXSetShaderIface(PVGASTATECC pThisCC, uint32_t idDXContext);
542int vmsvga3dDXBindStreamOutput(PVGASTATECC pThisCC, uint32_t idDXContext);
543int vmsvga3dSurfaceStretchBltNonMSToMS(PVGASTATECC pThisCC, uint32_t idDXContext);
544int vmsvga3dDXBindShaderIface(PVGASTATECC pThisCC, uint32_t idDXContext);
545#endif /* VMSVGA3D_DX */
546
547
548#endif /* !VBOX_INCLUDED_SRC_Graphics_DevVGA_SVGA3d_h */
549
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette