1 /* -*- Mode: C; indent-tabs-mode: t; tab-width: 4 -*-
2 // ---------------------------------------------------------------------------
4 // Copyright (C) Stephanie Gawroriski <xer@multiphasicapps.net>
5 // ---------------------------------------------------------------------------
6 // SquirrelJME is under the Mozilla Public License Version 2.0.
7 // See license.mkd for licensing and copyright information.
8 // -------------------------------------------------------------------------*/
16 #ifndef SQUIRRELJME_GFXCONST_H
17 #define SQUIRRELJME_GFXCONST_H
21 #ifndef SJME_CXX_IS_EXTERNED
22 #define SJME_CXX_IS_EXTERNED
23 #define SJME_CXX_SQUIRRELJME_GFXCONST_H
25 #endif /* #ifdef SJME_CXX_IS_EXTERNED */
26 #endif /* #ifdef __cplusplus */
28 /*--------------------------------------------------------------------------*/
31 * The pixel format used for graphics, matches @c UIPixelFormat.
35 typedef enum sjme_gfx_pixelFormat
37 /** 32-bit RGBA (@c uint32_t ) [Java ME Standard]. */
38 SJME_GFX_PIXEL_FORMAT_INT_ARGB8888
= 0,
40 /** 32-bit RGB (@c uint32_t ) [Java ME Standard]. */
41 SJME_GFX_PIXEL_FORMAT_INT_RGB888
= 1,
43 /** 16-bit RGBA4444. (@c uint16_t ) [Java ME Standard]. */
44 SJME_GFX_PIXEL_FORMAT_SHORT_ARGB4444
= 2,
46 /** 16-bit RGB565. (@c uint16_t ) [Java ME Standard]. */
47 SJME_GFX_PIXEL_FORMAT_SHORT_RGB565
= 3,
49 /** 16-bit RGB555. (@c uint16_t ). */
50 SJME_GFX_PIXEL_FORMAT_SHORT_RGB555
= 4,
52 /** 16-bit ABGR1555. (@c uint16_t ) [PlayStation 2]. */
53 SJME_GFX_PIXEL_FORMAT_SHORT_ABGR1555
= 5,
55 /** 65536 Colors (@c uint16_t ). */
56 SJME_GFX_PIXEL_FORMAT_SHORT_INDEXED65536
= 6,
58 /** 256 Colors (@c uint8_t ). */
59 SJME_GFX_PIXEL_FORMAT_BYTE_INDEXED256
= 7,
61 /** Packed 16 colors (4-bit). (packed @c uint8_t ) */
62 SJME_GFX_PIXEL_FORMAT_PACKED_INDEXED4
= 8,
64 /** Packed 4 Colors (2-bit). (packed @c uint8_t ) */
65 SJME_GFX_PIXEL_FORMAT_PACKED_INDEXED2
= 9,
67 /** Packed 2 colors (1-bit). (packed @c uint8_t ) */
68 SJME_GFX_PIXEL_FORMAT_PACKED_INDEXED1
= 10,
70 /** 32-bit BGRA ({@code int}). */
71 SJME_GFX_PIXEL_FORMAT_INT_BGRA8888
= 11,
73 /** 32-bit BGRX ({@code int}). */
74 SJME_GFX_PIXEL_FORMAT_INT_BGRX8888
= 12,
76 /** 32-bit BGR ({@code int}). */
77 SJME_GFX_PIXEL_FORMAT_INT_BGR888
= 13,
79 /** 32-bit RGBX ({@code int}). */
80 SJME_GFX_PIXEL_FORMAT_INT_RGBX8888
= 14,
82 /** 24-bit RGB consisting of three bytes. */
83 SJME_GFX_PIXEL_FORMAT_BYTE3_RGB888
= 15,
85 /** 24-bit BGR consisting of three bytes. */
86 SJME_GFX_PIXEL_FORMAT_BYTE3_BGR888
= 16,
88 /** The number of pixel formats. */
89 SJME_NUM_GFX_PIXEL_FORMATS
= 16,
90 } sjme_gfx_pixelFormat
;
92 /*--------------------------------------------------------------------------*/
96 #ifdef SJME_CXX_SQUIRRELJME_GFXCONST_H
98 #undef SJME_CXX_SQUIRRELJME_GFXCONST_H
99 #undef SJME_CXX_IS_EXTERNED
100 #endif /* #ifdef SJME_CXX_SQUIRRELJME_GFXCONST_H */
101 #endif /* #ifdef __cplusplus */
103 #endif /* SQUIRRELJME_GFXCONST_H */