Changeset 51393 in vbox for trunk/src/VBox/Additions/x11/vboxvideo
- Timestamp:
- May 26, 2014 12:39:34 PM (11 years ago)
- Location:
- trunk/src/VBox/Additions/x11/vboxvideo
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/x11/vboxvideo/pointer.c
r51242 r51393 542 542 543 543 TRACE_ENTRY(); 544 if (!pVBox->fHaveHGSMI)545 return FALSE;546 544 pVBox->pCurs = pCurs = xf86CreateCursorInfoRec(); 547 545 if (!pCurs) { -
trunk/src/VBox/Additions/x11/vboxvideo/setmode.c
r50569 r51393 100 100 VBOXPtr pVBox = VBOXGetRec(pScrn); 101 101 uint32_t offStart, cwReal = cWidth; 102 uint16_t fFlags; 102 103 103 104 TRACE_LOG("cDisplay=%u, cWidth=%u, cHeight=%u, x=%d, y=%d, displayWidth=%d\n", … … 121 122 VBoxVideoSetModeRegisters(cwReal, cHeight, pScrn->displayWidth, 122 123 vboxBPP(pScrn), 0, x, y); 123 if (pVBox->fHaveHGSMI) 124 { 125 uint16_t fFlags = VBVA_SCREEN_F_ACTIVE; 126 fFlags |= (pVBox->afDisabled[cDisplay] ? VBVA_SCREEN_F_DISABLED : 0); 127 VBoxHGSMIProcessDisplayInfo(&pVBox->guestCtx, cDisplay, x, y, 128 offStart, pVBox->cbLine, cwReal, cHeight, 129 vboxBPP(pScrn), fFlags); 130 } 124 fFlags = VBVA_SCREEN_F_ACTIVE; 125 fFlags |= (pVBox->afDisabled[cDisplay] ? VBVA_SCREEN_F_DISABLED : 0); 126 VBoxHGSMIProcessDisplayInfo(&pVBox->guestCtx, cDisplay, x, y, 127 offStart, pVBox->cbLine, cwReal, cHeight, 128 vboxBPP(pScrn), fFlags); 131 129 return TRUE; 132 130 } -
trunk/src/VBox/Additions/x11/vboxvideo/vboxvideo.c
r51374 r51393 1082 1082 pScrn->vtSema = TRUE; 1083 1083 1084 if (vbox_open (pScrn, pScreen, pVBox)) { 1085 vboxEnableVbva(pScrn); 1086 } 1084 vbox_open (pScrn, pScreen, pVBox); 1085 vboxEnableVbva(pScrn); 1087 1086 VBoxInitialiseSizeHints(pScrn); 1088 1087 … … 1231 1230 } 1232 1231 #endif 1233 if (pVBox->fHaveHGSMI) 1234 vboxEnableVbva(pScrn); 1232 vboxEnableVbva(pScrn); 1235 1233 /* Re-assert this in case we had a change request while switched out. */ 1236 1234 if (pVBox->FBSize.cx && pVBox->FBSize.cy) … … 1256 1254 1257 1255 TRACE_ENTRY(); 1258 if (pVBox->fHaveHGSMI) 1259 vboxDisableVbva(pScrn); 1256 vboxDisableVbva(pScrn); 1260 1257 vboxClearVRAM(pScrn, 0, 0); 1261 1258 #ifdef VBOX_DRI_OLD … … 1287 1284 if (pScrn->vtSema) 1288 1285 { 1289 if (pVBox->fHaveHGSMI) 1290 vboxDisableVbva(pScrn); 1286 vboxDisableVbva(pScrn); 1291 1287 vboxClearVRAM(pScrn, 0, 0); 1292 1288 } -
trunk/src/VBox/Additions/x11/vboxvideo/vboxvideo.h
r51242 r51393 175 175 /** Do we know that the guest can handle absolute co-ordinates? */ 176 176 Bool guestCanAbsolute; 177 /** Does this host support sending graphics commands using HGSMI? */178 Bool fHaveHGSMI;179 177 /** Number of screens attached */ 180 178 uint32_t cScreens; … … 218 216 extern Bool vbox_init(int scrnIndex, VBOXPtr pVBox); 219 217 extern Bool vbox_cursor_init (ScreenPtr pScreen); 220 extern Boolvbox_open (ScrnInfoPtr pScrn, ScreenPtr pScreen, VBOXPtr pVBox);218 extern void vbox_open (ScrnInfoPtr pScrn, ScreenPtr pScreen, VBOXPtr pVBox); 221 219 extern void vbox_close (ScrnInfoPtr pScrn, VBOXPtr pVBox); 222 220 extern Bool vbox_device_available(VBOXPtr pVBox); -
trunk/src/VBox/Additions/x11/vboxvideo/vbva.c
r50485 r51393 60 60 61 61 pVBox = pScrn->driverPrivate; 62 if ( pVBox->fHaveHGSMI == FALSE ||!pScrn->vtSema)62 if (!pScrn->vtSema) 63 63 return; 64 64 … … 179 179 void *pvGuestHeapMemory; 180 180 181 if (!pVBox->fHaveHGSMI)182 return FALSE;183 181 VBoxHGSMIGetBaseMappingInfo(pScrn->videoRam * 1024, &offVRAMBaseMapping, 184 182 NULL, &offGuestHeapMemory, &cbGuestHeapMemory, … … 225 223 } 226 224 227 Bool 225 void 228 226 vbox_open(ScrnInfoPtr pScrn, ScreenPtr pScreen, VBOXPtr pVBox) 229 227 { 230 228 TRACE_ENTRY(); 231 229 232 pVBox->fHaveHGSMI = vboxInitVbva(pScrn->scrnIndex, pScreen, pVBox);233 return pVBox->fHaveHGSMI;230 if (!vboxInitVbva(pScrn->scrnIndex, pScreen, pVBox)) 231 FatalError("failed to initialise vboxvideo graphics acceleration.\n"); 234 232 } 235 233 … … 294 292 295 293 TRACE_ENTRY(); 296 if (!pVBox->fHaveHGSMI) /* Ths function should not have been called */297 return;298 294 for (i = 0; i < pVBox->cScreens; ++i) 299 295 VBoxVBVADisable(&pVBox->aVbvaCtx[i], &pVBox->guestCtx, i);
Note:
See TracChangeset
for help on using the changeset viewer.