xref: /haiku/headers/os/interface/GraphicsDefs.h (revision 9931e8eeeebf00f45574b8f2e3257ec56d33860f)
16ec21b4aSAxel Dörfler /*
27f9368caSlooncraz  * Copyright 2008-2015 Haiku, Inc. All rights reserved.
36ec21b4aSAxel Dörfler  * Distributed under the terms of the MIT License.
46ec21b4aSAxel Dörfler  */
552a38012Sejakowatz #ifndef _GRAPHICS_DEFS_H
652a38012Sejakowatz #define _GRAPHICS_DEFS_H
752a38012Sejakowatz 
852a38012Sejakowatz 
952a38012Sejakowatz #include <SupportDefs.h>
1052a38012Sejakowatz 
1152a38012Sejakowatz 
126ec21b4aSAxel Dörfler // Pattern
1352a38012Sejakowatz typedef struct pattern {
1452a38012Sejakowatz 	uint8 data[8];
1552a38012Sejakowatz } pattern;
1652a38012Sejakowatz 
1709852109SStephan Aßmus 
1869001466SAlexander von Gluck IV #ifdef __cplusplus
1909852109SStephan Aßmus inline bool
2009852109SStephan Aßmus operator==(const pattern& a, const pattern& b)
2109852109SStephan Aßmus {
22764c402aSAugustin Cavalier 	uint64* pa = (uint64*)a.data;
23764c402aSAugustin Cavalier 	uint64* pb = (uint64*)b.data;
24764c402aSAugustin Cavalier 	return (*pa == *pb);
2509852109SStephan Aßmus }
2609852109SStephan Aßmus 
2769001466SAlexander von Gluck IV 
28758b1d0eSIngo Weinhold inline bool
29758b1d0eSIngo Weinhold operator!=(const pattern& a, const pattern& b)
30758b1d0eSIngo Weinhold {
31758b1d0eSIngo Weinhold 	return !(a == b);
32758b1d0eSIngo Weinhold }
3309852109SStephan Aßmus #endif // __cplusplus
3409852109SStephan Aßmus 
3569001466SAlexander von Gluck IV 
36f6e4cbb9SAxel Dörfler extern const pattern B_SOLID_HIGH;
37f6e4cbb9SAxel Dörfler extern const pattern B_MIXED_COLORS;
38f6e4cbb9SAxel Dörfler extern const pattern B_SOLID_LOW;
3952a38012Sejakowatz 
406ec21b4aSAxel Dörfler 
416ec21b4aSAxel Dörfler // rgb_color
4252a38012Sejakowatz typedef struct rgb_color {
4352a38012Sejakowatz 	uint8		red;
4452a38012Sejakowatz 	uint8		green;
4552a38012Sejakowatz 	uint8		blue;
4652a38012Sejakowatz 	uint8		alpha;
479551dd1cSAxel Dörfler 
489551dd1cSAxel Dörfler #if defined(__cplusplus)
499551dd1cSAxel Dörfler 	// some convenient additions
50cd0ea6ffSAxel Dörfler 	inline rgb_color&
51cd0ea6ffSAxel Dörfler 	set_to(uint8 r, uint8 g, uint8 b, uint8 a = 255)
52cd0ea6ffSAxel Dörfler 	{
53cd0ea6ffSAxel Dörfler 		red = r;
54cd0ea6ffSAxel Dörfler 		green = g;
55cd0ea6ffSAxel Dörfler 		blue = b;
56cd0ea6ffSAxel Dörfler 		alpha = a;
57cd0ea6ffSAxel Dörfler 		return *this;
58cd0ea6ffSAxel Dörfler 	}
59cd0ea6ffSAxel Dörfler 
607f9368caSlooncraz 	int32 Brightness() const;
617f9368caSlooncraz 
629551dd1cSAxel Dörfler 	inline bool
IsDarkrgb_color63*9931e8eeSnep 	IsDark() const
64*9931e8eeSnep 	{
65*9931e8eeSnep 		return Brightness() <= 127;
66*9931e8eeSnep 	}
67*9931e8eeSnep 
68*9931e8eeSnep 	inline bool
IsLightrgb_color69*9931e8eeSnep 	IsLight() const
70*9931e8eeSnep 	{
71*9931e8eeSnep 		return Brightness() > 127;
72*9931e8eeSnep 	}
73*9931e8eeSnep 
74*9931e8eeSnep 	static inline int32
Contrastrgb_color75*9931e8eeSnep 	Contrast(rgb_color colorA, rgb_color colorB)
76*9931e8eeSnep 	{
77*9931e8eeSnep 		int32 contrast = colorA.Brightness() - colorB.Brightness();
78*9931e8eeSnep 		if (contrast < 0)
79*9931e8eeSnep 			return -contrast;
80*9931e8eeSnep 
81*9931e8eeSnep 		return contrast;
82*9931e8eeSnep 	}
83*9931e8eeSnep 
84*9931e8eeSnep 	inline bool
859551dd1cSAxel Dörfler 	operator==(const rgb_color& other) const
869551dd1cSAxel Dörfler 	{
87764c402aSAugustin Cavalier 		return *(const uint32 *)this == *(const uint32 *)&other;
889551dd1cSAxel Dörfler 	}
899551dd1cSAxel Dörfler 
909551dd1cSAxel Dörfler 	inline bool
919551dd1cSAxel Dörfler 	operator!=(const rgb_color& other) const
929551dd1cSAxel Dörfler 	{
93764c402aSAugustin Cavalier 		return *(const uint32 *)this != *(const uint32 *)&other;
949551dd1cSAxel Dörfler 	}
95f6d52cb7SRene Gollent 
96f6d52cb7SRene Gollent 	inline rgb_color&
97f6d52cb7SRene Gollent 	operator=(const rgb_color& other)
98f6d52cb7SRene Gollent 	{
99f6d52cb7SRene Gollent 		return set_to(other.red, other.green, other.blue, other.alpha);
100f6d52cb7SRene Gollent 	}
1019551dd1cSAxel Dörfler #endif
10252a38012Sejakowatz } rgb_color;
10352a38012Sejakowatz 
10469001466SAlexander von Gluck IV 
105cd0ea6ffSAxel Dörfler #if defined(__cplusplus)
106cd0ea6ffSAxel Dörfler inline rgb_color
107cd0ea6ffSAxel Dörfler make_color(uint8 red, uint8 green, uint8 blue, uint8 alpha = 255)
108cd0ea6ffSAxel Dörfler {
109cd0ea6ffSAxel Dörfler 	rgb_color color = {red, green, blue, alpha};
110cd0ea6ffSAxel Dörfler 	return color;
111cd0ea6ffSAxel Dörfler }
112cd0ea6ffSAxel Dörfler #endif
113cd0ea6ffSAxel Dörfler 
11469001466SAlexander von Gluck IV 
1157f9368caSlooncraz rgb_color mix_color(rgb_color color1, rgb_color color2, uint8 amount);
1167f9368caSlooncraz rgb_color blend_color(rgb_color color1, rgb_color color2, uint8 amount);
1177f9368caSlooncraz rgb_color disable_color(rgb_color color, rgb_color background);
1187f9368caSlooncraz 
1197f9368caSlooncraz 
120f6e4cbb9SAxel Dörfler extern const rgb_color 	B_TRANSPARENT_COLOR;
121f6e4cbb9SAxel Dörfler extern const uint8		B_TRANSPARENT_MAGIC_CMAP8;
122f6e4cbb9SAxel Dörfler extern const uint16		B_TRANSPARENT_MAGIC_RGBA15;
123f6e4cbb9SAxel Dörfler extern const uint16		B_TRANSPARENT_MAGIC_RGBA15_BIG;
124f6e4cbb9SAxel Dörfler extern const uint32		B_TRANSPARENT_MAGIC_RGBA32;
125f6e4cbb9SAxel Dörfler extern const uint32		B_TRANSPARENT_MAGIC_RGBA32_BIG;
126f6e4cbb9SAxel Dörfler extern const uint8 		B_TRANSPARENT_8_BIT;
127f6e4cbb9SAxel Dörfler extern const rgb_color	B_TRANSPARENT_32_BIT;
12852a38012Sejakowatz 
1296ec21b4aSAxel Dörfler 
1306ec21b4aSAxel Dörfler // color map
13152a38012Sejakowatz typedef struct color_map {
13252a38012Sejakowatz 	int32				id;
13352a38012Sejakowatz 	rgb_color			color_list[256];
13452a38012Sejakowatz 	uint8				inversion_map[256];
13552a38012Sejakowatz 	uint8				index_map[32768];
13652a38012Sejakowatz } color_map;
13752a38012Sejakowatz 
1386ec21b4aSAxel Dörfler 
1396ec21b4aSAxel Dörfler // overlay
14052a38012Sejakowatz typedef struct overlay_rect_limits {
14152a38012Sejakowatz 	uint16				horizontal_alignment;
14252a38012Sejakowatz 	uint16				vertical_alignment;
14352a38012Sejakowatz 	uint16				width_alignment;
14452a38012Sejakowatz 	uint16				height_alignment;
14552a38012Sejakowatz 	uint16				min_width;
14652a38012Sejakowatz 	uint16				max_width;
14752a38012Sejakowatz 	uint16				min_height;
14852a38012Sejakowatz 	uint16				max_height;
14952a38012Sejakowatz 	uint32				reserved[8];
15052a38012Sejakowatz } overlay_rect_limits;
15152a38012Sejakowatz 
15269001466SAlexander von Gluck IV 
15352a38012Sejakowatz typedef struct overlay_restrictions {
15452a38012Sejakowatz 	overlay_rect_limits	source;
15552a38012Sejakowatz 	overlay_rect_limits	destination;
15652a38012Sejakowatz 	float				min_width_scale;
15752a38012Sejakowatz 	float				max_width_scale;
15852a38012Sejakowatz 	float				min_height_scale;
15952a38012Sejakowatz 	float				max_height_scale;
16052a38012Sejakowatz 	uint32				reserved[8];
16152a38012Sejakowatz } overlay_restrictions;
16252a38012Sejakowatz 
1636ec21b4aSAxel Dörfler 
16469001466SAlexander von Gluck IV // Screen ID
16552a38012Sejakowatz struct screen_id { int32 id; };
166f6e4cbb9SAxel Dörfler extern const struct screen_id B_MAIN_SCREEN_ID;
16752a38012Sejakowatz 
16852a38012Sejakowatz 
16969001466SAlexander von Gluck IV // Color spaces
1706ec21b4aSAxel Dörfler typedef enum {
1716ec21b4aSAxel Dörfler 	B_NO_COLOR_SPACE	= 0x0000,
17252a38012Sejakowatz 
1736ec21b4aSAxel Dörfler 	// linear color space (little endian)
174bb187c91SJérôme Duval 	B_RGBA64			= 0x2012,	// RGBA		RGBA 16:16:16:16
175bb187c91SJérôme Duval 	B_RGB48				= 0x0011,	// RGB		 RGB 16:16:16
17669001466SAlexander von Gluck IV 	B_RGB32				= 0x0008,	// BGR-		-RGB 8:8:8:8
17769001466SAlexander von Gluck IV 	B_RGBA32			= 0x2008,	// BGRA		ARGB 8:8:8:8
17869001466SAlexander von Gluck IV 	B_RGB24				= 0x0003,	// BGR		 RGB 8:8:8
17969001466SAlexander von Gluck IV 	B_RGB16				= 0x0005,	// BGR		 RGB 5:6:5
18069001466SAlexander von Gluck IV 	B_RGB15				= 0x0010,	// BGR-		-RGB 1:5:5:5
18169001466SAlexander von Gluck IV 	B_RGBA15			= 0x2010,	// BGRA		ARGB 1:5:5:5
18269001466SAlexander von Gluck IV 	B_CMAP8				= 0x0004,	// 256 color index table
18369001466SAlexander von Gluck IV 	B_GRAY8				= 0x0002,	// 256 greyscale table
18469001466SAlexander von Gluck IV 	B_GRAY1				= 0x0001,	// Each bit represents a single pixel
18552a38012Sejakowatz 
18669001466SAlexander von Gluck IV 	// linear color space (big endian)
187bb187c91SJérôme Duval 	B_RGBA64_BIG		= 0x3012,	// RGBA		RGBA 16:16:16:16
188bb187c91SJérôme Duval 	B_RGB48_BIG			= 0x1011,	//  RGB		RGB  16:16:16
18969001466SAlexander von Gluck IV 	B_RGB32_BIG			= 0x1008,	// -RGB		BGR- 8:8:8:8
19069001466SAlexander von Gluck IV 	B_RGBA32_BIG		= 0x3008,	// ARGB		BGRA 8:8:8:8
19169001466SAlexander von Gluck IV 	B_RGB24_BIG			= 0x1003,	//  RGB		BGR  8:8:8
19269001466SAlexander von Gluck IV 	B_RGB16_BIG			= 0x1005,	//  RGB		BGR  5:6:5
19369001466SAlexander von Gluck IV 	B_RGB15_BIG			= 0x1010,	// -RGB		BGR- 5:5:5:1
19469001466SAlexander von Gluck IV 	B_RGBA15_BIG		= 0x3010,	// ARGB		BGRA 5:5:5:1
1956ec21b4aSAxel Dörfler 
19669001466SAlexander von Gluck IV 	// linear color space (little endian, for completeness)
197bb187c91SJérôme Duval 	B_RGBA64_LITTLE		= B_RGBA64,
198bb187c91SJérôme Duval 	B_RGB48_LITTLE		= B_RGB48,
19952a38012Sejakowatz 	B_RGB32_LITTLE		= B_RGB32,
20052a38012Sejakowatz 	B_RGBA32_LITTLE		= B_RGBA32,
20152a38012Sejakowatz 	B_RGB24_LITTLE		= B_RGB24,
20252a38012Sejakowatz 	B_RGB16_LITTLE		= B_RGB16,
20352a38012Sejakowatz 	B_RGB15_LITTLE		= B_RGB15,
20452a38012Sejakowatz 	B_RGBA15_LITTLE		= B_RGBA15,
20552a38012Sejakowatz 
2066ec21b4aSAxel Dörfler 	// non linear color space -- incidently, all with 8 bits per value
2076ec21b4aSAxel Dörfler 	// Note, BBitmap and BView do not support all of these!
20852a38012Sejakowatz 
20969001466SAlexander von Gluck IV 	// Loss / saturation points:
21069001466SAlexander von Gluck IV 	//  Y		16 - 235 (absolute)
21169001466SAlexander von Gluck IV 	//  Cb/Cr	16 - 240 (center 128)
21252a38012Sejakowatz 
21369001466SAlexander von Gluck IV 	B_YCbCr422			= 0x4000,	// Y0  Cb0 Y1  Cr0
21469001466SAlexander von Gluck IV 									// Y2  Cb2 Y3  Cr4
21569001466SAlexander von Gluck IV 	B_YCbCr411			= 0x4001,	// Cb0 Y0  Cr0 Y1
21669001466SAlexander von Gluck IV 									// Cb4 Y2  Cr4 Y3
21769001466SAlexander von Gluck IV 									// Y4  Y5  Y6  Y7
2186ec21b4aSAxel Dörfler 	B_YCbCr444			= 0x4003,	// Y   Cb  Cr
2196ec21b4aSAxel Dörfler 	B_YCbCr420			= 0x4004,	// Non-interlaced only
2206ec21b4aSAxel Dörfler 		// on even scan lines: Cb0  Y0  Y1  Cb2 Y2  Y3
2216ec21b4aSAxel Dörfler 		// on odd scan lines:  Cr0  Y0  Y1  Cr2 Y2  Y3
22252a38012Sejakowatz 
2236ec21b4aSAxel Dörfler 	// Extrema points are:
22452a38012Sejakowatz 	//  Y 0 - 207 (absolute)
22552a38012Sejakowatz 	//  U -91 - 91 (offset 128)
22652a38012Sejakowatz 	//  V -127 - 127 (offset 128)
22752a38012Sejakowatz 
2286ec21b4aSAxel Dörfler 	// Note that YUV byte order is different from YCbCr; use YCbCr, not YUV,
2296ec21b4aSAxel Dörfler 	// when that's what you mean!
23069001466SAlexander von Gluck IV 	B_YUV422			= 0x4020,	// U0  Y0  V0  Y1
23169001466SAlexander von Gluck IV 									// U2  Y2  V2  Y3
23269001466SAlexander von Gluck IV 	B_YUV411			= 0x4021,	// U0  Y0  Y1  V0  Y2  Y3
23369001466SAlexander von Gluck IV 									// U4  Y4  Y5  V4  Y6  Y7
2346ec21b4aSAxel Dörfler 	B_YUV444			= 0x4023,	// U0  Y0  V0  U1  Y1  V1
2356ec21b4aSAxel Dörfler 	B_YUV420			= 0x4024,	// Non-interlaced only
2366ec21b4aSAxel Dörfler 		// on even scan lines: U0  Y0  Y1  U2 Y2  Y3
2376ec21b4aSAxel Dörfler 		// on odd scan lines:  V0  Y0  Y1  V2 Y2  Y3
2386ec21b4aSAxel Dörfler 	B_YUV9				= 0x402C,
2396ec21b4aSAxel Dörfler 	B_YUV12				= 0x402D,
24052a38012Sejakowatz 
2416ec21b4aSAxel Dörfler 	B_UVL24				= 0x4030,	// UVL
2426ec21b4aSAxel Dörfler 	B_UVL32				= 0x4031,	// UVL-
2436ec21b4aSAxel Dörfler 	B_UVLA32			= 0x6031,	// UVLA
24452a38012Sejakowatz 
2456ec21b4aSAxel Dörfler 	// L lightness, a/b color-opponent dimensions
2466ec21b4aSAxel Dörfler 	B_LAB24				= 0x4032,	// Lab
2476ec21b4aSAxel Dörfler 	B_LAB32				= 0x4033,	// Lab-
2486ec21b4aSAxel Dörfler 	B_LABA32			= 0x6033,	// LabA
24952a38012Sejakowatz 
2506ec21b4aSAxel Dörfler 	// Red is at hue 0
2516ec21b4aSAxel Dörfler 	B_HSI24				= 0x4040,	// HSI
2526ec21b4aSAxel Dörfler 	B_HSI32				= 0x4041,	// HSI-
2536ec21b4aSAxel Dörfler 	B_HSIA32			= 0x6041,	// HSIA
25452a38012Sejakowatz 
2556ec21b4aSAxel Dörfler 	B_HSV24				= 0x4042,	// HSV
2566ec21b4aSAxel Dörfler 	B_HSV32				= 0x4043,	// HSV-
2576ec21b4aSAxel Dörfler 	B_HSVA32			= 0x6043,	// HSVA
25852a38012Sejakowatz 
2596ec21b4aSAxel Dörfler 	B_HLS24				= 0x4044,	// HLS
2606ec21b4aSAxel Dörfler 	B_HLS32				= 0x4045,	// HLS-
2616ec21b4aSAxel Dörfler 	B_HLSA32			= 0x6045,	// HLSA
26252a38012Sejakowatz 
2636ec21b4aSAxel Dörfler 	B_CMY24				= 0xC001,	// CMY
2646ec21b4aSAxel Dörfler 	B_CMY32				= 0xC002,	// CMY-
2656ec21b4aSAxel Dörfler 	B_CMYA32			= 0xE002,	// CMYA
2666ec21b4aSAxel Dörfler 	B_CMYK32			= 0xC003,	// CMYK
26752a38012Sejakowatz 
26869001466SAlexander von Gluck IV 	// Compatibility declarations
26952a38012Sejakowatz 	B_MONOCHROME_1_BIT	= B_GRAY1,
27052a38012Sejakowatz 	B_GRAYSCALE_8_BIT	= B_GRAY8,
27152a38012Sejakowatz 	B_COLOR_8_BIT		= B_CMAP8,
27252a38012Sejakowatz 	B_RGB_32_BIT		= B_RGB32,
27352a38012Sejakowatz 	B_RGB_16_BIT		= B_RGB15,
27452a38012Sejakowatz 	B_BIG_RGB_32_BIT	= B_RGB32_BIG,
27552a38012Sejakowatz 	B_BIG_RGB_16_BIT	= B_RGB15_BIG
27652a38012Sejakowatz } color_space;
27752a38012Sejakowatz 
27852a38012Sejakowatz 
2796ec21b4aSAxel Dörfler // Bitmap Support Flags
28052a38012Sejakowatz enum {
28152a38012Sejakowatz 	B_VIEWS_SUPPORT_DRAW_BITMAP			= 0x1,
2826ec21b4aSAxel Dörfler 	B_BITMAPS_SUPPORT_ATTACHED_VIEWS	= 0x2,
2836cd1b6f7SRene Gollent 	B_BITMAPS_SUPPORT_OVERLAY			= 0x4
28452a38012Sejakowatz };
28569001466SAlexander von Gluck IV 
28669001466SAlexander von Gluck IV 
2876ec21b4aSAxel Dörfler bool bitmaps_support_space(color_space space, uint32* _supportFlags);
28852a38012Sejakowatz 
28969001466SAlexander von Gluck IV 
2906ec21b4aSAxel Dörfler status_t get_pixel_size_for(color_space space, size_t* _pixelChunk,
2916ec21b4aSAxel Dörfler 	size_t* _rowAlignment, size_t* _pixelsPerChunk);
29252a38012Sejakowatz 
29352a38012Sejakowatz 
29452a38012Sejakowatz enum buffer_orientation {
29552a38012Sejakowatz 	B_BUFFER_TOP_TO_BOTTOM,
29652a38012Sejakowatz 	B_BUFFER_BOTTOM_TO_TOP
29752a38012Sejakowatz };
29852a38012Sejakowatz 
29969001466SAlexander von Gluck IV 
30052a38012Sejakowatz enum buffer_layout {
30152a38012Sejakowatz 	B_BUFFER_NONINTERLEAVED = 1
30252a38012Sejakowatz };
30352a38012Sejakowatz 
3046ec21b4aSAxel Dörfler 
3056ec21b4aSAxel Dörfler // Drawing Modes
30652a38012Sejakowatz enum drawing_mode {
30752a38012Sejakowatz 	B_OP_COPY,
30852a38012Sejakowatz 	B_OP_OVER,
30952a38012Sejakowatz 	B_OP_ERASE,
31052a38012Sejakowatz 	B_OP_INVERT,
31152a38012Sejakowatz 	B_OP_ADD,
31252a38012Sejakowatz 	B_OP_SUBTRACT,
31352a38012Sejakowatz 	B_OP_BLEND,
31452a38012Sejakowatz 	B_OP_MIN,
31552a38012Sejakowatz 	B_OP_MAX,
31652a38012Sejakowatz 	B_OP_SELECT,
31752a38012Sejakowatz 	B_OP_ALPHA
31852a38012Sejakowatz };
31952a38012Sejakowatz 
32069001466SAlexander von Gluck IV 
32152a38012Sejakowatz enum source_alpha {
32252a38012Sejakowatz 	B_PIXEL_ALPHA = 0,
32352a38012Sejakowatz 	B_CONSTANT_ALPHA
32452a38012Sejakowatz };
32552a38012Sejakowatz 
32669001466SAlexander von Gluck IV 
32752a38012Sejakowatz enum alpha_function {
32852a38012Sejakowatz 	B_ALPHA_OVERLAY = 0,
32997bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE,
33097bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_SOURCE_OVER = B_ALPHA_COMPOSITE,
33197bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_SOURCE_IN,
33297bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_SOURCE_OUT,
33397bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_SOURCE_ATOP,
33497bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_DESTINATION_OVER,
33597bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_DESTINATION_IN,
33697bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_DESTINATION_OUT,
33797bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_DESTINATION_ATOP,
33897bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_XOR,
33997bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_CLEAR,
34097bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_DIFFERENCE,
34197bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_LIGHTEN,
34297bd6fe8SKacper Kasper 	B_ALPHA_COMPOSITE_DARKEN
34352a38012Sejakowatz };
34452a38012Sejakowatz 
3456ec21b4aSAxel Dörfler 
3466ec21b4aSAxel Dörfler // Fixed Screen Modes
34752a38012Sejakowatz enum {
34852a38012Sejakowatz 	B_8_BIT_640x480		= 0x00000001,
34952a38012Sejakowatz 	B_8_BIT_800x600		= 0x00000002,
35052a38012Sejakowatz 	B_8_BIT_1024x768	= 0x00000004,
35152a38012Sejakowatz 	B_8_BIT_1280x1024	= 0x00000008,
35252a38012Sejakowatz 	B_8_BIT_1600x1200	= 0x00000010,
35352a38012Sejakowatz 	B_16_BIT_640x480	= 0x00000020,
35452a38012Sejakowatz 	B_16_BIT_800x600	= 0x00000040,
35552a38012Sejakowatz 	B_16_BIT_1024x768	= 0x00000080,
35652a38012Sejakowatz 	B_16_BIT_1280x1024	= 0x00000100,
35752a38012Sejakowatz 	B_16_BIT_1600x1200	= 0x00000200,
35852a38012Sejakowatz 	B_32_BIT_640x480	= 0x00000400,
35952a38012Sejakowatz 	B_32_BIT_800x600	= 0x00000800,
36052a38012Sejakowatz 	B_32_BIT_1024x768	= 0x00001000,
36152a38012Sejakowatz 	B_32_BIT_1280x1024	= 0x00002000,
36252a38012Sejakowatz 	B_32_BIT_1600x1200	= 0x00004000,
36352a38012Sejakowatz 	B_8_BIT_1152x900	= 0x00008000,
36452a38012Sejakowatz 	B_16_BIT_1152x900	= 0x00010000,
36552a38012Sejakowatz 	B_32_BIT_1152x900	= 0x00020000,
36652a38012Sejakowatz 	B_15_BIT_640x480	= 0x00040000,
36752a38012Sejakowatz 	B_15_BIT_800x600	= 0x00080000,
36852a38012Sejakowatz 	B_15_BIT_1024x768	= 0x00100000,
36952a38012Sejakowatz 	B_15_BIT_1280x1024	= 0x00200000,
37052a38012Sejakowatz 	B_15_BIT_1600x1200	= 0x00400000,
37152a38012Sejakowatz 	B_15_BIT_1152x900	= 0x00800000,
3726ec21b4aSAxel Dörfler 	B_8_BIT_640x400		= 0x80000000
37352a38012Sejakowatz };
37452a38012Sejakowatz 
37569001466SAlexander von Gluck IV 
3766ec21b4aSAxel Dörfler #endif	// _GRAPHICS_DEFS_H
377