VirtualBox

Ignore:
Timestamp:
Aug 8, 2014 6:34:02 PM (11 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
95454
Message:

wddm/crOpenGL: prevent shared objects from being deleted till they can be used

Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/src/VBox

  • trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_misc.c

    r51559 r52329  
    1111#include "cr_string.h"
    1212#include "cr_pixeldata.h"
     13#ifdef VBOX_WITH_CRDUMPER
     14# include "cr_dump.h"
     15#endif
    1316
    1417void SERVER_DISPATCH_APIENTRY crServerDispatchSelectBuffer( GLsizei size, GLuint *buffer )
     
    311314    case GL_RCUSAGE_TEXTURE_CLEAR_CR:
    312315        crStateSetTextureUsed(value, GL_FALSE);
     316        break;
     317    case GL_PIN_TEXTURE_SET_CR:
     318        crStatePinTexture(value, GL_TRUE);
     319        break;
     320    case GL_PIN_TEXTURE_CLEAR_CR:
     321        crStatePinTexture(value, GL_FALSE);
    313322        break;
    314323    case GL_SHARED_DISPLAY_LISTS_CR:
     
    14861495#ifdef VBOX_WITH_CRSERVER_DUMPER
    14871496
     1497# ifndef VBOX_WITH_CRDUMPER
     1498#  error "VBOX_WITH_CRDUMPER undefined!"
     1499# endif
     1500
    14881501/* first four bits are buffer dump config
    14891502 * second four bits are texture dump config
  • trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_presenter.cpp

    r51975 r52329  
    10471047    if (pTobj)
    10481048    {
    1049         CR_STATE_SHAREDOBJ_USAGE_CLEAR(pTobj, cr_server.MainContextInfo.pContext);
    1050 
    10511049        crHashtableDelete(g_CrPresenter.pFbTexMap, pTobj->id, NULL);
    10521050
    1053         if (!CR_STATE_SHAREDOBJ_USAGE_IS_USED(pTobj))
    1054         {
    1055             CRSharedState *pShared = crStateGlobalSharedAcquire();
    1056 
    1057             CRASSERT(pShared);
    1058             /* on the host side, we need to delete an ogl texture object here as well, which crStateDeleteTextureCallback will do
    1059              * in addition to calling crStateDeleteTextureObject to delete a state object */
    1060             crHashtableDelete(pShared->textureTable, pTobj->id, crStateDeleteTextureCallback);
    1061 
    1062             crStateGlobalSharedRelease();
    1063         }
     1051        crStateReleaseTexture(cr_server.MainContextInfo.pContext, pTobj);
     1052
    10641053
    10651054        crStateGlobalSharedRelease();
Note: See TracChangeset for help on using the changeset viewer.

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