1 | /*
|
---|
2 | * Copyright (C) 2010 Oracle Corporation
|
---|
3 | *
|
---|
4 | * This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
5 | * available from http://www.virtualbox.org. This file is free software;
|
---|
6 | * you can redistribute it and/or modify it under the terms of the GNU
|
---|
7 | * General Public License (GPL) as published by the Free Software
|
---|
8 | * Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
9 | * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
10 | * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
11 | */
|
---|
12 | #ifndef ___VBoxVideoVbva_h___
|
---|
13 | #define ___VBoxVideoVbva_h___
|
---|
14 |
|
---|
15 | typedef struct VBOXVBVAINFO
|
---|
16 | {
|
---|
17 | VBOXVIDEOOFFSET offVBVA;
|
---|
18 | uint32_t cbVBVA;
|
---|
19 | VBVABUFFER *pVBVA;
|
---|
20 | BOOL fHwBufferOverflow;
|
---|
21 | VBVARECORD *pRecord;
|
---|
22 | D3DDDI_VIDEO_PRESENT_SOURCE_ID srcId;
|
---|
23 | } VBOXVBVAINFO;
|
---|
24 |
|
---|
25 | int vboxVbvaEnable (struct _DEVICE_EXTENSION* pDevExt, VBOXVBVAINFO *pVbva);
|
---|
26 | int vboxVbvaDisable (struct _DEVICE_EXTENSION* pDevExt, VBOXVBVAINFO *pVbva);
|
---|
27 | int vboxVbvaCreate(struct _DEVICE_EXTENSION* pDevExt, VBOXVBVAINFO *pVbva, ULONG offBuffer, ULONG cbBuffer, D3DDDI_VIDEO_PRESENT_SOURCE_ID srcId);
|
---|
28 | int vboxVbvaReportCmdOffset (struct _DEVICE_EXTENSION* pDevExt, VBOXVBVAINFO *pVbva, uint32_t offCmd);
|
---|
29 | int vboxVbvaReportDirtyRect (struct _DEVICE_EXTENSION* pDevExt, VBOXVBVAINFO *pVbva, RECT *pRectOrig);
|
---|
30 | BOOL vboxVbvaBufferBeginUpdate (struct _DEVICE_EXTENSION* pDevExt, VBOXVBVAINFO *pVbva);
|
---|
31 | void vboxVbvaBufferEndUpdate (struct _DEVICE_EXTENSION* pDevExt, VBOXVBVAINFO *pVbva);
|
---|
32 |
|
---|
33 | #define VBOXVBVA_OP(_op, _pdext, _pvbva, _arg) \
|
---|
34 | if (vboxVbvaBufferBeginUpdate(_pdext, _pvbva)) \
|
---|
35 | { \
|
---|
36 | vboxVbva##_op(_pdext, _pvbva, _arg); \
|
---|
37 | vboxVbvaBufferEndUpdate(_pdext, _pvbva); \
|
---|
38 | }
|
---|
39 |
|
---|
40 | #endif /* #ifndef ___VBoxVideoVbva_h___ */
|
---|