VirtualBox

Ignore:
Timestamp:
Dec 17, 2018 6:05:17 PM (6 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
127546
Message:

DevVGA-SVGA3d: dynamic loading of OpenGL: log failures

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Graphics/DevVGA-SVGA3d-ogl.cpp

    r76266 r76269  
    30323032        /* get an X display and make sure we have glX 1.3 */
    30333033        pState->display = XOpenDisplay(0);
    3034         Assert(pState->display);
     3034        AssertLogRelMsgReturn(pState->display, ("XOpenDisplay failed"), VERR_INTERNAL_ERROR);
    30353035        int glxMajor, glxMinor;
    30363036        Bool ret = glXQueryVersion(pState->display, &glxMajor, &glxMinor);
    3037         AssertMsgReturn(ret && glxMajor == 1 && glxMinor >= 3, ("glX >=1.3 not present"), VERR_INTERNAL_ERROR);
     3037        AssertLogRelMsgReturn(ret && glxMajor == 1 && glxMinor >= 3, ("glX >=1.3 not present"), VERR_INTERNAL_ERROR);
    30383038        /* start our X event handling thread */
    30393039        rc = RTThreadCreate(&pState->pWindowThread, vmsvga3dXEventThread, pState, 0, RTTHREADTYPE_GUI, RTTHREADFLAGS_WAITABLE, "VMSVGA3DXEVENT");
    3040         if (RT_FAILURE(rc))
    3041         {
    3042             AssertMsgFailed(("%s: Async IO Thread creation for 3d window handling failed rc=%d\n", __FUNCTION__, rc));
    3043             return rc;
    3044         }
    3045     }
    3046 
     3040        AssertLogRelMsgReturn(RT_SUCCESS(rc), ("Async IO Thread creation for 3d window handling failed rc=%Rrc\n", rc), rc);
     3041    }
     3042
     3043    Window defaultRootWindow = XDefaultRootWindow(pState->display);
    30473044    /* Create a small 4x4 window required for GL context. */
    30483045    int attrib[] =
     
    30573054    };
    30583055    XVisualInfo *vi = glXChooseVisual(pState->display, DefaultScreen(pState->display), attrib);
     3056    AssertLogRelMsgReturn(vi, ("glXChooseVisual failed"), VERR_INTERNAL_ERROR);
    30593057    XSetWindowAttributes swa;
    3060     swa.colormap = XCreateColormap(pState->display, XDefaultRootWindow(pState->display), vi->visual, AllocNone);
     3058    swa.colormap = XCreateColormap(pState->display, defaultRootWindow, vi->visual, AllocNone);
     3059    AssertLogRelMsgReturn(swa.colormap, ("XCreateColormap failed"), VERR_INTERNAL_ERROR);
    30613060    swa.border_pixel = 0;
    30623061    swa.background_pixel = 0;
    30633062    swa.event_mask = StructureNotifyMask;
    30643063    unsigned long flags = CWBorderPixel | CWBackPixel | CWColormap | CWEventMask;
    3065     pContext->window = XCreateWindow(pState->display, XDefaultRootWindow(pState->display),
     3064    pContext->window = XCreateWindow(pState->display, defaultRootWindow,
    30663065                                     0, 0, 4, 4,
    30673066                                     0, vi->depth, InputOutput,
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