VirtualBox

Changeset 76376 in vbox for trunk/src/VBox/Additions/WINNT


Ignore:
Timestamp:
Dec 22, 2018 10:32:24 PM (6 years ago)
Author:
vboxsync
Message:

VBoxUhgsmi.h: GCC doesn't like unnamed sub-structures in C++ code, so ditched them for VBOXUHGSMI_BUFFER_TYPE_FLAGS, VBOXUHGSMI_BUFFER_LOCK_FLAGS and VBOXUHGSMI_BUFFER_SUBMIT_FLAGS. Also skipped the outer wrapper structures for each of these types as all it contained was an unnamed union, so just make the typedefs unions straight away. Fixed some hungarian inconsistency between the three types ('b' == byte, not boolean in VBox, don't forget).

Location:
trunk/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm/VBoxUhgsmiBase.cpp

    r73097 r76376  
    4848    *phSynch = NULL;
    4949
    50     if (fUhgsmiType.fCommand)
     50    if (fUhgsmiType.s.fCommand)
    5151    {
    5252        *phSynch = CreateEvent(
     
    186186        PVBOXUHGSMI_BUFFER_PRIVATE_ESC_BASE pBuf = VBOXUHGSMIESCBASE_GET_BUFFER(pBufInfo->pBuf);
    187187        pSubmInfo->hAlloc = pBuf->Alloc.hAlloc;
    188         if (pBufInfo->fFlags.bEntireBuffer)
     188        if (pBufInfo->fFlags.s.fEntireBuffer)
    189189        {
    190190            pSubmInfo->Info.offData = 0;
  • trunk/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm/VBoxUhgsmiBase.h

    r73097 r76376  
    9494    D3DDDICB_LOCKFLAGS fLockFlags;
    9595    fLockFlags.Value = 0;
    96     if (fFlags.bLockEntire)
     96    if (fFlags.s.fLockEntire)
    9797    {
    9898        Assert(!offLock);
     
    126126    }
    127127
    128     fLockFlags.ReadOnly = fFlags.bReadOnly;
    129     fLockFlags.WriteOnly = fFlags.bWriteOnly;
    130     fLockFlags.DonotWait = fFlags.bDonotWait;
    131 //    fLockFlags.Discard = fFlags.bDiscard;
     128    fLockFlags.ReadOnly  = fFlags.s.fReadOnly;
     129    fLockFlags.WriteOnly = fFlags.s.fWriteOnly;
     130    fLockFlags.DonotWait = fFlags.s.fDonotWait;
     131//    fLockFlags.Discard = fFlags.s.fDiscard;
    132132    *pfFlags = fLockFlags;
    133133    return VINF_SUCCESS;
     
    173173        pAllocationList->hAllocation = pBuffer->hAllocation;
    174174        pAllocationList->Value = 0;
    175         pAllocationList->WriteOperation = !pBufInfo->fFlags.bHostReadOnly;
    176         pAllocationList->DoNotRetireInstance = pBufInfo->fFlags.bDoNotRetire;
    177         if (pBufInfo->fFlags.bEntireBuffer)
     175        pAllocationList->WriteOperation = !pBufInfo->fFlags.s.fHostReadOnly;
     176        pAllocationList->DoNotRetireInstance = pBufInfo->fFlags.s.fDoNotRetire;
     177        if (pBufInfo->fFlags.s.fEntireBuffer)
    178178        {
    179179            pBufSubmInfo->offData = 0;
  • trunk/src/VBox/Additions/WINNT/Graphics/Video/disp/wddm/VBoxUhgsmiKmt.cpp

    r75445 r76376  
    5454}
    5555
    56 DECLCALLBACK(int) vboxUhgsmiKmtBufferLock(PVBOXUHGSMI_BUFFER pBuf, uint32_t offLock, uint32_t cbLock, VBOXUHGSMI_BUFFER_LOCK_FLAGS fFlags, void**pvLock)
     56DECLCALLBACK(int) vboxUhgsmiKmtBufferLock(PVBOXUHGSMI_BUFFER pBuf, uint32_t offLock, uint32_t cbLock,
     57                                          VBOXUHGSMI_BUFFER_LOCK_FLAGS fFlags, void**pvLock)
    5758{
    5859    PVBOXUHGSMI_BUFFER_PRIVATE_DX_ALLOC_BASE pBuffer = VBOXUHGSMDXALLOCBASE_GET_BUFFER(pBuf);
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette