VirtualBox

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


Ignore:
Timestamp:
Apr 8, 2013 1:00:36 PM (12 years ago)
Author:
vboxsync
Message:

wddm/3d: cmd API only 3D contexts

Location:
trunk/src/VBox/Additions/WINNT/Graphics/Video
Files:
2 edited

Legend:

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

    r44529 r45403  
    207207
    208208    pCmd->EscapeHdr.escapeCode = VBOXESC_GETVBOXVIDEOCMCMD;
     209
     210    PVBOXWDDMDISP_CONTEXT pContext = NULL, pCurCtx;
     211
    209212    /* lock to ensure the context is not destroyed */
    210213    EnterCriticalSection(&pSession->CritSect);
    211214    /* use any context for identifying the kernel CmSession. We're using the first one */
    212     PVBOXWDDMDISP_CONTEXT pContext = RTListGetFirst(&pSession->CtxList, VBOXWDDMDISP_CONTEXT, ListNode);
     215    RTListForEach(&pSession->CtxList, pCurCtx, VBOXWDDMDISP_CONTEXT, ListNode)
     216    {
     217        PVBOXWDDMDISP_DEVICE pDevice = pCurCtx->pDevice;
     218        if (VBOXDISPMODE_IS_3D(pDevice->pAdapter))
     219        {
     220            pContext = pCurCtx;
     221            break;
     222        }
     223    }
    213224    if (pContext)
    214225    {
  • trunk/src/VBox/Additions/WINNT/Graphics/Video/mp/wddm/VBoxMPWddm.cpp

    r45132 r45403  
    40244024                if (pEscape->PrivateDriverDataSize >= sizeof (VBOXDISPIFESCAPE_GETVBOXVIDEOCMCMD))
    40254025                {
    4026                     Status = vboxVideoCmEscape(&pContext->CmContext, pRegions, pEscape->PrivateDriverDataSize);
    4027                     Assert(Status == STATUS_SUCCESS);
     4026                    if (pContext->enmType == VBOXWDDM_CONTEXT_TYPE_CUSTOM_3D)
     4027                    {
     4028                        Status = vboxVideoCmEscape(&pContext->CmContext, pRegions, pEscape->PrivateDriverDataSize);
     4029                        Assert(Status == STATUS_SUCCESS);
     4030                    }
     4031                    else
     4032                    {
     4033                        WARN(("VBOXESC_GETVBOXVIDEOCMCMD recieved invalid context type %d", pContext->enmType));
     4034                        Status = STATUS_INVALID_PARAMETER;
     4035                    }
    40284036                }
    40294037                else
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