PrintScreenLogger¶
About¶
PrintScreenLogger is a DXE_DRIVER you can include in your platform to obtain Screen Captures during the preboot environment by pressing the Ctrl-PrtScn key combination. This action will creates a 24bbp (Bits Per Pixel) .BMP file of the screen's contents and write it to a enabled USB drive.
Supported Architectures¶
This package is not architecturally dependent. This package is dependent upon the Gop pixel format, and only supports these two pixel formats:
- PixelRedGreenBlueReserved8BitPerColor
- PixelBlueGreenRedReserved8BitPerColor
PrintScreenLogger operation¶
During initialization, the Print Screen Logger registers for notification of the Ctrl-PrtScn key combination is pressed.
When a Print Screen callback occurs:
- Looks for a mounted USB drive that contains a file in the root directory called PrintScreenEnable.txt. This limits PrintScreenLogger to only write to enabled USB devices.
- Looks for the next available filename in the form PrtScreen####.bmp, starting with 0000.
- Creates the new PrtScreen####.bmp file.
- Call GraphicsOutput->Blt to obtain the complete screen.
- Converts the BLT buffer to a 24bbp BMP structure.
- Writes the BMP structure to the new PrtScreen####.bmp file.
Including in your platform¶
Sample DSC change¶
[Components.<arch>]
...
...
MsGraphicsPkg/PrintScreenLogger/PrintScreenLogger.inf
Sample FDF change¶
[FV.<a DXE firmware volume>]
...
...
INF MsGraphicsPkg/PrintScreenLogger/PrintScreenLogger.inf
Copyright¶
Copyright (C) Microsoft Corporation. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent