VirtualBox

source: vbox/trunk/src/VBox/Additions/WINNT/Graphics/Display/wddm/VBoxDispD3DCmn.h@ 32281

Last change on this file since 32281 was 32281, checked in by vboxsync, 14 years ago

wddm/3d: basics for early d3d device creation (needed for win7), wine/d3d: stub for device settings update

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 3.4 KB
Line 
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 ___VBoxDispD3DCmn_h___
16#define ___VBoxDispD3DCmn_h___
17
18#include <windows.h>
19#include <d3d9types.h>
20//#include <d3dtypes.h>
21#include <D3dumddi.h>
22#include <d3dhal.h>
23
24#include <iprt/initterm.h>
25#include <iprt/log.h>
26#include <iprt/mem.h>
27
28#include <VBox/Log.h>
29
30#include <VBox/VBoxGuestLib.h>
31
32#include "VBoxDispD3DIf.h"
33#include "../../Miniport/wddm/VBoxVideoIf.h"
34#include "VBoxDispCm.h"
35#include "VBoxDispD3D.h"
36
37#ifdef DEBUG
38# define VBOXWDDMDISP_DEBUG
39# define VBOXWDDMDISP_DEBUG_FLOW
40# define VBOXWDDMDISP_DEBUG_DUMPSURFDATA
41#endif
42
43//#define VBOXDISP_EARLYCREATEDEVICE
44
45#if 0
46# ifdef Assert
47# undef Assert
48# define Assert(_a) do{}while(0)
49# endif
50# ifdef AssertBreakpoint
51# undef AssertBreakpoint
52# define AssertBreakpoint() do{}while(0)
53# endif
54# ifdef AssertFailed
55# undef AssertFailed
56# define AssertFailed() do{}while(0)
57# endif
58#endif
59
60#ifdef VBOXWDDMDISP_DEBUG
61extern bool g_VDbgTstDumpEnable;
62extern bool g_VDbgTstDumpOnSys2VidSameSizeEnable;
63
64VOID vboxVDbgDoDumpSurfData(const PVBOXWDDMDISP_DEVICE pDevice, const char * pPrefix, const PVBOXWDDMDISP_RESOURCE pRc, uint32_t iAlloc, const RECT *pRect, IDirect3DSurface9 *pSurf, const char* pSuffix);
65void vboxVDbgDoMpPrintRect(const PVBOXWDDMDISP_DEVICE pDevice, const char * pPrefix, const RECT *pRect, const char * pSuffix);
66void vboxVDbgDoMpPrintAlloc(const PVBOXWDDMDISP_DEVICE pDevice, const char * pPrefix, const PVBOXWDDMDISP_RESOURCE pRc, uint32_t iAlloc, const char * pSuffix);
67VOID vboxVDbgDoPrint(LPCSTR szString, ...);
68VOID vboxVDbgDoMpPrintF(const PVBOXWDDMDISP_DEVICE pDevice, LPCSTR szString, ...);
69void vboxVDbgVEHandlerRegister();
70void vboxVDbgVEHandlerUnregister();
71
72#define vboxVDbgBreak() AssertBreakpoint()
73#define vboxVDbgPrint(_m) \
74 do { \
75 vboxVDbgDoPrint _m ; \
76 } while (0)
77#define vboxVDbgPrintR vboxVDbgPrint
78#define vboxVDbgMpPrint(_m) \
79 do { \
80 vboxVDbgDoMpPrintF _m ; \
81 } while (0)
82#define vboxVDbgMpPrintRect(_m) \
83 do { \
84 vboxVDbgDoMpPrintRect _m ; \
85 } while (0)
86#define vboxVDbgMpPrintAlloc(_m) \
87 do { \
88 vboxVDbgDoMpPrintAlloc _m ; \
89 } while (0)
90#ifdef VBOXWDDMDISP_DEBUG_DUMPSURFDATA
91#define vboxVDbgDumpSurfData(_m) \
92 do { \
93 vboxVDbgDoDumpSurfData _m ; \
94 } while (0)
95#else
96#define vboxVDbgDumpSurfData(_m) do {} while (0)
97#endif
98#ifdef VBOXWDDMDISP_DEBUG_FLOW
99# define vboxVDbgPrintF vboxVDbgPrint
100#else
101# define vboxVDbgPrintF(_m) do {} while (0)
102#endif
103#else
104#define vboxVDbgMpPrint(_m) do {} while (0)
105#define vboxVDbgMpPrintRect(_m) do {} while (0)
106#define vboxVDbgMpPrintAlloc(_m) do {} while (0)
107#define vboxVDbgDumpSurfData(_m) do {} while (0)
108#define vboxVDbgBreak() do {} while (0)
109#define vboxVDbgPrint(_m) do {} while (0)
110#define vboxVDbgPrintR vboxVDbgPrint
111#define vboxVDbgPrintF vboxVDbgPrint
112#endif
113
114#endif /* #ifndef ___VBoxDispD3DCmn_h___ */
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