1 | /* $Id: VBoxMPCm.h 76540 2018-12-30 06:26:37Z vboxsync $ */
|
---|
2 | /** @file
|
---|
3 | * VBox WDDM Miniport driver
|
---|
4 | */
|
---|
5 |
|
---|
6 | /*
|
---|
7 | * Copyright (C) 2011-2017 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 ___VBoxMPCm_h___
|
---|
19 | #define ___VBoxMPCm_h___
|
---|
20 | #ifndef RT_WITHOUT_PRAGMA_ONCE
|
---|
21 | # pragma once
|
---|
22 | #endif
|
---|
23 |
|
---|
24 | typedef struct VBOXVIDEOCM_MGR
|
---|
25 | {
|
---|
26 | KSPIN_LOCK SynchLock;
|
---|
27 | /* session list */
|
---|
28 | LIST_ENTRY SessionList;
|
---|
29 | } VBOXVIDEOCM_MGR, *PVBOXVIDEOCM_MGR;
|
---|
30 |
|
---|
31 | typedef struct VBOXVIDEOCM_CTX
|
---|
32 | {
|
---|
33 | LIST_ENTRY SessionEntry;
|
---|
34 | struct VBOXVIDEOCM_SESSION *pSession;
|
---|
35 | uint64_t u64UmData;
|
---|
36 | VBOXWDDM_HTABLE AllocTable;
|
---|
37 | } VBOXVIDEOCM_CTX, *PVBOXVIDEOCM_CTX;
|
---|
38 |
|
---|
39 | void vboxVideoCmCtxInitEmpty(PVBOXVIDEOCM_CTX pContext);
|
---|
40 |
|
---|
41 | NTSTATUS vboxVideoCmCtxAdd(PVBOXVIDEOCM_MGR pMgr, PVBOXVIDEOCM_CTX pContext, HANDLE hUmEvent, uint64_t u64UmData);
|
---|
42 | NTSTATUS vboxVideoCmCtxRemove(PVBOXVIDEOCM_MGR pMgr, PVBOXVIDEOCM_CTX pContext);
|
---|
43 | NTSTATUS vboxVideoCmInit(PVBOXVIDEOCM_MGR pMgr);
|
---|
44 | NTSTATUS vboxVideoCmTerm(PVBOXVIDEOCM_MGR pMgr);
|
---|
45 | NTSTATUS vboxVideoCmSignalEvents(PVBOXVIDEOCM_MGR pMgr);
|
---|
46 |
|
---|
47 | NTSTATUS vboxVideoCmCmdSubmitCompleteEvent(PVBOXVIDEOCM_CTX pContext, PKEVENT pEvent);
|
---|
48 | void* vboxVideoCmCmdCreate(PVBOXVIDEOCM_CTX pContext, uint32_t cbSize);
|
---|
49 | void* vboxVideoCmCmdReinitForContext(void *pvCmd, PVBOXVIDEOCM_CTX pContext);
|
---|
50 | void vboxVideoCmCmdRetain(void *pvCmd);
|
---|
51 | void vboxVideoCmCmdRelease(void *pvCmd);
|
---|
52 | #define VBOXVIDEOCM_SUBMITSIZE_DEFAULT (~0UL)
|
---|
53 | void vboxVideoCmCmdSubmit(void *pvCmd, uint32_t cbSize);
|
---|
54 |
|
---|
55 | #define VBOXVIDEOCMCMDVISITOR_RETURN_BREAK 0x00000001
|
---|
56 | #define VBOXVIDEOCMCMDVISITOR_RETURN_RMCMD 0x00000002
|
---|
57 | typedef DECLCALLBACK(UINT) FNVBOXVIDEOCMCMDVISITOR(PVBOXVIDEOCM_CTX pContext, PVOID pvCmd, uint32_t cbCmd, PVOID pvVisitor);
|
---|
58 | typedef FNVBOXVIDEOCMCMDVISITOR *PFNVBOXVIDEOCMCMDVISITOR;
|
---|
59 | NTSTATUS vboxVideoCmCmdVisit(PVBOXVIDEOCM_CTX pContext, BOOLEAN bEntireSession, PFNVBOXVIDEOCMCMDVISITOR pfnVisitor, PVOID pvVisitor);
|
---|
60 |
|
---|
61 | NTSTATUS vboxVideoCmEscape(PVBOXVIDEOCM_CTX pContext, PVBOXDISPIFESCAPE_GETVBOXVIDEOCMCMD pCmd, uint32_t cbCmd);
|
---|
62 |
|
---|
63 | #endif /* #ifndef ___VBoxMPCm_h___ */
|
---|