Add initial vesa modes even if EDID information is present. EDID does not

include all supported video modes. Fixes #4166.

Note that this change will probably show several weird resolution is some
configurations. They are all valid resolutions but are not commom so we need
a way to filter those out.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42600 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Bruno G. Albuquerque
2011-08-08 16:13:56 +00:00
parent aca6ac3cc2
commit 18fe0231df
+12 -14
View File
@@ -76,23 +76,21 @@ create_mode_list(void)
const color_space kVesaSpaces[] = {B_RGB32_LITTLE, B_RGB24_LITTLE,
B_RGB16_LITTLE, B_RGB15_LITTLE, B_CMAP8};
// Create the initial list from the support mode list - but only if we don't
// have EDID info available, as that should be good enough.
display_mode* initialModes = NULL;
uint32 initialModesCount = 0;
if (!gInfo->shared_info->has_edid) {
initialModes = (display_mode*)malloc(
sizeof(display_mode) * gInfo->shared_info->vesa_mode_count);
if (initialModes != NULL) {
initialModesCount = gInfo->shared_info->vesa_mode_count;
vesa_mode* vesaModes = gInfo->vesa_modes;
for (uint32 i = gInfo->shared_info->vesa_mode_count; i-- > 0;) {
compute_display_timing(vesaModes[i].width, vesaModes[i].height,
60, false, &initialModes[i].timing);
fill_display_mode(vesaModes[i].width, vesaModes[i].height,
&initialModes[i]);
}
// Add initial VESA modes.
initialModes = (display_mode*)malloc(
sizeof(display_mode) * gInfo->shared_info->vesa_mode_count);
if (initialModes != NULL) {
initialModesCount = gInfo->shared_info->vesa_mode_count;
vesa_mode* vesaModes = gInfo->vesa_modes;
for (uint32 i = gInfo->shared_info->vesa_mode_count; i-- > 0;) {
compute_display_timing(vesaModes[i].width, vesaModes[i].height,
60, false, &initialModes[i].timing);
fill_display_mode(vesaModes[i].width, vesaModes[i].height,
&initialModes[i]);
}
}