Changeset 51148 in vbox for trunk/src/VBox/HostServices/SharedOpenGL
- Timestamp:
- Apr 25, 2014 7:31:35 PM (11 years ago)
- svn:sync-xref-src-repo-rev:
- 93473
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_presenter.cpp
r51147 r51148 4836 4836 } 4837 4837 4838 static void crVBoxServerCrCmdBltPrimaryUpdate(const VBVAINFOSCREEN *pScreen, const RTRECT *pRects, uint32_t cRects, uint32_t u32PrimaryID)4838 static void crVBoxServerCrCmdBltPrimaryUpdate(const VBVAINFOSCREEN *pScreen, uint32_t cRects, const RTRECT *pRects) 4839 4839 { 4840 4840 if (!cRects) 4841 4841 return; 4842 4842 4843 uint32_t u32PrimaryID = pScreen->u32ViewIndex; 4843 4844 bool fDirtyEmpty = true; 4844 4845 RTRECT dirtyRect; … … 5006 5007 } 5007 5008 5008 crVBoxServerCrCmdBltPrimaryUpdate(CrFbGetScreenInfo(hFb), pRects, cRects, u32PrimaryID);5009 crVBoxServerCrCmdBltPrimaryUpdate(CrFbGetScreenInfo(hFb), cRects, pRects); 5009 5010 5010 5011 return 0; … … 5105 5106 { 5106 5107 if (hSrcFb) 5107 WARN(("blit from one framebuffer to another not supported properly")); 5108 { 5109 WARN(("blit from one framebuffer, wow")); 5110 5111 int rc = CrFbUpdateBegin(hSrcFb); 5112 if (RT_SUCCESS(rc)) 5113 { 5114 CrFbRegionsClear(hSrcFb); 5115 5116 CrFbUpdateEnd(hSrcFb); 5117 } 5118 else 5119 WARN(("CrFbUpdateBegin failed %d", rc)); 5120 } 5108 5121 5109 5122 CR_BLITTER_IMG Img; … … 5115 5128 } 5116 5129 5117 int rc = CrFbBltPutContentsNe(hDstFb, pPos, cRects, pRects, &Img); 5118 if (RT_FAILURE(rc)) 5119 { 5120 WARN(("CrFbBltPutContentsNe failed %d", rc)); 5121 return -1; 5122 } 5130 const VBVAINFOSCREEN *pScreen = CrFbGetScreenInfo(hDstFb); 5131 if (pScreen->u32Width == dstWidth && pScreen->u32Height == dstHeight) 5132 { 5133 int rc = CrFbBltPutContentsNe(hDstFb, pPos, cRects, pRects, &Img); 5134 if (RT_FAILURE(rc)) 5135 { 5136 WARN(("CrFbBltPutContentsNe failed %d", rc)); 5137 return -1; 5138 } 5139 } 5140 else 5141 { 5142 int rc = CrFbUpdateBegin(hDstFb); 5143 if (RT_SUCCESS(rc)) 5144 { 5145 CrFbRegionsClear(hDstFb); 5146 5147 CrFbUpdateEnd(hDstFb); 5148 } 5149 else 5150 WARN(("CrFbUpdateBegin failed %d", rc)); 5151 5152 rc = crVBoxServerCrCmdBltVramToVramMem(offSrcVRAM, srcWidth, srcHeight, offDstVRAM, dstWidth, dstHeight, pPos, cRects, pRects); 5153 if (RT_FAILURE(rc)) 5154 { 5155 WARN(("crVBoxServerCrCmdBltVramToVramMem failed, %d", rc)); 5156 return -1; 5157 } 5158 } 5159 5160 crVBoxServerCrCmdBltPrimaryUpdate(pScreen, cRects, pRects); 5123 5161 5124 5162 return 0; … … 5134 5172 } 5135 5173 5136 int rc = CrFbBltGetContents(hSrcFb, pPos, cRects, pRects, &Img); 5137 if (RT_FAILURE(rc)) 5138 { 5139 WARN(("CrFbBltGetContents failed %d", rc)); 5140 return -1; 5174 const VBVAINFOSCREEN *pScreen = CrFbGetScreenInfo(hSrcFb); 5175 if (pScreen->u32Width == srcWidth && pScreen->u32Height == srcHeight) 5176 { 5177 int rc = CrFbBltGetContents(hSrcFb, pPos, cRects, pRects, &Img); 5178 if (RT_FAILURE(rc)) 5179 { 5180 WARN(("CrFbBltGetContents failed %d", rc)); 5181 return -1; 5182 } 5183 } 5184 else 5185 { 5186 int rc = CrFbUpdateBegin(hSrcFb); 5187 if (RT_SUCCESS(rc)) 5188 { 5189 CrFbRegionsClear(hSrcFb); 5190 5191 CrFbUpdateEnd(hSrcFb); 5192 } 5193 else 5194 WARN(("CrFbUpdateBegin failed %d", rc)); 5195 5196 rc = crVBoxServerCrCmdBltVramToVramMem(offSrcVRAM, srcWidth, srcHeight, offDstVRAM, dstWidth, dstHeight, pPos, cRects, pRects); 5197 if (RT_FAILURE(rc)) 5198 { 5199 WARN(("crVBoxServerCrCmdBltVramToVramMem failed, %d", rc)); 5200 return -1; 5201 } 5141 5202 } 5142 5203 … … 5275 5336 } 5276 5337 5277 crVBoxServerCrCmdBltPrimaryUpdate(CrFbGetScreenInfo(hFb), pRects, cRects, u32PrimaryID);5338 crVBoxServerCrCmdBltPrimaryUpdate(CrFbGetScreenInfo(hFb), cRects, pRects); 5278 5339 5279 5340 return 0; … … 5445 5506 } 5446 5507 5447 crVBoxServerCrCmdBltPrimaryUpdate(CrFbGetScreenInfo(hFb), pRects, cRects, u32PrimaryID);5508 crVBoxServerCrCmdBltPrimaryUpdate(CrFbGetScreenInfo(hFb), cRects, pRects); 5448 5509 5449 5510 return 0;
Note:
See TracChangeset
for help on using the changeset viewer.