VBoxVideoWddm.h revision 7a3c0a6f8961fc1de551aaa9e3728d21f186af49
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync * Copyright (C) 2010 Oracle Corporation
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync * available from http://www.virtualbox.org. This file is free software;
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync * you can redistribute it and/or modify it under the terms of the GNU
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync * General Public License (GPL) as published by the Free Software
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync/* one page size */
1f277e5b999f572b1ef1fe4ef593c603ea463be3vboxsync#define VBOXWDDM_ROUNDBOUND(_v, _b) (((_v) + ((_b) - 1)) & ~((_b) - 1))
615105a2b89b7dd89a76504e6a9b8e099704c0d9vboxsynctypedef struct VBOXWDDM_ALLOCINFO_SHAREDPRIMARYSURFACE
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync} VBOXWDDM_ALLOCINFO_SHAREDPRIMARYSURFACE, *PVBOXWDDM_ALLOCINFO_SHAREDPRIMARYSURFACE;
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync/* allocation */
49207a1552ff3752904e36b9269f08fe643ba871vboxsync#define VBOXWDDM_ALLOCATION_HEADSIZE() (sizeof (VBOXWDDM_ALLOCATION))
49207a1552ff3752904e36b9269f08fe643ba871vboxsync#define VBOXWDDM_ALLOCATION_SIZE_FROMBODYSIZE(_s) (VBOXWDDM_ALLOCATION_HEADSIZE() + (_s))
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync#define VBOXWDDM_ALLOCATION_SIZE(_tCmd) (VBOXWDDM_ALLOCATION_SIZE_FROMBODYSIZE(sizeof(_tCmd)))
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync#define VBOXWDDM_ALLOCATION_BODY(_p, _t) ( (_t*)(((uint8_t*)(_p)) + VBOXWDDM_ALLOCATION_HEADSIZE()) )
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync#define VBOXWDDM_ALLOCATION_HEAD(_pb) ((VBOXWDDM_ALLOCATION*)((uint8_t *)(_pb) - VBOXWDDM_ALLOCATION_HEADSIZE()))
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsynctypedef struct VBOXWDDM_ALLOCATION_SHAREDPRIMARYSURFACE
83c86878d483df62ca8db465c671995984838338vboxsync// VBOXVIDEOOFFSET offAddress;
05c28d9d4557bed6e320dfee1acca69408bc3c15vboxsync} VBOXWDDM_ALLOCATION_SHAREDPRIMARYSURFACE, *PVBOXWDDM_ALLOCATION_SHAREDPRIMARYSURFACE;
1f277e5b999f572b1ef1fe4ef593c603ea463be3vboxsync// VBOXVIDEOOFFSET offAddress;
1f277e5b999f572b1ef1fe4ef593c603ea463be3vboxsync} VBOXWDDM_ALLOCATION_SHADOWSURFACE, *PVBOXWDDM_ALLOCATION_SHADOWSURFACE;
1f277e5b999f572b1ef1fe4ef593c603ea463be3vboxsynctypedef enum
1f277e5b999f572b1ef1fe4ef593c603ea463be3vboxsync struct _DEVICE_EXTENSION * pAdapter; /* Adapder info */
e120ca0501a41ca43369b7ba984f4db2f720bdc8vboxsync HANDLE hDevice; /* handle passed to CreateDevice */
e120ca0501a41ca43369b7ba984f4db2f720bdc8vboxsync VBOXWDDM_DEVICE_TYPE enmType; /* device creation flags passed to DxgkDdiCreateDevice, not sure we need it */
1f277e5b999f572b1ef1fe4ef593c603ea463be3vboxsynctypedef enum
4dee4a4f4ff664b16f478e200e0d231407a2b097vboxsync// uint8_t Reserved[8];
4dee4a4f4ff664b16f478e200e0d231407a2b097vboxsync}VBOXWDDM_DMA_PRIVATE_DATA, *PVBOXWDDM_DMA_PRIVATE_DATA;
4dee4a4f4ff664b16f478e200e0d231407a2b097vboxsync} VBOXWDDM_OPENALLOCATION, *PVBOXWDDM_OPENALLOCATION;
4dee4a4f4ff664b16f478e200e0d231407a2b097vboxsync#endif /* #ifndef ___VBoxVideoWddm_h___ */