1 | /* $Id: VBoxDispMp.h 36867 2011-04-28 07:27:03Z vboxsync $ */
|
---|
2 |
|
---|
3 | /** @file
|
---|
4 | * VBoxVideo Display D3D User mode dll
|
---|
5 | */
|
---|
6 |
|
---|
7 | /*
|
---|
8 | * Copyright (C) 2011 Oracle Corporation
|
---|
9 | *
|
---|
10 | * This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
11 | * available from http://www.virtualbox.org. This file is free software;
|
---|
12 | * you can redistribute it and/or modify it under the terms of the GNU
|
---|
13 | * General Public License (GPL) as published by the Free Software
|
---|
14 | * Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
15 | * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
16 | * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
17 | */
|
---|
18 |
|
---|
19 | #ifndef ___VBoxDispMp_h___
|
---|
20 | #define ___VBoxDispMp_h___
|
---|
21 |
|
---|
22 | #include <windows.h>
|
---|
23 | #include <d3d9types.h>
|
---|
24 | #include <D3dumddi.h>
|
---|
25 | #include <d3dhal.h>
|
---|
26 | #include "../../common/wddm/VBoxMPIf.h"
|
---|
27 |
|
---|
28 | typedef struct VBOXDISPMP_REGIONS
|
---|
29 | {
|
---|
30 | HWND hWnd;
|
---|
31 | PVBOXVIDEOCM_CMD_RECTS pRegions;
|
---|
32 | } VBOXDISPMP_REGIONS, *PVBOXDISPMP_REGIONS;
|
---|
33 |
|
---|
34 | typedef DECLCALLBACK(HRESULT) FNVBOXDISPMP_ENABLEEVENTS();
|
---|
35 | typedef FNVBOXDISPMP_ENABLEEVENTS *PFNVBOXDISPMP_ENABLEEVENTS;
|
---|
36 |
|
---|
37 | typedef DECLCALLBACK(HRESULT) FNVBOXDISPMP_DISABLEEVENTS();
|
---|
38 | typedef FNVBOXDISPMP_DISABLEEVENTS *PFNVBOXDISPMP_DISABLEEVENTS;
|
---|
39 |
|
---|
40 | typedef DECLCALLBACK(HRESULT) FNVBOXDISPMP_DISABLEEVENTS();
|
---|
41 | typedef FNVBOXDISPMP_DISABLEEVENTS *PFNVBOXDISPMP_DISABLEEVENTS;
|
---|
42 |
|
---|
43 | typedef DECLCALLBACK(HRESULT) FNVBOXDISPMP_GETREGIONS(PVBOXDISPMP_REGIONS pRegions, DWORD dwMilliseconds);
|
---|
44 | typedef FNVBOXDISPMP_GETREGIONS *PFNVBOXDISPMP_GETREGIONS;
|
---|
45 |
|
---|
46 | typedef DECLCALLBACK(void) FNVBOXDISPMP_LOG(LPCSTR pszMsg);
|
---|
47 | typedef FNVBOXDISPMP_LOG *PFNVBOXDISPMP_LOG;
|
---|
48 |
|
---|
49 |
|
---|
50 | typedef struct VBOXDISPMP_CALLBACKS
|
---|
51 | {
|
---|
52 | PFNVBOXDISPMP_ENABLEEVENTS pfnEnableEvents;
|
---|
53 | PFNVBOXDISPMP_DISABLEEVENTS pfnDisableEvents;
|
---|
54 | /**
|
---|
55 | * if events are enabled - blocks until dirty region is available or timeout occurs
|
---|
56 | * in the former case S_OK is returned on event, in the latter case WAIT_TIMEOUT is returned
|
---|
57 | * if events are disabled - returns S_FALSE
|
---|
58 | */
|
---|
59 | PFNVBOXDISPMP_GETREGIONS pfnGetRegions;
|
---|
60 |
|
---|
61 | PFNVBOXDISPMP_LOG pfnLog;
|
---|
62 | } VBOXDISPMP_CALLBACKS, *PVBOXDISPMP_CALLBACKS;
|
---|
63 |
|
---|
64 | /** @def VBOXNETCFGWIN_DECL
|
---|
65 | * The usual declaration wrapper.
|
---|
66 | */
|
---|
67 |
|
---|
68 | /* enable this in case we include this in a dll*/
|
---|
69 | # ifdef VBOXWDDMDISP
|
---|
70 | # define VBOXDISPMP_DECL(_type) DECLEXPORT(_type)
|
---|
71 | # else
|
---|
72 | # define VBOXDISPMP_DECL(_type) DECLIMPORT(_type)
|
---|
73 | # endif
|
---|
74 |
|
---|
75 | #define VBOXDISPMP_IFVERSION 2
|
---|
76 | #define VBOXDISPMP_VERSION (VBOXVIDEOIF_VERSION | (VBOXDISPMP_IFVERSION < 16))
|
---|
77 | /**
|
---|
78 | * VBoxDispMpGetCallbacks export
|
---|
79 | *
|
---|
80 | * @param u32Version - must be set to VBOXDISPMP_VERSION
|
---|
81 | * @param pCallbacks - callbacks structure
|
---|
82 | */
|
---|
83 | typedef VBOXDISPMP_DECL(HRESULT) FNVBOXDISPMP_GETCALLBACKS(uint32_t u32Version, PVBOXDISPMP_CALLBACKS pCallbacks);
|
---|
84 | typedef FNVBOXDISPMP_GETCALLBACKS *PFNVBOXDISPMP_GETCALLBACKS;
|
---|
85 |
|
---|
86 | #endif /* #ifndef ___VBoxDispMp_h___ */
|
---|