Do not hard the drv. that is bad with u patch But we are using the vbe as defualt drv. in second boot. and there it change the drv by the pnp if it found another one. I can liv with that small problem. rember vga drv can only work with 640x480x 8bits (640x480 with 256 color) .
----- Original Message ----- From: "Maarten Bosma" maarten.paul@bosma.de To: "ReactOS Development List" ros-dev@reactos.org Sent: den 23 December 2005 12:29 Subject: [ros-dev] Change resolution in 1st stage installer (Patch to review)
In revision 20194 Brandon Turner changed to default resolution to 800x600x16. Many people were not happy with it, especially GreateLord how has got a monitor that is capable of that resolution. On the other hand ReactOS looks way better in 800x600x16. Especially if we want to include photo wallpapers, it is a bad idea imo if the they won't work with the standard resolution.
It was GreatLord's idea to make it a option at 1st stage installer, that way the default can stay 800x600 but people with old monitors got a chance to choose 640x680. So here is the patch.
Maarten Bosma
---------------------------------------------------------------------------- ----
Index: subsys/system/usetup/settings.c
--- subsys/system/usetup/settings.c (revision 20296) +++ subsys/system/usetup/settings.c (working copy) @@ -521,6 +521,66 @@ return FALSE; }
- /* Set the resolution */
- // ToDo:
- // * get Driver Name into Path
- PWCHAR Buffer;
- if (!InfGetDataField(Context, 4, &Buffer))
- {
DPRINT("InfGetDataField() failed\n");return FALSE;- }
- ULONG Width = wcstoul(Buffer, NULL, 0);
- Status = RtlWriteRegistryValue(RTL_REGISTRY_ABSOLUTE,
- L"\Registry\Machine\System\CurrentControlSet\Hardware
Profiles\Current\System\CurrentControlSet\Services\VBE\Device0", // FIXME: Do not hardcode driver name
- L"DefaultSettings.XResolution",
- REG_DWORD,
- &Width,
- sizeof(ULONG));
- if (!NT_SUCCESS(Status))
- {
DPRINT("RtlWriteRegistryValue() failed (Status %lx)\n", Status);return FALSE;- }
- if (!InfGetDataField(Context, 5, &Buffer))
- {
DPRINT("InfGetDataField() failed\n");return FALSE;- }
- ULONG Hight = wcstoul(Buffer, NULL, 0);
- Status = RtlWriteRegistryValue(RTL_REGISTRY_ABSOLUTE,
- L"\Registry\Machine\System\CurrentControlSet\Hardware
Profiles\Current\System\CurrentControlSet\Services\VBE\Device0", // FIXME: Do not hardcode driver name
- L"DefaultSettings.YResolution",
- REG_DWORD,
- &Hight,
- sizeof(ULONG));
- if (!NT_SUCCESS(Status))
- {
DPRINT("RtlWriteRegistryValue() failed (Status %lx)\n", Status);return FALSE;- }
- if (!InfGetDataField(Context, 6, &Buffer))
- {
DPRINT("InfGetDataField() failed\n");return FALSE;- }
- ULONG Bpp = wcstoul(Buffer, NULL, 0);
- Status = RtlWriteRegistryValue(RTL_REGISTRY_ABSOLUTE,
- L"\Registry\Machine\System\CurrentControlSet\Hardware
Profiles\Current\System\CurrentControlSet\Services\VBE\Device0", // FIXME: Do not hardcode driver name
- L"DefaultSettings.BitsPerPel",
- REG_DWORD,
- &Bpp,
- sizeof(ULONG));
- if (!NT_SUCCESS(Status))
- {
DPRINT("RtlWriteRegistryValue() failed (Status %lx)\n", Status);return FALSE;- }
- /* Enable the right driver */ if (!InfGetDataField(Context, 3, &ServiceName)) { DPRINT("InfGetDataField() failed\n");
Index: bootdata/txtsetup.sif
--- bootdata/txtsetup.sif (revision 20296) +++ bootdata/txtsetup.sif (working copy) @@ -66,9 +66,10 @@ halmp.dll = 2,hal.dll
[Display] -;<id> = <user friendly name>,<spare>,<service key name> -vga = "VGA Display",,Vga -vbe = "VESA Display",,VBE +;<id> = <user friendly name>,<spare>,<service key
name>,<hight>,<width>,<bpp>
+vga = "VGA Display (640x680x8)",,Vga,640,480,8 +vbe_lowres = "VESA Display (640x680x8)",,VBE,640,480,8 +vbe = "VESA Display (800x600x16)",,VBE,800,600,16
[Map.Display] ;<id> = <pnp id string>
---------------------------------------------------------------------------- ----
Ros-dev mailing list Ros-dev@reactos.org http://www.reactos.org/mailman/listinfo/ros-dev