Changeset 38207 in vbox for trunk/src/VBox/Additions/common
- Timestamp:
- Jul 27, 2011 9:56:28 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/VBoxVideo/Modesetting.cpp
r35999 r38207 6 6 7 7 /* 8 * Copyright (C) 2006-201 0Oracle Corporation8 * Copyright (C) 2006-2011 Oracle Corporation 9 9 * 10 10 * This file is part of VirtualBox Open Source Edition (OSE), as … … 43 43 cDisplays = 1; 44 44 return cDisplays; 45 } 46 47 48 /** 49 * Returns the size of the video RAM in bytes. 50 * 51 * @returns the size 52 */ 53 RTDECL(uint32_t) VBoxVideoGetVRAMSize(void) 54 { 55 /** @note A 32bit read on this port returns the VRAM size. */ 56 return VBoxVideoCmnPortReadUlong(VBE_DISPI_IOPORT_DATA); 57 } 58 59 60 /** 61 * Check whether this hardware allows the display width to have non-multiple- 62 * of-eight values. 63 * 64 * @returns true if any width is allowed, false otherwise. 65 */ 66 RTDECL(bool) VBoxVideoAnyWidthAllowed(void) 67 { 68 unsigned DispiId; 69 VBoxVideoCmnPortWriteUshort(VBE_DISPI_IOPORT_INDEX, VBE_DISPI_INDEX_ID); 70 VBoxVideoCmnPortWriteUshort(VBE_DISPI_IOPORT_DATA, VBE_DISPI_ID_ANYX); 71 DispiId = VBoxVideoCmnPortReadUshort(VBE_DISPI_IOPORT_DATA); 72 return (DispiId == VBE_DISPI_ID_ANYX); 45 73 } 46 74 … … 180 208 181 209 /** 182 * Get the video mode for the first screen using the port registers. All 183 * parameters are optional 184 * @note If anyone else needs additional values just extend the function with 185 * additional parameters and fix any existing callers. 186 * @param pcWidth where to store the mode width 187 * @param pcHeight where to store the mode height 188 * @param pcVirtWidth where to store the mode pitch 189 * @param pcBPP where to store the colour depth of the mode 190 * @param pfFlags where to store the flags for the mode 210 * Disable our extended graphics mode and go back to VGA mode. 191 211 */ 192 212 RTDECL(void) VBoxVideoDisableVBE(void)
Note:
See TracChangeset
for help on using the changeset viewer.