diff --git a/reactos/base/setup/usetup/bootsup.c b/reactos/base/setup/usetup/bootsup.c index 17684789ba3..354ac7edb43 100644 --- a/reactos/base/setup/usetup/bootsup.c +++ b/reactos/base/setup/usetup/bootsup.c @@ -310,7 +310,7 @@ CreateFreeLoaderIniForDos(PWCHAR IniPath, NULL, INSERT_LAST, L"Options", - L"/DEBUGPORT=SCREEN /NOGUIBOOT /SOS"); + L"/DEBUGPORT=SCREEN /SOS"); /* Create "DOS" section */ IniSection = IniCacheAppendSection(IniCache, diff --git a/reactos/boot/freeldr/freeldr/arch/i386/pcvideo.c b/reactos/boot/freeldr/freeldr/arch/i386/pcvideo.c index 2bee2b7997f..c9f45840ded 100644 --- a/reactos/boot/freeldr/freeldr/arch/i386/pcvideo.c +++ b/reactos/boot/freeldr/freeldr/arch/i386/pcvideo.c @@ -596,7 +596,7 @@ PcVideoSetMode80x50_80x43(VOID) { if (VIDEOCARD_VGA == PcVideoDetectVideoCard()) { - PcVideoSetBiosMode(0x03); + PcVideoSetBiosMode(0x12); PcVideoSetFont8x8(); PcVideoSelectAlternatePrintScreen(); PcVideoDisableCursorEmulation(); @@ -1108,8 +1108,8 @@ PcVideoSync(VOID) VOID PcVideoPrepareForReactOS(VOID) { - PcVideoSetMode80x50_80x43(); - PcVideoHideShowTextCursor(FALSE); + PcVideoSetBiosMode(0x12); + PcVideoHideShowTextCursor(FALSE); } /* EOF */ diff --git a/reactos/boot/freeldr/freeldr/reactos/reactos.c b/reactos/boot/freeldr/freeldr/reactos/reactos.c index eafd96dd86f..cdf4500cc0c 100644 --- a/reactos/boot/freeldr/freeldr/reactos/reactos.c +++ b/reactos/boot/freeldr/freeldr/reactos/reactos.c @@ -932,7 +932,7 @@ LoadAndBootReactOS(PCSTR OperatingSystemName) * Now boot the kernel */ DiskStopFloppyMotor(); - //MachVideoPrepareForReactOS(); + MachVideoPrepareForReactOS(); FrLdrStartup(0x2badb002); } diff --git a/reactos/drivers/base/bootvid/vga.c b/reactos/drivers/base/bootvid/vga.c index 398df46901f..a3433ef13f7 100644 --- a/reactos/drivers/base/bootvid/vga.c +++ b/reactos/drivers/base/bootvid/vga.c @@ -847,7 +847,7 @@ VidSetScrollRegion(ULONG x1, { /* Assert alignment */ ASSERT((x1 & 0x7) == 0); - ASSERT((x2 & 0x7) == 0); + ASSERT((x2 & 0x7) == 7); /* Set Scroll Region */ ScrollRegion[0] = x1; diff --git a/reactos/ntoskrnl/ex/init.c b/reactos/ntoskrnl/ex/init.c index f747464ec87..e6a180e5469 100644 --- a/reactos/ntoskrnl/ex/init.c +++ b/reactos/ntoskrnl/ex/init.c @@ -1028,7 +1028,7 @@ Phase1InitializationDiscard(PVOID Context) { /* It is, display the boot logo and enable printing strings */ InbvEnableDisplayString(SosEnabled); - //DisplayBootBitmap(SosEnabled); + DisplayBootBitmap(SosEnabled); } else { @@ -1204,7 +1204,7 @@ Phase1InitializationDiscard(PVOID Context) /* Wait 5 seconds for it to initialize */ Timeout.QuadPart = Int32x32To64(5, -10000000); Status = ZwWaitForSingleObject(ProcessInfo->ProcessHandle, FALSE, &Timeout); - //if (InbvBootDriverInstalled) FinalizeBootLogo(); + if (InbvBootDriverInstalled) FinalizeBootLogo(); if (Status == STATUS_SUCCESS) { diff --git a/reactos/ntoskrnl/ex/power.c b/reactos/ntoskrnl/ex/power.c index 346547cd09f..f6dcc20ce94 100644 --- a/reactos/ntoskrnl/ex/power.c +++ b/reactos/ntoskrnl/ex/power.c @@ -150,7 +150,7 @@ ShutdownThreadMain(PVOID Context) InbvSetTextColor(15); InbvInstallDisplayStringFilter(NULL); InbvEnableDisplayString(TRUE); - //InbvSetScrollRegion(0, 0, 639, 479); + InbvSetScrollRegion(0, 0, 639, 479); } if (Action == ShutdownNoReboot) diff --git a/reactos/ntoskrnl/inbv/inbv.c b/reactos/ntoskrnl/inbv/inbv.c index 68e342e4898..285fb4ae4dc 100644 --- a/reactos/ntoskrnl/inbv/inbv.c +++ b/reactos/ntoskrnl/inbv/inbv.c @@ -19,6 +19,9 @@ INBV_PROGRESS_STATE InbvProgressState; INBV_RESET_DISPLAY_PARAMETERS InbvResetDisplayParameters; ULONG ResourceCount; PUCHAR ResourceList[64]; +BOOLEAN SysThreadCreated; +ROT_BAR_TYPE RotBarSelection; +ULONG PltRotBarStatus; /* FUNCTIONS *****************************************************************/ @@ -528,3 +531,94 @@ NtDisplayString(IN PUNICODE_STRING DisplayString) /* Return success */ return STATUS_SUCCESS; } + +VOID +NTAPI +DisplayBootBitmap(IN BOOLEAN SosMode) +{ + PVOID Bitmap, Header; + ROT_BAR_TYPE TempRotBarSelection = RB_UNSPECIFIED; + + /* Check if the system thread has already been created */ + if (SysThreadCreated) + { + /* Reset the progress bar */ + InbvAcquireLock(); + RotBarSelection = 0; + InbvReleaseLock(); + } + + /* Check if this is SOS mode */ + ShowProgressBar = FALSE; + if (SosMode) + { + /* Check if this is a server OS */ + if (SharedUserData->NtProductType == NtProductWinNt) + { + /* It's not, set workstation settings */ + InbvSetTextColor(15); + InbvSolidColorFill(0, 0, 639, 479, 7); + InbvSolidColorFill(0, 421, 639, 479, 1); + + /* Get resources */ + Bitmap = InbvGetResourceAddress(6); + Header = InbvGetResourceAddress(7); + } + else + { + /* Set server settings */ + InbvSetTextColor(14); + InbvSolidColorFill(0, 0, 639, 479, 6); + InbvSolidColorFill(0, 421, 639, 479, 1); + + /* Get resources */ + Bitmap = InbvGetResourceAddress(14); + Header = InbvGetResourceAddress(15); + } + + /* Set the scrolling region */ + InbvSetScrollRegion(32, 80, 631, 400); + + /* Make sure we have resources */ + if ((Bitmap) && (Header)) + { + /* BitBlt them on the screen */ + InbvBitBlt(Header, 0, 419); + InbvBitBlt(Bitmap, 0, 0); + } + } + else + { + /* Is the boot driver installed? */ + if (!InbvBootDriverInstalled) return; + + /* FIXME: TODO, display full-screen bitmap */ + } + + /* Do we have a system thread? */ + if (SysThreadCreated) + { + /* We do, set the progress bar location */ + InbvAcquireLock(); + RotBarSelection = TempRotBarSelection; + //InbvRotBarInit(); + InbvReleaseLock(); + } +} + +VOID +NTAPI +FinalizeBootLogo(VOID) +{ + /* Acquire lock and check the display state */ + InbvAcquireLock(); + if (InbvGetDisplayState() == INBV_DISPLAY_STATE_OWNED) + { + /* Clear the screen */ + VidSolidColorFill(0, 0, 639, 479, 0); + } + + /* Reset progress bar and lock */ + PltRotBarStatus = 3; + InbvReleaseLock(); +} diff --git a/reactos/ntoskrnl/inbv/logo/1.bmp b/reactos/ntoskrnl/inbv/logo/1.bmp index 45468ac901b..a2b59398aae 100644 Binary files a/reactos/ntoskrnl/inbv/logo/1.bmp and b/reactos/ntoskrnl/inbv/logo/1.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/13.bmp b/reactos/ntoskrnl/inbv/logo/13.bmp index 7bf3b541566..209227e9847 100644 Binary files a/reactos/ntoskrnl/inbv/logo/13.bmp and b/reactos/ntoskrnl/inbv/logo/13.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/14.bmp b/reactos/ntoskrnl/inbv/logo/14.bmp index 26502845e04..64439e9a245 100644 Binary files a/reactos/ntoskrnl/inbv/logo/14.bmp and b/reactos/ntoskrnl/inbv/logo/14.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/15.bmp b/reactos/ntoskrnl/inbv/logo/15.bmp index 4f5c9184b88..d137807c9f9 100644 Binary files a/reactos/ntoskrnl/inbv/logo/15.bmp and b/reactos/ntoskrnl/inbv/logo/15.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/16.bmp b/reactos/ntoskrnl/inbv/logo/16.bmp index 7bf3b541566..209227e9847 100644 Binary files a/reactos/ntoskrnl/inbv/logo/16.bmp and b/reactos/ntoskrnl/inbv/logo/16.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/17.bmp b/reactos/ntoskrnl/inbv/logo/17.bmp index 7bf3b541566..209227e9847 100644 Binary files a/reactos/ntoskrnl/inbv/logo/17.bmp and b/reactos/ntoskrnl/inbv/logo/17.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/2.bmp b/reactos/ntoskrnl/inbv/logo/2.bmp index 31cb36c9924..43984762c5f 100644 Binary files a/reactos/ntoskrnl/inbv/logo/2.bmp and b/reactos/ntoskrnl/inbv/logo/2.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/3.bmp b/reactos/ntoskrnl/inbv/logo/3.bmp index 6f48d5f18e0..7e95ca2b662 100644 Binary files a/reactos/ntoskrnl/inbv/logo/3.bmp and b/reactos/ntoskrnl/inbv/logo/3.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/4.bmp b/reactos/ntoskrnl/inbv/logo/4.bmp index 49474dcaf1c..239307b7d95 100644 Binary files a/reactos/ntoskrnl/inbv/logo/4.bmp and b/reactos/ntoskrnl/inbv/logo/4.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/5.bmp b/reactos/ntoskrnl/inbv/logo/5.bmp index 9dd3d9bd398..f0cce0e2fed 100644 Binary files a/reactos/ntoskrnl/inbv/logo/5.bmp and b/reactos/ntoskrnl/inbv/logo/5.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/6.bmp b/reactos/ntoskrnl/inbv/logo/6.bmp index 25048601f40..a8cafc569c0 100644 Binary files a/reactos/ntoskrnl/inbv/logo/6.bmp and b/reactos/ntoskrnl/inbv/logo/6.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/7.bmp b/reactos/ntoskrnl/inbv/logo/7.bmp index 4f5c9184b88..d137807c9f9 100644 Binary files a/reactos/ntoskrnl/inbv/logo/7.bmp and b/reactos/ntoskrnl/inbv/logo/7.bmp differ diff --git a/reactos/ntoskrnl/inbv/logo/8.bmp b/reactos/ntoskrnl/inbv/logo/8.bmp index 49474dcaf1c..239307b7d95 100644 Binary files a/reactos/ntoskrnl/inbv/logo/8.bmp and b/reactos/ntoskrnl/inbv/logo/8.bmp differ diff --git a/reactos/ntoskrnl/include/internal/inbv.h b/reactos/ntoskrnl/include/internal/inbv.h index ffdd818e236..02453e77251 100644 --- a/reactos/ntoskrnl/include/internal/inbv.h +++ b/reactos/ntoskrnl/include/internal/inbv.h @@ -8,6 +8,12 @@ typedef struct _InbvProgressState ULONG Bias; } INBV_PROGRESS_STATE; +typedef enum _ROT_BAR_TYPE +{ + RB_UNSPECIFIED, + RB_SQUARE_CELLS +} ROT_BAR_TYPE; + VOID NTAPI InbvUpdateProgressBar( @@ -27,6 +33,18 @@ InbvEnableBootDriver( IN BOOLEAN Enable ); +VOID +NTAPI +DisplayBootBitmap( + IN BOOLEAN SosMode +); + +VOID +NTAPI +FinalizeBootLogo( + VOID +); + #endif /* NTOSKRNL_INBV_H */