3 Copyright (c) 2004 - 2006, Intel Corporation. All rights reserved.<BR>
4 This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
21 #ifndef _EFI_GRAPHICS_LIB_H_
22 #define _EFI_GRAPHICS_LIB_H_
24 #include EFI_PROTOCOL_DEFINITION (ConsoleControl)
25 #include EFI_PROTOCOL_DEFINITION (FirmwareVolume)
26 #include EFI_PROTOCOL_DEFINITION (FirmwareVolume2)
27 #include EFI_PROTOCOL_DEFINITION (GraphicsOutput)
28 #include EFI_PROTOCOL_DEFINITION (UgaDraw)
29 #include EFI_PROTOCOL_DEFINITION (EfiOemBadging)
31 #include EFI_GUID_DEFINITION (Bmp)
34 GetGraphicsBitMapFromFV (
35 IN EFI_GUID
*FileNameGuid
,
43 Return the graphics image file named FileNameGuid into Image and return it's
44 size in ImageSize. All Firmware Volumes (FV) in the system are searched for the
49 FileNameGuid - File Name of graphics file in the FV(s).
51 Image - Pointer to pointer to return graphics image. If NULL, a
52 buffer will be allocated.
54 ImageSize - Size of the graphics Image in bytes. Zero if no image found.
59 EFI_SUCCESS - Image and ImageSize are valid.
60 EFI_BUFFER_TOO_SMALL - Image not big enough. ImageSize has required size
61 EFI_NOT_FOUND - FileNameGuid not found
67 GetGraphicsBitMapFromFVEx (
68 IN EFI_HANDLE ImageHandle
,
69 IN EFI_GUID
*FileNameGuid
,
77 Return the graphics image file named FileNameGuid into Image and return it's
78 size in ImageSize. All Firmware Volumes (FV) in the system are searched for the
83 ImageHandle - The driver image handle of the caller. The parameter is used to
84 optimize the loading of the image file so that the FV from which
85 the driver image is loaded will be tried first.
87 FileNameGuid - File Name of graphics file in the FV(s).
89 Image - Pointer to pointer to return graphics image. If NULL, a
90 buffer will be allocated.
92 ImageSize - Size of the graphics Image in bytes. Zero if no image found.
97 EFI_SUCCESS - Image and ImageSize are valid.
98 EFI_BUFFER_TOO_SMALL - Image not big enough. ImageSize has required size
99 EFI_NOT_FOUND - FileNameGuid not found
108 IN UINTN BmpImageSize
,
109 IN OUT VOID
**GopBlt
,
110 IN OUT UINTN
*GopBltSize
,
111 OUT UINTN
*PixelHeight
,
112 OUT UINTN
*PixelWidth
118 Convert a *.BMP graphics image to a GOP/UGA blt buffer. If a NULL Blt buffer
119 is passed in a GopBlt buffer will be allocated by this routine. If a GopBlt
120 buffer is passed in it will be used if it is big enough.
124 BmpImage - Pointer to BMP file
126 BmpImageSize - Number of bytes in BmpImage
128 GopBlt - Buffer containing GOP version of BmpImage.
130 GopBltSize - Size of GopBlt in bytes.
132 PixelHeight - Height of GopBlt/BmpImage in pixels
134 PixelWidth - Width of GopBlt/BmpImage in pixels
139 EFI_SUCCESS - GopBlt and GopBltSize are returned.
140 EFI_UNSUPPORTED - BmpImage is not a valid *.BMP image
141 EFI_BUFFER_TOO_SMALL - The passed in GopBlt buffer is not big enough.
142 GopBltSize will contain the required size.
143 EFI_OUT_OF_RESOURCES - No enough buffer to allocate
150 IN EFI_GUID
*LogoFile
156 Use Console Control to turn off UGA based Simple Text Out consoles from going
157 to the UGA device. Put up LogoFile on every UGA device that is a console
161 LogoFile - File name of logo to display on the center of the screen.
166 EFI_SUCCESS - ConsoleControl has been flipped to graphics and logo
168 EFI_UNSUPPORTED - Logo not found
175 IN EFI_GUID
*LogoFile
,
176 IN EFI_HANDLE ImageHandle
182 Use Console Control to turn off UGA based Simple Text Out consoles from going
183 to the UGA device. Put up LogoFile on every UGA device that is a console
187 LogoFile - File name of logo to display on the center of the screen.
188 ImageHandle - The driver image handle of the caller. The parameter is used to
189 optimize the loading of the logo file so that the FV from which
190 the driver image is loaded will be tried first.
195 EFI_SUCCESS - ConsoleControl has been flipped to graphics and logo
197 EFI_UNSUPPORTED - Logo not found
210 Use Console Control to turn on UGA based Simple Text Out consoles. The UGA
211 Simple Text Out screens will now be synced up with all non UGA output devices
219 EFI_SUCCESS - UGA devices are back in text mode and synced up.
220 EFI_UNSUPPORTED - Logo not found
232 Use Console Control Protocol to lock the Console In Spliter virtual handle.
233 This is the ConInHandle and ConIn handle in the EFI system table. All key
234 presses will be ignored until the Password is typed in. The only way to
235 disable the password is to type it in to a ConIn device.
238 Password - Password used to lock ConIn device
243 EFI_SUCCESS - ConsoleControl has been flipped to graphics and logo
245 EFI_UNSUPPORTED - Logo not found