]> git.proxmox.com Git - mirror_edk2.git/blame - OptionRomPkg/Include/Library/BltLib.h
update copyright line format
[mirror_edk2.git] / OptionRomPkg / Include / Library / BltLib.h
CommitLineData
caebd915 1/** @file\r
2 Library for performing video blt operations\r
3\r
98208ad3
HT
4 Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>\r
5 This program and the accompanying materials\r
caebd915 6 are licensed and made available under the terms and conditions of the BSD License\r
7 which accompanies this distribution. The full text of the license may be found at\r
8 http://opensource.org/licenses/bsd-license.php\r
9\r
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
12\r
13**/\r
14\r
15#ifndef __BLT_LIB__\r
16#define __BLT_LIB__\r
17\r
18#include <Protocol/GraphicsOutput.h>\r
19\r
20\r
21/**\r
22 Configure the BltLib for a frame-buffer\r
23\r
24 @param[in] FrameBuffer Pointer to the start of the frame buffer\r
25 @param[in] FrameBufferInfo Describes the frame buffer characteristics\r
26\r
27 @retval EFI_INVALID_PARAMETER - Invalid parameter passed in\r
28 @retval EFI_SUCCESS - Blt operation success\r
29\r
30**/\r
31EFI_STATUS\r
32EFIAPI\r
33BltLibConfigure (\r
34 IN VOID *FrameBuffer,\r
35 IN EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *FrameBufferInfo\r
36 );\r
37\r
38\r
39/**\r
40 Performs a UEFI Graphics Output Protocol Blt operation.\r
41\r
42 @param[in,out] BltBuffer - The data to transfer to screen\r
43 @param[in] BltOperation - The operation to perform\r
44 @param[in] SourceX - The X coordinate of the source for BltOperation\r
45 @param[in] SourceY - The Y coordinate of the source for BltOperation\r
46 @param[in] DestinationX - The X coordinate of the destination for BltOperation\r
47 @param[in] DestinationY - The Y coordinate of the destination for BltOperation\r
48 @param[in] Width - The width of a rectangle in the blt rectangle in pixels\r
49 @param[in] Height - The height of a rectangle in the blt rectangle in pixels\r
50 @param[in] Delta - Not used for EfiBltVideoFill and EfiBltVideoToVideo operation.\r
51 If a Delta of 0 is used, the entire BltBuffer will be operated on.\r
52 If a subrectangle of the BltBuffer is used, then Delta represents\r
53 the number of bytes in a row of the BltBuffer.\r
54\r
55 @retval EFI_DEVICE_ERROR - A hardware error occured\r
56 @retval EFI_INVALID_PARAMETER - Invalid parameter passed in\r
57 @retval EFI_SUCCESS - Blt operation success\r
58\r
59**/\r
60EFI_STATUS\r
61EFIAPI\r
62BltLibGopBlt (\r
63 IN OUT EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer, OPTIONAL\r
64 IN EFI_GRAPHICS_OUTPUT_BLT_OPERATION BltOperation,\r
65 IN UINTN SourceX,\r
66 IN UINTN SourceY,\r
67 IN UINTN DestinationX,\r
68 IN UINTN DestinationY,\r
69 IN UINTN Width,\r
70 IN UINTN Height,\r
71 IN UINTN Delta\r
72 );\r
73\r
74\r
75/**\r
76 Performs a UEFI Graphics Output Protocol Blt Video Fill.\r
77\r
78 @param[in] Color Color to fill the region with\r
79 @param[in] DestinationX X location to start fill operation\r
80 @param[in] DestinationY Y location to start fill operation\r
81 @param[in] Width Width (in pixels) to fill\r
82 @param[in] Height Height to fill\r
83\r
84 @retval EFI_DEVICE_ERROR - A hardware error occured\r
85 @retval EFI_INVALID_PARAMETER - Invalid parameter passed in\r
86 @retval EFI_SUCCESS - Blt operation success\r
87\r
88**/\r
89EFI_STATUS\r
90EFIAPI\r
91BltLibVideoFill (\r
92 IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL *Color,\r
93 IN UINTN DestinationX,\r
94 IN UINTN DestinationY,\r
95 IN UINTN Width,\r
96 IN UINTN Height\r
97 );\r
98\r
99\r
100/**\r
101 Performs a UEFI Graphics Output Protocol Blt Video to Buffer operation.\r
102\r
103 @param[out] BltBuffer Output buffer for pixel color data\r
104 @param[in] SourceX X location within video\r
105 @param[in] SourceY Y location within video\r
106 @param[in] Width Width (in pixels)\r
107 @param[in] Height Height\r
108\r
109 @retval EFI_DEVICE_ERROR - A hardware error occured\r
110 @retval EFI_INVALID_PARAMETER - Invalid parameter passed in\r
111 @retval EFI_SUCCESS - Blt operation success\r
112\r
113**/\r
114EFI_STATUS\r
115EFIAPI\r
116BltLibVideoToBltBuffer (\r
117 OUT EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer,\r
118 IN UINTN SourceX,\r
119 IN UINTN SourceY,\r
120 IN UINTN Width,\r
121 IN UINTN Height\r
122 );\r
123\r
124\r
125/**\r
126 Performs a UEFI Graphics Output Protocol Blt Video to Buffer operation\r
127 with extended parameters.\r
128\r
129 @param[out] BltBuffer Output buffer for pixel color data\r
130 @param[in] SourceX X location within video\r
131 @param[in] SourceY Y location within video\r
132 @param[in] DestinationX X location within BltBuffer\r
133 @param[in] DestinationY Y location within BltBuffer\r
134 @param[in] Width Width (in pixels)\r
135 @param[in] Height Height\r
136 @param[in] Delta Number of bytes in a row of BltBuffer\r
137\r
138 @retval EFI_DEVICE_ERROR - A hardware error occured\r
139 @retval EFI_INVALID_PARAMETER - Invalid parameter passed in\r
140 @retval EFI_SUCCESS - Blt operation success\r
141\r
142**/\r
143EFI_STATUS\r
144EFIAPI\r
145BltLibVideoToBltBufferEx (\r
146 OUT EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer,\r
147 IN UINTN SourceX,\r
148 IN UINTN SourceY,\r
149 IN UINTN DestinationX,\r
150 IN UINTN DestinationY,\r
151 IN UINTN Width,\r
152 IN UINTN Height,\r
153 IN UINTN Delta\r
154 );\r
155\r
156\r
157/**\r
158 Performs a UEFI Graphics Output Protocol Blt Buffer to Video operation.\r
159\r
160 @param[in] BltBuffer Output buffer for pixel color data\r
161 @param[in] DestinationX X location within video\r
162 @param[in] DestinationY Y location within video\r
163 @param[in] Width Width (in pixels)\r
164 @param[in] Height Height\r
165\r
166 @retval EFI_DEVICE_ERROR - A hardware error occured\r
167 @retval EFI_INVALID_PARAMETER - Invalid parameter passed in\r
168 @retval EFI_SUCCESS - Blt operation success\r
169\r
170**/\r
171EFI_STATUS\r
172EFIAPI\r
173BltLibBufferToVideo (\r
174 IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer,\r
175 IN UINTN DestinationX,\r
176 IN UINTN DestinationY,\r
177 IN UINTN Width,\r
178 IN UINTN Height\r
179 );\r
180\r
181\r
182/**\r
183 Performs a UEFI Graphics Output Protocol Blt Buffer to Video operation\r
184 with extended parameters.\r
185\r
186 @param[in] BltBuffer Output buffer for pixel color data\r
187 @param[in] SourceX X location within BltBuffer\r
188 @param[in] SourceY Y location within BltBuffer\r
189 @param[in] DestinationX X location within video\r
190 @param[in] DestinationY Y location within video\r
191 @param[in] Width Width (in pixels)\r
192 @param[in] Height Height\r
193 @param[in] Delta Number of bytes in a row of BltBuffer\r
194\r
195 @retval EFI_DEVICE_ERROR - A hardware error occured\r
196 @retval EFI_INVALID_PARAMETER - Invalid parameter passed in\r
197 @retval EFI_SUCCESS - Blt operation success\r
198\r
199**/\r
200EFI_STATUS\r
201EFIAPI\r
202BltLibBufferToVideoEx (\r
203 IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer,\r
204 IN UINTN SourceX,\r
205 IN UINTN SourceY,\r
206 IN UINTN DestinationX,\r
207 IN UINTN DestinationY,\r
208 IN UINTN Width,\r
209 IN UINTN Height,\r
210 IN UINTN Delta\r
211 );\r
212\r
213\r
214/**\r
215 Performs a UEFI Graphics Output Protocol Blt Video to Video operation\r
216\r
217 @param[in] SourceX X location within video\r
218 @param[in] SourceY Y location within video\r
219 @param[in] DestinationX X location within video\r
220 @param[in] DestinationY Y location within video\r
221 @param[in] Width Width (in pixels)\r
222 @param[in] Height Height\r
223\r
224 @retval EFI_DEVICE_ERROR - A hardware error occured\r
225 @retval EFI_INVALID_PARAMETER - Invalid parameter passed in\r
226 @retval EFI_SUCCESS - Blt operation success\r
227\r
228**/\r
229EFI_STATUS\r
230EFIAPI\r
231BltLibVideoToVideo (\r
232 IN UINTN SourceX,\r
233 IN UINTN SourceY,\r
234 IN UINTN DestinationX,\r
235 IN UINTN DestinationY,\r
236 IN UINTN Width,\r
237 IN UINTN Height\r
238 );\r
239\r
240\r
241/**\r
242 Returns the sizes related to the video device\r
243\r
244 @param[out] Width Width (in pixels)\r
245 @param[out] Height Height (in pixels)\r
246\r
247 @retval EFI_INVALID_PARAMETER - Invalid parameter passed in\r
248 @retval EFI_SUCCESS - The sizes were returned\r
249\r
250**/\r
251EFI_STATUS\r
252EFIAPI\r
253BltLibGetSizes (\r
254 OUT UINTN *Width, OPTIONAL\r
255 OUT UINTN *Height OPTIONAL\r
256 );\r
257\r
258#endif\r
259\r