1 | /** @file
|
---|
2 | *
|
---|
3 | * VBoxVideo Display D3D User mode dll
|
---|
4 | *
|
---|
5 | * Copyright (C) 2010 Oracle Corporation
|
---|
6 | *
|
---|
7 | * This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
8 | * available from http://www.virtualbox.org. This file is free software;
|
---|
9 | * you can redistribute it and/or modify it under the terms of the GNU
|
---|
10 | * General Public License (GPL) as published by the Free Software
|
---|
11 | * Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
12 | * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
13 | * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
14 | */
|
---|
15 | #ifndef ___VBoxDispD3DIf_h___
|
---|
16 | #define ___VBoxDispD3DIf_h___
|
---|
17 |
|
---|
18 | /* D3D headers */
|
---|
19 | #include <iprt/critsect.h>
|
---|
20 | #include <iprt/semaphore.h>
|
---|
21 |
|
---|
22 | #include <D3D9.h>
|
---|
23 |
|
---|
24 | /* D3D functionality the VBOXDISPD3D provides */
|
---|
25 | typedef HRESULT WINAPI FNVBOXDISPD3DCREATE9EX(UINT SDKVersion, IDirect3D9Ex **ppD3D);
|
---|
26 | typedef FNVBOXDISPD3DCREATE9EX *PFNVBOXDISPD3DCREATE9EX;
|
---|
27 |
|
---|
28 | typedef struct VBOXDISPD3D
|
---|
29 | {
|
---|
30 | /* D3D functionality the VBOXDISPD3D provides */
|
---|
31 | PFNVBOXDISPD3DCREATE9EX pfnDirect3DCreate9Ex;
|
---|
32 |
|
---|
33 | /* module handle */
|
---|
34 | HMODULE hD3DLib;
|
---|
35 | } VBOXDISPD3D;
|
---|
36 |
|
---|
37 | HRESULT VBoxDispD3DOpen(VBOXDISPD3D *pD3D);
|
---|
38 | void VBoxDispD3DClose(VBOXDISPD3D *pD3D);
|
---|
39 |
|
---|
40 |
|
---|
41 | typedef struct VBOXDISPWORKER
|
---|
42 | {
|
---|
43 | RTCRITSECT CritSect;
|
---|
44 |
|
---|
45 | RTSEMEVENT hEvent;
|
---|
46 |
|
---|
47 | HANDLE hThread;
|
---|
48 | DWORD idThread;
|
---|
49 | } VBOXDISPWORKER;
|
---|
50 |
|
---|
51 | HRESULT VBoxDispWorkerCreate(VBOXDISPWORKER *pWorker);
|
---|
52 | HRESULT VBoxDispWorkerDestroy(VBOXDISPWORKER *pWorker);
|
---|
53 |
|
---|
54 | typedef DECLCALLBACK(void) FNVBOXDISPWORKERCB(void *pvUser);
|
---|
55 | typedef FNVBOXDISPWORKERCB *PFNVBOXDISPWORKERCB;
|
---|
56 |
|
---|
57 | HRESULT VBoxDispWorkerSubmitProc(VBOXDISPWORKER *pWorker, PFNVBOXDISPWORKERCB pfnCb, void *pvCb);
|
---|
58 |
|
---|
59 | typedef struct VBOXWDDMDISP_ADAPTER *PVBOXWDDMDISP_ADAPTER;
|
---|
60 |
|
---|
61 | HRESULT VBoxDispWndDestroy(PVBOXWDDMDISP_ADAPTER pAdapter, HWND hWnd);
|
---|
62 | HRESULT VBoxDispWndCreate(PVBOXWDDMDISP_ADAPTER pAdapter, DWORD width, DWORD height, HWND *phWnd);
|
---|
63 |
|
---|
64 | #endif /* ifndef ___VBoxDispD3DIf_h___ */
|
---|