diff options
author | Emmanuele Bassi <ebassi@linux.intel.com> | 2012-03-08 10:31:21 +0000 |
---|---|---|
committer | Emmanuele Bassi <ebassi@linux.intel.com> | 2012-03-16 12:33:37 +0000 |
commit | 07bb35bbe38392e46f92ad17049893ef752f5c55 (patch) | |
tree | b602abeb933f8666f15cb99390bb97c4e5f5ff8b /clutter/clutter-macros.h | |
parent | e2f1153c462d955dbbab8bc981dc2fc77cae1cde (diff) | |
download | clutter-07bb35bbe38392e46f92ad17049893ef752f5c55.tar.gz |
Add ClutterCanvas, a drawing content
Diffstat (limited to 'clutter/clutter-macros.h')
-rw-r--r-- | clutter/clutter-macros.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/clutter/clutter-macros.h b/clutter/clutter-macros.h index 2e70a6b8e..50eb021e2 100644 --- a/clutter/clutter-macros.h +++ b/clutter/clutter-macros.h @@ -248,4 +248,24 @@ # define CLUTTER_AVAILABLE_IN_1_10 #endif +/** + * CLUTTER_CAIRO_FORMAT_ARGB32: + * + * The #CoglPixelFormat to be used when uploading image data from + * and to a Cairo image surface using %CAIRO_FORMAT_ARGB32 and + * %CAIRO_FORMAT_RGB24 as #cairo_format_t. + * + * Since: 1.8 + */ + +/* Cairo stores the data in native byte order as ARGB but Cogl's pixel + * formats specify the actual byte order. Therefore we need to use a + * different format depending on the architecture + */ +#if G_BYTE_ORDER == G_LITTLE_ENDIAN +#define CLUTTER_CAIRO_FORMAT_ARGB32 (COGL_PIXEL_FORMAT_BGRA_8888_PRE) +#else +#define CLUTTER_CAIRO_FORMAT_ARGB32 (COGL_PIXEL_FORMAT_ARGB_8888_PRE) +#endif + #endif /* __CLUTTER_MACROS_H__ */ |