]> Git Repo - J-u-boot.git/blame - include/bmp_layout.h
arm: kirkwood: Enable bootstd for Sheevaplug board
[J-u-boot.git] / include / bmp_layout.h
CommitLineData
83d290c5 1/* SPDX-License-Identifier: GPL-2.0+ */
059ae173
WD
2/* (C) Copyright 2002
3 * Detlev Zundel, DENX Software Engineering, [email protected].
059ae173
WD
4 */
5
6/************************************************************************/
7/* ** Layout of a bmp file */
8/************************************************************************/
9
10#ifndef _BMP_H_
11#define _BMP_H_
12
03de305e
TR
13#include <linux/compiler.h>
14
1c3dbe56 15struct __packed bmp_color_table_entry {
27b207fd
WD
16 __u8 blue;
17 __u8 green;
18 __u8 red;
19 __u8 reserved;
1c3dbe56 20};
059ae173
WD
21
22/* When accessing these fields, remember that they are stored in little
23 endian format, so use linux macros, e.g. le32_to_cpu(width) */
24
1c3dbe56 25struct __packed bmp_header {
27b207fd
WD
26 /* Header */
27 char signature[2];
28 __u32 file_size;
29 __u32 reserved;
30 __u32 data_offset;
31 /* InfoHeader */
32 __u32 size;
33 __u32 width;
34 __u32 height;
35 __u16 planes;
36 __u16 bit_count;
37 __u32 compression;
38 __u32 image_size;
39 __u32 x_pixels_per_m;
40 __u32 y_pixels_per_m;
41 __u32 colors_used;
42 __u32 colors_important;
43 /* ColorTable */
1c3dbe56 44};
8bde7f77 45
1c3dbe56
SG
46struct bmp_image {
47 struct bmp_header header;
27b207fd
WD
48 /* We use a zero sized array just as a placeholder for variable
49 sized array */
1c3dbe56
SG
50 struct bmp_color_table_entry color_table[0];
51};
059ae173
WD
52
53/* Data in the bmp_image is aligned to this length */
27b207fd 54#define BMP_DATA_ALIGN 4
059ae173
WD
55
56/* Constants for the compression field */
27b207fd
WD
57#define BMP_BI_RGB 0
58#define BMP_BI_RLE8 1
59#define BMP_BI_RLE4 2
059ae173 60
27b207fd 61#endif /* _BMP_H_ */
This page took 0.669976 seconds and 4 git commands to generate.