VirtualBox

Ignore:
Timestamp:
Oct 17, 2013 7:34:35 PM (12 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
90045
Message:

crOpenGL: dumping stuff

Location:
trunk/src/VBox/HostServices/SharedOpenGL/crserverlib
Files:
2 edited

Legend:

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

    r48897 r49172  
    488488extern unsigned long g_CrDbgDumpDrawFramesCount;
    489489
     490extern uint32_t g_CrDbgDumpVertattrFixupOn;
     491
    490492bool crServerDumpFilterDmp(unsigned long event, CR_DUMPER *pDumper);
    491 bool crServerDumpFilterOp(unsigned long event, CR_DUMPER *pDumper);
     493bool crServerDumpFilterOpEnter(unsigned long event, CR_DUMPER *pDumper);
     494void crServerDumpFilterOpLeave(unsigned long event, CR_DUMPER *pDumper);
    492495
    493496//#define CR_SERVER_DUMP_MASK_OP                  0x0000fffc
     
    581584                        || (g_CrDbgDumpPid > 0 && ((uint64_t)g_CrDbgDumpPid) == cr_server.curClient->pid) \
    582585                        || (g_CrDbgDumpPid < 0 && ((uint64_t)(-g_CrDbgDumpPid)) != cr_server.curClient->pid)) \
    583                 && crServerDumpFilterOp((_ev), (_pDumper)))
     586                && crServerDumpFilterOpEnter((_ev), (_pDumper)))
    584587#define CR_SERVER_DUMP_FILTER_DMP(_ev, _pDumper) (crServerDumpFilterDmp((_ev), (_pDumper)))
    585588
     
    595598            if (CR_SERVER_DUMP_FILTER_DMP(CR_SERVER_DUMP_F_DRAW_BUFF_ENTER, cr_server.Recorder.pDumper)) { crServerDumpBuffer(-1); } \
    596599            crDmpStrF(cr_server.Recorder.pDumper, "==Done ENTER[%d] %s==", (uint32_t)cr_server.curClient->pid, __FUNCTION__); \
     600            crServerDumpFilterOpLeave(CR_SERVER_DUMP_F_DRAW_ENTER_ALL, cr_server.Recorder.pDumper); \
    597601        } while (0)
    598602
     
    608612            if (CR_SERVER_DUMP_FILTER_DMP(CR_SERVER_DUMP_F_DRAW_STATE_LEAVE, cr_server.Recorder.pDumper)) { crServerDumpState(); } \
    609613            crDmpStrF(cr_server.Recorder.pDumper, "==Done LEAVE[%d] %s==", (uint32_t)cr_server.curClient->pid, __FUNCTION__); \
     614            crServerDumpFilterOpLeave(CR_SERVER_DUMP_F_DRAW_LEAVE_ALL, cr_server.Recorder.pDumper); \
    610615        } while (0)
    611616
     
    616621            crServerDumpShader((_id)); \
    617622            crDmpStrF(cr_server.Recorder.pDumper, "==Done[%d] %s==", (uint32_t)cr_server.curClient->pid, __FUNCTION__); \
     623            crServerDumpFilterOpLeave(CR_SERVER_DUMP_F_COMPILE_SHADER, cr_server.Recorder.pDumper); \
    618624        } while (0)
    619625
     
    624630            crServerDumpShader((_id)); \
    625631            crDmpStrF(cr_server.Recorder.pDumper, "==Done[%d] %s==", (uint32_t)cr_server.curClient->pid, __FUNCTION__); \
     632            crServerDumpFilterOpLeave(CR_SERVER_DUMP_F_SHADER_SOURCE, cr_server.Recorder.pDumper); \
    626633        } while (0)
    627634
     
    632639            crServerDumpProgram((_id)); \
    633640            crDmpStrF(cr_server.Recorder.pDumper, "==Done[%d] %s==", (uint32_t)cr_server.curClient->pid, __FUNCTION__); \
     641            crServerDumpFilterOpLeave(CR_SERVER_DUMP_F_LINK_PROGRAM, cr_server.Recorder.pDumper); \
    634642        } while (0)
    635643
     
    641649            if (g_CrDbgDumpDrawFramesCount) { crServerDumpFramesCheck(); } \
    642650            crDmpStrF(cr_server.Recorder.pDumper, "==Done ENTER[%d] %s==", (uint32_t)cr_server.curClient->pid, __FUNCTION__); \
     651            crServerDumpFilterOpLeave(CR_SERVER_DUMP_F_SWAPBUFFERS_ENTER, cr_server.Recorder.pDumper); \
    643652        } while (0)
    644653
     
    648657            crDmpStrF(cr_server.Recorder.pDumper, "==[%d] %s==", (uint32_t)cr_server.curClient->pid, __FUNCTION__); \
    649658            crServerDumpTexture((_pTex)); \
     659            crServerDumpFilterOpLeave(CR_SERVER_DUMP_F_TEXPRESENT, cr_server.Recorder.pDumper); \
    650660        } while (0)
    651661
     
    655665            crServerDumpCheckInit(); \
    656666            crDmpStrF(cr_server.Recorder.pDumper, "==Done LEAVE[%d] %s==", (uint32_t)cr_server.curClient->pid, __FUNCTION__); \
     667            crServerDumpFilterOpLeave(CR_SERVER_DUMP_F_SWAPBUFFERS_LEAVE, cr_server.Recorder.pDumper); \
    657668        } while (0)
    658669
     
    662673        crDmpStrF(cr_server.Recorder.pDumper, "==[%d] %s==", (uint32_t)cr_server.curClient->pid, __FUNCTION__); \
    663674        crServerDumpDrawel _msg; \
     675        crServerDumpFilterOpLeave(CR_SERVER_DUMP_F_DRAWEL, cr_server.Recorder.pDumper); \
    664676    } while (0)
    665677
     
    669681        crDmpStrF(cr_server.Recorder.pDumper, "==[%d] %s==", (uint32_t)cr_server.curClient->pid, __FUNCTION__); \
    670682        crServerDumpDrawelv((_index), (_pszElFormat), (_cbEl), (_pvVal), (_cVal)); \
     683        crServerDumpFilterOpLeave(CR_SERVER_DUMP_F_DRAWEL, cr_server.Recorder.pDumper); \
    671684    } while (0)
    672685#else /* if !defined VBOX_WITH_CRSERVER_DUMPER */
  • trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_misc.c

    r48897 r49172  
    130130
    131131    case GL_GATHER_CONNECT_CR:
    132         /* 
     132        /*
    133133         * We want the last connect to go through,
    134134         * otherwise we might deadlock in CheckWindowSize()
     
    136136         */
    137137        gather_connect_count++;
    138         if (cr_server.only_swap_once && (gather_connect_count != cr_server.numClients)) 
     138        if (cr_server.only_swap_once && (gather_connect_count != cr_server.numClients))
    139139        {
    140140            break;
     
    156156            const int eye = v[1] == 0.0 ? 0 : 1;
    157157            crMatrixInitFromFloats(&cr_server.viewMatrix[eye], v + 2);
    158            
    159             crDebug("Got GL_SERVER_VIEW_MATRIX_CR:\n" 
     158
     159            crDebug("Got GL_SERVER_VIEW_MATRIX_CR:\n"
    160160                            "  %f %f %f %f\n"
    161161                            "  %f %f %f %f\n"
     
    194194            const int eye = v[1] == 0.0 ? 0 : 1;
    195195            crMatrixInitFromFloats(&cr_server.projectionMatrix[eye], v + 2);
    196      
    197             crDebug("Got GL_SERVER_PROJECTION_MATRIX_CR:\n" 
     196
     197            crDebug("Got GL_SERVER_PROJECTION_MATRIX_CR:\n"
    198198                            "  %f %f %f %f\n"
    199199                            "  %f %f %f %f\n"
     
    230230                float bottom = znear * (b - 1.0f) / y;
    231231              float top = 2.0f * znear / y + bottom;
    232               crDebug("Frustum: left, right, bottom, top, near, far: %f, %f, %f, %f, %f, %f", left, right, bottom, top, znear, zfar);   
     232              crDebug("Frustum: left, right, bottom, top, near, far: %f, %f, %f, %f, %f, %f", left, right, bottom, top, znear, zfar);
    233233            }
    234234            else {
     
    323323
    324324
    325 void SERVER_DISPATCH_APIENTRY 
     325void SERVER_DISPATCH_APIENTRY
    326326crServerDispatchCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
    327327{
     
    424424            gl->GenFramebuffersEXT(1, &fboID);
    425425            gl->BindFramebufferEXT(GL_FRAMEBUFFER_EXT, fboID);
    426             gl->FramebufferTexture2DEXT(GL_FRAMEBUFFER_EXT, GL_COLOR_ATTACHMENT0_EXT, target, 
     426            gl->FramebufferTexture2DEXT(GL_FRAMEBUFFER_EXT, GL_COLOR_ATTACHMENT0_EXT, target,
    427427                                        ctx->texture.unit[ctx->texture.curTextureUnit].currentTexture2D->hwid, level);
    428428            status = gl->CheckFramebufferStatusEXT(GL_FRAMEBUFFER_EXT);
     
    492492                gl->GetTexImage(target, level, GL_BGRA, GL_UNSIGNED_BYTE, img1);
    493493
    494            
     494
    495495                for (dRow=yoffset, sRow=y-height-1; dRow<yoffset-height; dRow++, sRow--)
    496496                {
     
    879879}
    880880
    881 void SERVER_DISPATCH_APIENTRY 
     881void SERVER_DISPATCH_APIENTRY
    882882crServerDispatchBlitFramebufferEXT(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1,
    883                                    GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, 
     883                                   GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1,
    884884                                   GLbitfield mask, GLenum filter)
    885885{
     
    16281628}
    16291629
    1630 bool crServerDumpFilterOp(unsigned long event, CR_DUMPER *pDumper)
     1630void crServerDumpFilterOpLeave(unsigned long event, CR_DUMPER *pDumper)
     1631{
     1632}
     1633
     1634bool crServerDumpFilterOpEnter(unsigned long event, CR_DUMPER *pDumper)
    16311635{
    16321636    return CR_SERVER_DUMP_DEFAULT_FILTER_OP(event);
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