Changeset 51069 in vbox for trunk/src/VBox/HostServices/SharedOpenGL
- Timestamp:
- Apr 14, 2014 4:51:24 PM (11 years ago)
- Location:
- trunk/src/VBox/HostServices/SharedOpenGL/crserverlib
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server.h
r51065 r51069 423 423 424 424 425 int CrPMgrInit(); 426 void CrPMgrTerm(); 425 427 int CrPMgrDisable(); 426 428 int CrPMgrEnable(); 427 int CrPMgrInit();428 void CrPMgrTerm();429 429 430 430 typedef DECLCALLBACKPTR(bool, PFNCR_FRAMEBUFFER_ENTRIES_VISITOR_CB)(HCR_FRAMEBUFFER hFb, HCR_FRAMEBUFFER_ENTRY hEntry, void *pvContext); -
trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_presenter.cpp
r51064 r51069 2599 2599 } 2600 2600 2601 virtual int RegionsChanged(struct CR_FRAMEBUFFER *pFb) 2602 { 2603 int rc = CrFbDisplayBase::RegionsChanged(pFb); 2604 if (!RT_SUCCESS(rc)) 2605 { 2606 WARN(("err")); 2607 return rc; 2608 } 2609 2610 if (mpWindow->GetParentId()) 2611 { 2612 rc = mpWindow->Create(); 2613 if (!RT_SUCCESS(rc)) 2614 { 2615 WARN(("err")); 2616 return rc; 2617 } 2618 } 2619 2620 return VINF_SUCCESS; 2621 } 2622 2601 2623 virtual int EntryCreated(struct CR_FRAMEBUFFER *pFb, HCR_FRAMEBUFFER_ENTRY hEntry) 2602 2624 { … … 2938 2960 } 2939 2961 2940 mu32Screen = CrFbGetScreenInfo(getFramebuffer())->u32ViewIndex; 2941 2942 return windowSync(); 2962 HCR_FRAMEBUFFER hFb = getFramebuffer(); 2963 2964 mu32Screen = CrFbGetScreenInfo(hFb)->u32ViewIndex; 2965 2966 rc = windowSync(); 2967 if (!RT_SUCCESS(rc)) 2968 { 2969 WARN(("windowSync failed %d", rc)); 2970 return rc; 2971 } 2972 2973 if (CrFbHas3DData(hFb)) 2974 { 2975 if (mpWindow->GetParentId()) 2976 { 2977 rc = mpWindow->Create(); 2978 if (!RT_SUCCESS(rc)) 2979 { 2980 WARN(("err")); 2981 return rc; 2982 } 2983 } 2984 } 2985 2986 return VINF_SUCCESS; 2943 2987 } 2944 2988 … … 3646 3690 } 3647 3691 3648 int crServerDisplaySaveState(PSSMHANDLE pSSM)3649 {3650 int rc;3651 int cDisplays = 0, i;3652 for (i = 0; i < cr_server.screenCount; ++i)3653 {3654 if (ASMBitTest(cr_server.DisplaysInitMap, i) && !CrDpIsEmpty(&cr_server.aDispplays[i]))3655 ++cDisplays;3656 }3657 3658 rc = SSMR3PutS32(pSSM, cDisplays);3659 AssertRCReturn(rc, rc);3660 3661 if (!cDisplays)3662 return VINF_SUCCESS;3663 3664 rc = SSMR3PutS32(pSSM, cr_server.screenCount);3665 AssertRCReturn(rc, rc);3666 3667 for (i = 0; i < cr_server.screenCount; ++i)3668 {3669 rc = SSMR3PutS32(pSSM, cr_server.screen[i].x);3670 AssertRCReturn(rc, rc);3671 3672 rc = SSMR3PutS32(pSSM, cr_server.screen[i].y);3673 AssertRCReturn(rc, rc);3674 3675 rc = SSMR3PutU32(pSSM, cr_server.screen[i].w);3676 AssertRCReturn(rc, rc);3677 3678 rc = SSMR3PutU32(pSSM, cr_server.screen[i].h);3679 AssertRCReturn(rc, rc);3680 }3681 3682 for (i = 0; i < cr_server.screenCount; ++i)3683 {3684 if (ASMBitTest(cr_server.DisplaysInitMap, i) && !CrDpIsEmpty(&cr_server.aDispplays[i]))3685 {3686 rc = SSMR3PutS32(pSSM, i);3687 AssertRCReturn(rc, rc);3688 3689 rc = CrDpSaveState(&cr_server.aDispplays[i], pSSM);3690 AssertRCReturn(rc, rc);3691 }3692 }3693 3694 return VINF_SUCCESS;3695 }3696 3697 int crServerDisplayLoadState(PSSMHANDLE pSSM, uint32_t u32Version)3698 {3699 3700 }3701 3692 #endif 3702 3693 … … 4247 4238 hFb = CrPMgrFbGetNextEnabled(hFb)) 4248 4239 { 4240 if (!CrFbHas3DData(hFb)) 4241 continue; 4242 4249 4243 uint32_t idScreen = CrFbGetScreenInfo(hFb)->u32ViewIndex; 4250 4244 CR_FBDISPLAY_INFO *pInfo = &g_CrPresenter.aDisplayInfos[idScreen]; … … 4528 4522 int CrFbLoadState(CR_FRAMEBUFFER *pFb, PSSMHANDLE pSSM, uint32_t version) 4529 4523 { 4524 Assert(0); 4530 4525 uint32_t u32 = 0; 4531 4526 int rc = SSMR3GetU32(pSSM, &u32); … … 4542 4537 rc = CrFbEntryLoadState(pFb, pSSM, version); 4543 4538 AssertRCReturn(rc, rc); 4544 4545 4539 } 4546 4540
Note:
See TracChangeset
for help on using the changeset viewer.