VirtualBox

Changeset 3858 in vbox for trunk/src


Ignore:
Timestamp:
Jul 26, 2007 8:33:24 AM (17 years ago)
Author:
vboxsync
Message:

OpenGL update by Alexander Eichner

Location:
trunk/src/VBox/HostServices/SharedOpenGL
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostServices/SharedOpenGL/gldrv.h

    r3708 r3858  
    2828#define VBOX_OGL_DEBUG_WINDOW_OUTPUT
    2929#elif defined(RT_OS_LINUX)
     30
     31#define GLX_GLXEXT_PROTOTYPES
    3032#include <X11/Xlib.h>
     33#include <GL/gl.h>
    3134#include <GL/glx.h>
    3235#include <GL/glxext.h>
    33  
    34 typedef GLXContextID (*glXGetContextIDEXTProc) (const GLXContext);
    35 typedef GLXContext (*glXImportContextEXTProc) (Display *, GLXContextID);
    3636 
    3737#define VBOX_OGL_DEBUG_WINDOW_OUTPUT
     
    8787    PFNGLXGETVISUALFROMFBCONFIGSGIXPROC glxGetVisualFromFBConfig;
    8888    PFNGLXCREATECONTEXTWITHCONFIGSGIXPROC glxCreateNewContext;
    89     //glXGetContextIDEXTProc getContextIDPtr;
    90     //glXImportContextEXTProc importContextEXTPtr;
    9189#endif
    9290#endif
  • trunk/src/VBox/HostServices/SharedOpenGL/gllindrv.cpp

    r3766 r3858  
    2424 *
    2525 */
     26#define GLX_GLXEXT_PROTOTYPES
    2627
    2728#include "vboxgl.h"
     
    3031#include <string.h>
    3132#include <stdio.h>
    32 
    33 /*static int (*X_handler)(Display *, XErrorEvent *) = NULL;
    34 static int x_errhandler(Display *d, XErrorEvent *e)
    35 {
    36     return (X_handler(d, e));
    37 }
    38 
    39 static int (*XIO_handler)(Display *) = NULL;
    40 static int xio_errhandler(Display *d)
    41 {
    42     return (XIO_handler(d));
    43 }*/
     33#include <GL/gl.h>
     34#include <GL/glx.h>
     35#include <GL/glxext.h>
     36
    4437
    4538/* X11 server connection for all OpenGL clients.
     
    8174}
    8275
    83 
    8476/**
    85  * Print parameters for a GLXFBConfig to stdout.
    86  * Input:  dpy - the X display
    87  *         screen - the X screen number
    88  *         fbConfig - the fbconfig handle
    89  *         horizFormat - if true, print in horizontal format
    90  */
    91 void
    92 PrintFBConfigInfo(Display *dpy, int screen, GLXFBConfig config)
    93 {
    94    int bufferSize, level, doubleBuffer, stereo, auxBuffers;
    95    int redSize, greenSize, blueSize, alphaSize;
    96    int depthSize, stencilSize;
    97    int accumRedSize, accumBlueSize, accumGreenSize, accumAlphaSize;
    98 //   int sampleBuffers, samples;
    99    int drawableType, renderType, xRenderable, xVisual, id;
    100 
    101    /* do queries using the GLX 1.3 tokens (same as the SGIX tokens) */
    102    glXGetFBConfigAttrib(dpy, config, GLX_BUFFER_SIZE, &bufferSize);
    103    glXGetFBConfigAttrib(dpy, config, GLX_LEVEL, &level);
    104    glXGetFBConfigAttrib(dpy, config, GLX_DOUBLEBUFFER, &doubleBuffer);
    105    glXGetFBConfigAttrib(dpy, config, GLX_STEREO, &stereo);
    106    glXGetFBConfigAttrib(dpy, config, GLX_AUX_BUFFERS, &auxBuffers);
    107    glXGetFBConfigAttrib(dpy, config, GLX_RED_SIZE, &redSize);
    108    glXGetFBConfigAttrib(dpy, config, GLX_GREEN_SIZE, &greenSize);
    109    glXGetFBConfigAttrib(dpy, config, GLX_BLUE_SIZE, &blueSize);
    110    glXGetFBConfigAttrib(dpy, config, GLX_ALPHA_SIZE, &alphaSize);
    111    glXGetFBConfigAttrib(dpy, config, GLX_DEPTH_SIZE, &depthSize);
    112    glXGetFBConfigAttrib(dpy, config, GLX_STENCIL_SIZE, &stencilSize);
    113    glXGetFBConfigAttrib(dpy, config, GLX_ACCUM_RED_SIZE, &accumRedSize);
    114    glXGetFBConfigAttrib(dpy, config, GLX_ACCUM_GREEN_SIZE, &accumGreenSize);
    115    glXGetFBConfigAttrib(dpy, config, GLX_ACCUM_BLUE_SIZE, &accumBlueSize);
    116    glXGetFBConfigAttrib(dpy, config, GLX_ACCUM_ALPHA_SIZE, &accumAlphaSize);
    117 //   glXGetFBConfigAttrib(dpy, config, GLX_SAMPLE_BUFFERS, &sampleBuffers);
    118 //   glXGetFBConfigAttrib(dpy, config, GLX_SAMPLES, &samples);
    119    glXGetFBConfigAttrib(dpy, config, GLX_DRAWABLE_TYPE, &drawableType);
    120    glXGetFBConfigAttrib(dpy, config, GLX_RENDER_TYPE, &renderType);
    121    glXGetFBConfigAttrib(dpy, config, GLX_X_RENDERABLE, &xRenderable);
    122    glXGetFBConfigAttrib(dpy, config, GLX_X_VISUAL_TYPE, &xVisual);
    123    if (!xRenderable || !(drawableType & GLX_WINDOW_BIT_SGIX))
    124       xVisual = -1;
    125 
    126    glXGetFBConfigAttrib(dpy, config, GLX_FBCONFIG_ID, &id);
    127 
    128       printf("Id 0x%x\n", id);
    129       printf("  Buffer Size: %d\n", bufferSize);
    130       printf("  Level: %d\n", level);
    131       printf("  Double Buffer: %s\n", doubleBuffer ? "yes" : "no");
    132       printf("  Stereo: %s\n", stereo ? "yes" : "no");
    133       printf("  Aux Buffers: %d\n", auxBuffers);
    134       printf("  Red Size: %d\n", redSize);
    135       printf("  Green Size: %d\n", greenSize);
    136       printf("  Blue Size: %d\n", blueSize);
    137       printf("  Alpha Size: %d\n", alphaSize);
    138       printf("  Depth Size: %d\n", depthSize);
    139       printf("  Stencil Size: %d\n", stencilSize);
    140       printf("  Accum Red Size: %d\n", accumRedSize);
    141       printf("  Accum Green Size: %d\n", accumGreenSize);
    142       printf("  Accum Blue Size: %d\n", accumBlueSize);
    143       printf("  Accum Alpha Size: %d\n", accumAlphaSize);
    144 //      printf("  Sample Buffers: %d\n", sampleBuffers);
    145 //      printf("  Samples/Pixel: %d\n", samples);
    146       printf("  Drawable Types: ");
    147       if (drawableType & GLX_WINDOW_BIT)  printf("Window ");
    148       if (drawableType & GLX_PIXMAP_BIT)  printf("Pixmap ");
    149       if (drawableType & GLX_PBUFFER_BIT)  printf("PBuffer");
    150       printf("\n");
    151       printf("  Render Types: ");
    152       if (renderType & GLX_RGBA_BIT_SGIX)  printf("RGBA ");
    153       if (renderType & GLX_COLOR_INDEX_BIT_SGIX)  printf("CI ");
    154       printf("\n");
    155       printf("  X Renderable: %s\n", xRenderable ? "yes" : "no");
    156 
    157 }
    158 
    159 /**
    160  * Global init of VBox OpenGL for windows
     77 * Global init of VBox OpenGL
    16178 *
    16279 * @returns VBox error code
     
    16582{
    16683    Log(("vboxglGlobalInit\n"));
    167 
    168     glXDisplay = XOpenDisplay(NULL);
    16984
    17085    /*vboxInitOpenGLExtensions();*/
     
    17287}
    17388
     89/**
     90 * Global deinit of VBox OpenGL
     91 *
     92 * @returns VBox error code
     93 */
     94int vboxglGlobalUnload()
     95{
     96    Log(("vboxglGlobalUnload"));
     97
     98    if (glXDisplay)
     99        XCloseDisplay(glXDisplay);
     100
     101    return VINF_SUCCESS;
     102}
    174103
    175104/**
     
    184113        GLX_DRAWABLE_TYPE, GLX_WINDOW_BIT,
    185114        GLX_RENDER_TYPE,   GLX_RGBA_BIT,
    186         GLX_DOUBLEBUFFER,  True,  /* Request a double-buffered color buffer with */
    187         GLX_RED_SIZE,      1,     /* the maximum number of bits per component    */
     115        GLX_DOUBLEBUFFER,  GL_TRUE,  /* Request a double-buffered color buffer with */
     116        GLX_RED_SIZE,      1,        /* the maximum number of bits per component    */
    188117        GLX_GREEN_SIZE,    1,
    189118        GLX_BLUE_SIZE,     1,
     
    195124    int returnedFBConfigs;
    196125
    197     if (!pClient->glxContext)
    198     {
    199         /* we have to set up a rendering context to be able to use glGetString
    200          * a window is created but is not mapped to screen (so it's not visible')
    201          * and a GLXContext is bound to it */
    202         screen_num = DefaultScreen(pClient->dpy);
    203         pClient->enable.fbConfig = pClient->glxChooseFBConfig(pClient->dpy, screen_num, attribs, &returnedFBConfigs);
    204         Log(("vboxglGetString: returned FBConfigs: %d\n", returnedFBConfigs));
    205         pClient->enable.visinfo = pClient->glxGetVisualFromFBConfig(pClient->dpy, pClient->enable.fbConfig[0]);
    206         /* Create Window */
    207         attr.background_pixel = 0;
    208         attr.border_pixel = 0;
    209         attr.colormap = XCreateColormap(pClient->dpy, RootWindow(pClient->dpy, screen_num), pClient->enable.visinfo->visual, AllocNone);
    210         attr.event_mask = StructureNotifyMask | ExposureMask;
    211         mask = CWBackPixel | CWBorderPixel | CWColormap | CWEventMask;
    212         pClient->enable.win = XCreateWindow(pClient->dpy, RootWindow(pClient->dpy, screen_num), 0, 0, 100, 100,
    213                            0, pClient->enable.visinfo->depth, InputOutput,
    214                            pClient->enable.visinfo->visual, mask, &attr);
    215         /* Create Context */
    216         pClient->enable.ctx = pClient->glxCreateNewContext(pClient->dpy, pClient->enable.fbConfig[0], GLX_RGBA_TYPE, NULL, True);
    217 
    218         glXMakeCurrent(pClient->dpy, pClient->enable.win, pClient->enable.ctx);
    219     }
    220     else
    221     {
    222         glXMakeCurrent(pClient->dpy, pClient->xWindow, pClient->glxContext);
    223     }
     126    /* we have to set up a rendering context to be able to use glGetString
     127     * a window is created but is not mapped to screen (so it's not visible')
     128     * and a GLXContext is bound to it */
     129    screen_num = DefaultScreen(pClient->dpy);
     130    pClient->enable.fbConfig = pClient->glxChooseFBConfig(pClient->dpy, screen_num, attribs, &returnedFBConfigs);
     131    Log(("vboxglGetString: returned FBConfigs: %d\n", returnedFBConfigs));
     132    pClient->enable.visinfo = pClient->glxGetVisualFromFBConfig(pClient->dpy, pClient->enable.fbConfig[0]);
     133    /* Create Window */
     134    attr.background_pixel = 0;
     135    attr.border_pixel = 0;
     136    attr.colormap = XCreateColormap(pClient->dpy, RootWindow(pClient->dpy, screen_num), pClient->enable.visinfo->visual, AllocNone);
     137    attr.event_mask = StructureNotifyMask | ExposureMask;
     138    mask = CWBackPixel | CWBorderPixel | CWColormap | CWEventMask;
     139    pClient->enable.win = XCreateWindow(pClient->dpy, RootWindow(pClient->dpy, screen_num), 0, 0, 100, 100,
     140                                        0, pClient->enable.visinfo->depth, InputOutput,
     141                                        pClient->enable.visinfo->visual, mask, &attr);
     142    /* Create Context */
     143    pClient->enable.ctx = pClient->glxCreateNewContext(pClient->dpy, pClient->enable.fbConfig[0], GLX_RGBA_TYPE, NULL, GL_TRUE);
     144    glXMakeCurrent(pClient->dpy, pClient->enable.win, pClient->enable.ctx);
    224145
    225146    return VINF_SUCCESS;
     
    235156{
    236157    /* Free all data */
    237     glFlush();
    238     if (!pClient->glxContext)
     158    if (pClient->enable.ctx)
    239159    {
    240         glXMakeCurrent(pClient->dpy, 0, NULL);
     160        glFlush();
     161        glXMakeCurrent(pClient->dpy, None, NULL);
    241162        XDestroyWindow(pClient->dpy, pClient->enable.win);
    242163        glXDestroyContext(pClient->dpy, pClient->enable.ctx);
     
    244165        XFree(pClient->enable.fbConfig);
    245166    }
     167
    246168    return VINF_SUCCESS;
    247169}
     
    257179    int rc = VERR_NOT_IMPLEMENTED;
    258180    Log(("vboxglConnect\n"));
    259     //pClient->getContextIDPtr = NULL;
    260     //pClient->importContextEXTPtr = NULL;
     181
    261182    pClient->PixelFormatToFBConfigMapper = NULL;
    262183    pClient->xWindow = 0;
    263184
     185    if (!glXDisplay)
     186        glXDisplay = XOpenDisplay(NULL);
     187
    264188    pClient->dpy = glXDisplay;
    265189
     
    272196        if ((major == 1) && (minor >= 3)) {
    273197            Log(("Server GLX 1.3 supported\n"));
    274             pClient->glxChooseFBConfig = (PFNGLXCHOOSEFBCONFIGSGIXPROC) glXGetProcAddress(
     198            pClient->glxChooseFBConfig = (PFNGLXCHOOSEFBCONFIGSGIXPROC) glXGetProcAddressARB(
    275199                                          (GLubyte *) "glXChooseFBConfig");
    276             pClient->glxGetVisualFromFBConfig = (PFNGLXGETVISUALFROMFBCONFIGSGIXPROC) glXGetProcAddress(
     200            pClient->glxGetVisualFromFBConfig = (PFNGLXGETVISUALFROMFBCONFIGSGIXPROC) glXGetProcAddressARB(
    277201                                                 (GLubyte *) "glXGetVisualFromFBConfig");
    278             pClient->glxCreateNewContext = (PFNGLXCREATECONTEXTWITHCONFIGSGIXPROC) glXGetProcAddress(
     202            pClient->glxCreateNewContext = (PFNGLXCREATECONTEXTWITHCONFIGSGIXPROC) glXGetProcAddressARB(
    279203                                            (GLubyte *) "glXCreateNewContext");
    280204        } else if (vboxglCheckExtension(pClient->dpy, screenNum, "GLX_SGIX_fbconfig")) {
    281205            Log(("GLX_SGIX_fbconfig extension supported\n"));
    282             pClient->glxChooseFBConfig = (PFNGLXCHOOSEFBCONFIGSGIXPROC) glXGetProcAddress(
     206            pClient->glxChooseFBConfig = (PFNGLXCHOOSEFBCONFIGSGIXPROC) glXGetProcAddressARB(
    283207                                          (GLubyte *) "glXChooseFBConfigSGIX");
    284             pClient->glxGetVisualFromFBConfig = (PFNGLXGETVISUALFROMFBCONFIGSGIXPROC) glXGetProcAddress(
     208            pClient->glxGetVisualFromFBConfig = (PFNGLXGETVISUALFROMFBCONFIGSGIXPROC) glXGetProcAddressARB(
    285209                                                 (GLubyte *) "glXGetVisualFromFBConfigSGIX");
    286             pClient->glxCreateNewContext = (PFNGLXCREATECONTEXTWITHCONFIGSGIXPROC) glXGetProcAddress(
     210            pClient->glxCreateNewContext = (PFNGLXCREATECONTEXTWITHCONFIGSGIXPROC) glXGetProcAddressARB(
    287211                                            (GLubyte *) "glXCreateContextWithConfigSGIX");
    288212        } else {
     
    329253    XVisualInfo *visinfo = NULL;
    330254    unsigned long mask;
    331     //GLXContext ctx;
    332255    GLXFBConfig fbConfig;
    333256    GLXContextID glrc;
     
    342265    screen_num = DefaultScreen(pClient->dpy);
    343266    fbConfig = pClient->actFBConfig;
    344 
    345 #if 0
    346     if (!fbConfig) {
    347         /* Create a standard fbconfig */
    348         int returnedNumFBConfigs;
    349         GLXFBConfig *returnedFBConfigs;
    350         static int attribs[] = {
    351             GLX_DRAWABLE_TYPE, GLX_WINDOW_BIT,
    352             GLX_RENDER_TYPE,   GLX_RGBA_BIT,
    353             GLX_DOUBLEBUFFER,  True,  /* Request a double-buffered color buffer with */
    354             GLX_RED_SIZE,      1,     /* the maximum number of bits per component    */
    355             GLX_GREEN_SIZE,    1,
    356             GLX_BLUE_SIZE,     1,
    357             None
    358         };
    359 
    360         Log(("Warning: no GLXFBConfig set creating standard one\n"));
    361         returnedFBConfigs = pClient->glxChooseFBConfig(pClient->dpy, screen_num, attribs, &returnedNumFBConfigs);
    362         if (!returnedNumFBConfigs) {
    363             pClient->lastretval = 0;
    364             pClient->fHasLastError = true;
    365             pClient->ulLastError   = glGetError();
    366             return;
    367         }
    368         fbConfig = returnedFBConfigs[0];
    369     }
    370 #endif
    371267
    372268    visinfo = pClient->glxGetVisualFromFBConfig(pClient->dpy, fbConfig);
     
    387283    }
    388284    XResizeWindow(pClient->dpy, pClient->xWindow, pClient->winWidth, pClient->winHeight);
    389     pClient->glxContext = pClient->glxCreateNewContext(pClient->dpy, fbConfig, GLX_RGBA_TYPE, NULL, True);
     285    pClient->glxContext = pClient->glxCreateNewContext(pClient->dpy, fbConfig, GLX_RGBA_TYPE, NULL, GL_TRUE);
    390286
    391287    XMapWindow(pClient->dpy, pClient->xWindow);
    392288    XIfEvent(pClient->dpy, &event, WaitForNotify, (XPointer)pClient->xWindow );
    393     //glrc = pClient->getContextIDPtr(ctx);
     289
    394290    glrc = 1;
    395291    Assert(glrc);
     
    406302void vboxglDrvDeleteContext(VBOXOGLCTX *pClient, uint8_t *pCmdBuffer)
    407303{
    408     //GLXContext ctx;
    409304    OGL_CMD(DrvDeleteContext, 1);
    410305    OGL_PARAM(HGLRC, hglrc);
    411306    Log(("DrvDeleteContext %x\n", hglrc));
    412     //ctx = pClient->importContextEXTPtr(pClient->dpy, hglrc);
     307
    413308    glXDestroyContext(pClient->dpy, VBOX_OGL_GUEST_TO_HOST_HDC(hglrc));
    414309    pClient->lastretval = 1;
     
    419314void vboxglDrvSetContext(VBOXOGLCTX *pClient, uint8_t *pCmdBuffer)
    420315{
    421     //GLXContext ctx;
    422316    OGL_CMD(DrvSetContext, 2);
    423317    OGL_PARAM(HDC, hdc);
     
    425319    Log(("DrvSetContext %x %x\n", hdc, hglrc));
    426320#ifdef VBOX_OGL_DEBUG_WINDOW_OUTPUT
    427     //ctx = pClient->importContextEXTPtr(pClient->dpy, hglrc);
    428     pClient->lastretval = glXMakeCurrent(pClient->dpy, pClient->xWindow, 
     321
     322    pClient->lastretval = glXMakeCurrent(pClient->dpy, pClient->xWindow,
    429323                                         VBOX_OGL_GUEST_TO_HOST_HDC(hglrc));
    430324    if (!pClient->lastretval)
     
    439333void vboxglDrvCopyContext(VBOXOGLCTX *pClient, uint8_t *pCmdBuffer)
    440334{
    441     //GLXContext ctxSrc, ctxDst;
    442335    OGL_CMD(DrvDeleteContext, 3);
    443336    OGL_PARAM(HGLRC, hglrcSrc);
     
    445338    OGL_PARAM(UINT,  mask);
    446339    Log(("DrvCopyContext %x %x %x\n", hglrcSrc, hglrcDst, mask));
    447     //ctxSrc = pClient->importContextEXTPtr(pClient->dpy, hglrcSrc);
    448     //ctxDst = pClient->importContextEXTPtr(pClient->dpy, hglrcDst);
     340
    449341    glXCopyContext(pClient->dpy, VBOX_OGL_GUEST_TO_HOST_HDC(hglrc), VBOX_OGL_GUEST_TO_HOST_HDC(hglrc), mask);
    450342    pClient->lastretval = 1;
     
    459351    Log(("DrvReleaseContext %x\n", hglrc));
    460352    /* clear current selection */
    461     pClient->lastretval = glXMakeCurrent(pClient->dpy, 0, NULL);
     353    pClient->lastretval = glXMakeCurrent(pClient->dpy, None, NULL);
    462354
    463355    if (!pClient->lastretval)
     
    469361void vboxglDrvCreateLayerContext(VBOXOGLCTX *pClient, uint8_t *pCmdBuffer)
    470362{
     363    XSetWindowAttributes attr;
     364    XVisualInfo *visinfo = NULL;
     365    unsigned long mask;
     366    GLXFBConfig fbConfig;
     367    GLXContextID glrc;
     368    int screen_num;
     369    XEvent event;
    471370    OGL_CMD(DrvCreateLayerContext, 2);
    472371    OGL_PARAM(HDC, hdc);
     
    475374    Log(("DrvCreateLayerContext %x\n", hdc));
    476375#ifdef VBOX_OGL_DEBUG_WINDOW_OUTPUT
    477     pClient->lastretval = 0; /** @todo */
     376
     377    screen_num = DefaultScreen(pClient->dpy);
     378    fbConfig = pClient->actFBConfig;
     379    visinfo = pClient->glxGetVisualFromFBConfig(pClient->dpy, fbConfig);
     380
     381    if (pClient->xWindow == 0) {
     382
     383        /* window attributes */
     384        attr.background_pixel = 0;
     385        attr.border_pixel = 0;
     386        attr.colormap = XCreateColormap(pClient->dpy, RootWindow(pClient->dpy, screen_num ), visinfo->visual, AllocNone);
     387        attr.event_mask = StructureNotifyMask | ExposureMask;
     388        mask = CWBackPixel | CWBorderPixel | CWColormap | CWEventMask;
     389        pClient->xWindow = XCreateWindow(pClient->dpy,
     390                                        RootWindow(pClient->dpy, screen_num),
     391                                        0, 0, pClient->winWidth, pClient->winHeight, 0,
     392                                        visinfo->depth, InputOutput,
     393                                        visinfo->visual, mask, &attr);
     394    }
     395    XResizeWindow(pClient->dpy, pClient->xWindow, pClient->winWidth, pClient->winHeight);
     396    pClient->glxContext = pClient->glxCreateNewContext(pClient->dpy, fbConfig, GLX_RGBA_TYPE, NULL, GL_TRUE);
     397    XMapWindow(pClient->dpy, pClient->xWindow);
     398    XIfEvent(pClient->dpy, &event, WaitForNotify, (XPointer)pClient->xWindow );
     399
     400    glrc = 1;
     401    Assert(glrc);
     402
     403    pClient->lastretval = glrc;
    478404    pClient->fHasLastError = true;
    479405    pClient->ulLastError   = glGetError();
     
    529455    pClient->actFBConfig = pClient->PixelFormatToFBConfigMapper[iPixelFormat-1];
    530456    screen_num = DefaultScreen(pClient->dpy);
    531     PrintFBConfigInfo(pClient->dpy, screen_num, pClient->actFBConfig);
    532     Log(("Window width: %d Window height: %d\n", cx, cy));
     457
    533458    pClient->winWidth = cx;
    534459    pClient->winHeight = cy;
  • trunk/src/VBox/HostServices/SharedOpenGL/glwindrv.cpp

    r3708 r3858  
    132132
    133133/**
     134 * Global deinit of VBox OpenGL
     135 *
     136 * @returns VBox error code
     137 */
     138int vboxglGlobalUnload()
     139{
     140    Log(("vboxglGlobalUnload"));
     141
     142    return VINF_SUCCESS;
     143}
     144
     145/**
    134146 * Enable OpenGL
    135147 *
  • trunk/src/VBox/HostServices/SharedOpenGL/service.cpp

    r3709 r3858  
    3939    Log(("svcUnload\n"));
    4040
     41    vboxglGlobalUnload();
    4142    return rc;
    4243}
  • trunk/src/VBox/HostServices/SharedOpenGL/vboxgl.cpp

    r3708 r3858  
    6868
    6969    vboxglDisableOpenGL(pClient);
     70
    7071    return rc;
    7172}
  • trunk/src/VBox/HostServices/SharedOpenGL/vboxgl.h

    r3708 r3858  
    3333
    3434/**
    35  * Global init of VBox OpenGL for windows
     35 * Global init of VBox OpenGL
    3636 *
    3737 * @returns VBox error code
    3838 */
    3939int vboxglGlobalInit();
     40
     41/**
     42 * Global deinit of VBox OpenGL
     43 *
     44 * @returns VBox error code
     45 */
     46int vboxglGlobalUnload();
    4047
    4148/**
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