pixman: Branch 'master'
Søren Sandmann Pedersen
sandmann at kemper.freedesktop.org
Sat Jun 16 19:14:28 PDT 2007
pixman/pixman-compose.c | 1492 +++++++++++++++++++++--------------------------
pixman/pixman-edge-imp.h | 43 -
pixman/pixman-edge.c | 183 ++---
pixman/pixman-private.h | 61 -
4 files changed, 822 insertions(+), 957 deletions(-)
New commits:
diff-tree e0a501d9b7e5c4ca07115552a16c4c4953ec5702 (from 9b3cfcc13d0613cfb9d15b21a6b90e4a91a1666f)
Author: Søren Sandmann <sandmann at redhat.com>
Date: Sat Jun 16 22:10:36 2007 -0400
Remove ACCESS_MEM macro; define READ and WRITE to directly use the wrapper functions
diff --git a/pixman/pixman-compose.c b/pixman/pixman-compose.c
index 80831cd..63b1677 100644
--- a/pixman/pixman-compose.c
+++ b/pixman/pixman-compose.c
@@ -123,10 +123,8 @@ static FASTCALL void
fbFetch_a8r8g8b8 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- MEMCPY_WRAPPED(buffer, (const uint32_t *)bits + x,
- width*sizeof(uint32_t));
- );
+ MEMCPY_WRAPPED(buffer, (const uint32_t *)bits + x,
+ width*sizeof(uint32_t));
}
static FASTCALL void
@@ -135,10 +133,9 @@ fbFetch_x8r8g8b8 (pixman_image_t *image,
{
const uint32_t *pixel = (const uint32_t *)bits + x;
const uint32_t *end = pixel + width;
- ACCESS_MEM (
- while (pixel < end) {
- WRITE(buffer++, READ(pixel++) | 0xff000000);
- });
+ while (pixel < end) {
+ WRITE(buffer++, READ(pixel++) | 0xff000000);
+ }
}
static FASTCALL void
@@ -147,13 +144,12 @@ fbFetch_a8b8g8r8 (pixman_image_t *image,
{
const uint32_t *pixel = (uint32_t *)bits + x;
const uint32_t *end = pixel + width;
- ACCESS_MEM (
- while (pixel < end) {
- WRITE(buffer++, ((READ(pixel) & 0xff00ff00) |
- ((READ(pixel) >> 16) & 0xff) |
- ((READ(pixel) & 0xff) << 16)));
- ++pixel;
- });
+ while (pixel < end) {
+ WRITE(buffer++, ((READ(pixel) & 0xff00ff00) |
+ ((READ(pixel) >> 16) & 0xff) |
+ ((READ(pixel) & 0xff) << 16)));
+ ++pixel;
+ }
}
static FASTCALL void
@@ -162,14 +158,13 @@ fbFetch_x8b8g8r8 (pixman_image_t *image,
{
const uint32_t *pixel = (uint32_t *)bits + x;
const uint32_t *end = pixel + width;
- ACCESS_MEM (
- while (pixel < end) {
- WRITE(buffer++, 0xff000000 |
- ((READ(pixel) & 0x0000ff00) |
- ((READ(pixel) >> 16) & 0xff) |
- ((READ(pixel) & 0xff) << 16)));
- ++pixel;
- });
+ while (pixel < end) {
+ WRITE(buffer++, 0xff000000 |
+ ((READ(pixel) & 0x0000ff00) |
+ ((READ(pixel) >> 16) & 0xff) |
+ ((READ(pixel) & 0xff) << 16)));
+ ++pixel;
+ }
}
static FASTCALL void
@@ -178,12 +173,11 @@ fbFetch_r8g8b8 (pixman_image_t *image,
{
const uint8_t *pixel = (const uint8_t *)bits + 3*x;
const uint8_t *end = pixel + 3*width;
- ACCESS_MEM (
- while (pixel < end) {
- uint32_t b = Fetch24(pixel) | 0xff000000;
- pixel += 3;
- WRITE(buffer++, b);
- });
+ while (pixel < end) {
+ uint32_t b = Fetch24(pixel) | 0xff000000;
+ pixel += 3;
+ WRITE(buffer++, b);
+ }
}
static FASTCALL void
@@ -192,20 +186,19 @@ fbFetch_b8g8r8 (pixman_image_t *image,
{
const uint8_t *pixel = (const uint8_t *)bits + 3*x;
const uint8_t *end = pixel + 3*width;
- ACCESS_MEM (
- while (pixel < end) {
- uint32_t b = 0xff000000;
+ while (pixel < end) {
+ uint32_t b = 0xff000000;
#if IMAGE_BYTE_ORDER == MSBFirst
- b |= (READ(pixel++));
- b |= (READ(pixel++) << 8);
- b |= (READ(pixel++) << 16);
+ b |= (READ(pixel++));
+ b |= (READ(pixel++) << 8);
+ b |= (READ(pixel++) << 16);
#else
- b |= (READ(pixel++) << 16);
- b |= (READ(pixel++) << 8);
- b |= (READ(pixel++));
+ b |= (READ(pixel++) << 16);
+ b |= (READ(pixel++) << 8);
+ b |= (READ(pixel++));
#endif
- WRITE(buffer++, b);
- });
+ WRITE(buffer++, b);
+ }
}
static FASTCALL void
@@ -215,16 +208,15 @@ fbFetch_r5g6b5 (pixman_image_t *image,
{
const uint16_t *pixel = (const uint16_t *)bits + x;
const uint16_t *end = pixel + width;
- ACCESS_MEM (
- while (pixel < end) {
- uint32_t p = READ(pixel++);
- uint32_t r = (((p) << 3) & 0xf8) |
- (((p) << 5) & 0xfc00) |
- (((p) << 8) & 0xf80000);
- r |= (r >> 5) & 0x70007;
- r |= (r >> 6) & 0x300;
- WRITE(buffer++, 0xff000000 | r);
- });
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+ uint32_t r = (((p) << 3) & 0xf8) |
+ (((p) << 5) & 0xfc00) |
+ (((p) << 8) & 0xf80000);
+ r |= (r >> 5) & 0x70007;
+ r |= (r >> 6) & 0x300;
+ WRITE(buffer++, 0xff000000 | r);
+ }
}
static FASTCALL void
@@ -234,16 +226,15 @@ fbFetch_b5g6r5 (pixman_image_t *image,
{
uint32_t r,g,b;
- ACCESS_MEM(
- const uint16_t *pixel = (const uint16_t *)bits + x;
- const uint16_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
- b = ((p & 0xf800) | ((p & 0xe000) >> 5)) >> 8;
- g = ((p & 0x07e0) | ((p & 0x0600) >> 6)) << 5;
- r = ((p & 0x001c) | ((p & 0x001f) << 5)) << 14;
- WRITE(buffer++, (0xff000000 | r | g | b));
- });
+ const uint16_t *pixel = (const uint16_t *)bits + x;
+ const uint16_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+ b = ((p & 0xf800) | ((p & 0xe000) >> 5)) >> 8;
+ g = ((p & 0x07e0) | ((p & 0x0600) >> 6)) << 5;
+ r = ((p & 0x001c) | ((p & 0x001f) << 5)) << 14;
+ WRITE(buffer++, (0xff000000 | r | g | b));
+ }
}
static FASTCALL void
@@ -252,18 +243,17 @@ fbFetch_a1r5g5b5 (pixman_image_t *image,
{
uint32_t r,g,b, a;
- ACCESS_MEM (
- const uint16_t *pixel = (const uint16_t *)bits + x;
- const uint16_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- a = (uint32_t) ((uint8_t) (0 - ((p & 0x8000) >> 15))) << 24;
- r = ((p & 0x7c00) | ((p & 0x7000) >> 5)) << 9;
- g = ((p & 0x03e0) | ((p & 0x0380) >> 5)) << 6;
- b = ((p & 0x001c) | ((p & 0x001f) << 5)) >> 2;
- WRITE(buffer++, (a | r | g | b));
- });
+ const uint16_t *pixel = (const uint16_t *)bits + x;
+ const uint16_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ a = (uint32_t) ((uint8_t) (0 - ((p & 0x8000) >> 15))) << 24;
+ r = ((p & 0x7c00) | ((p & 0x7000) >> 5)) << 9;
+ g = ((p & 0x03e0) | ((p & 0x0380) >> 5)) << 6;
+ b = ((p & 0x001c) | ((p & 0x001f) << 5)) >> 2;
+ WRITE(buffer++, (a | r | g | b));
+ }
}
static FASTCALL void
@@ -272,17 +262,16 @@ fbFetch_x1r5g5b5 (pixman_image_t *image,
{
uint32_t r,g,b;
- ACCESS_MEM (
- const uint16_t *pixel = (const uint16_t *)bits + x;
- const uint16_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- r = ((p & 0x7c00) | ((p & 0x7000) >> 5)) << 9;
- g = ((p & 0x03e0) | ((p & 0x0380) >> 5)) << 6;
- b = ((p & 0x001c) | ((p & 0x001f) << 5)) >> 2;
- WRITE(buffer++, (0xff000000 | r | g | b));
- });
+ const uint16_t *pixel = (const uint16_t *)bits + x;
+ const uint16_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ r = ((p & 0x7c00) | ((p & 0x7000) >> 5)) << 9;
+ g = ((p & 0x03e0) | ((p & 0x0380) >> 5)) << 6;
+ b = ((p & 0x001c) | ((p & 0x001f) << 5)) >> 2;
+ WRITE(buffer++, (0xff000000 | r | g | b));
+ }
}
static FASTCALL void
@@ -291,18 +280,17 @@ fbFetch_a1b5g5r5 (pixman_image_t *image,
{
uint32_t r,g,b, a;
- ACCESS_MEM (
- const uint16_t *pixel = (const uint16_t *)bits + x;
- const uint16_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- a = (uint32_t) ((uint8_t) (0 - ((p & 0x8000) >> 15))) << 24;
- b = ((p & 0x7c00) | ((p & 0x7000) >> 5)) >> 7;
- g = ((p & 0x03e0) | ((p & 0x0380) >> 5)) << 6;
- r = ((p & 0x001c) | ((p & 0x001f) << 5)) << 14;
- WRITE(buffer++, (a | r | g | b));
- });
+ const uint16_t *pixel = (const uint16_t *)bits + x;
+ const uint16_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ a = (uint32_t) ((uint8_t) (0 - ((p & 0x8000) >> 15))) << 24;
+ b = ((p & 0x7c00) | ((p & 0x7000) >> 5)) >> 7;
+ g = ((p & 0x03e0) | ((p & 0x0380) >> 5)) << 6;
+ r = ((p & 0x001c) | ((p & 0x001f) << 5)) << 14;
+ WRITE(buffer++, (a | r | g | b));
+ }
}
static FASTCALL void
@@ -311,17 +299,16 @@ fbFetch_x1b5g5r5 (pixman_image_t *image,
{
uint32_t r,g,b;
- ACCESS_MEM (
- const uint16_t *pixel = (const uint16_t *)bits + x;
- const uint16_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- b = ((p & 0x7c00) | ((p & 0x7000) >> 5)) >> 7;
- g = ((p & 0x03e0) | ((p & 0x0380) >> 5)) << 6;
- r = ((p & 0x001c) | ((p & 0x001f) << 5)) << 14;
- WRITE(buffer++, (0xff000000 | r | g | b));
- });
+ const uint16_t *pixel = (const uint16_t *)bits + x;
+ const uint16_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ b = ((p & 0x7c00) | ((p & 0x7000) >> 5)) >> 7;
+ g = ((p & 0x03e0) | ((p & 0x0380) >> 5)) << 6;
+ r = ((p & 0x001c) | ((p & 0x001f) << 5)) << 14;
+ WRITE(buffer++, (0xff000000 | r | g | b));
+ }
}
static FASTCALL void
@@ -329,18 +316,17 @@ fbFetch_a4r4g4b4 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
uint32_t r,g,b, a;
- ACCESS_MEM (
- const uint16_t *pixel = (const uint16_t *)bits + x;
- const uint16_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- a = ((p & 0xf000) | ((p & 0xf000) >> 4)) << 16;
- r = ((p & 0x0f00) | ((p & 0x0f00) >> 4)) << 12;
- g = ((p & 0x00f0) | ((p & 0x00f0) >> 4)) << 8;
- b = ((p & 0x000f) | ((p & 0x000f) << 4));
- WRITE(buffer++, (a | r | g | b));
- });
+ const uint16_t *pixel = (const uint16_t *)bits + x;
+ const uint16_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ a = ((p & 0xf000) | ((p & 0xf000) >> 4)) << 16;
+ r = ((p & 0x0f00) | ((p & 0x0f00) >> 4)) << 12;
+ g = ((p & 0x00f0) | ((p & 0x00f0) >> 4)) << 8;
+ b = ((p & 0x000f) | ((p & 0x000f) << 4));
+ WRITE(buffer++, (a | r | g | b));
+ }
}
static FASTCALL void
@@ -349,17 +335,16 @@ fbFetch_x4r4g4b4 (pixman_image_t *image,
{
uint32_t r,g,b;
- ACCESS_MEM (
- const uint16_t *pixel = (const uint16_t *)bits + x;
- const uint16_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- r = ((p & 0x0f00) | ((p & 0x0f00) >> 4)) << 12;
- g = ((p & 0x00f0) | ((p & 0x00f0) >> 4)) << 8;
- b = ((p & 0x000f) | ((p & 0x000f) << 4));
- WRITE(buffer++, (0xff000000 | r | g | b));
- });
+ const uint16_t *pixel = (const uint16_t *)bits + x;
+ const uint16_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ r = ((p & 0x0f00) | ((p & 0x0f00) >> 4)) << 12;
+ g = ((p & 0x00f0) | ((p & 0x00f0) >> 4)) << 8;
+ b = ((p & 0x000f) | ((p & 0x000f) << 4));
+ WRITE(buffer++, (0xff000000 | r | g | b));
+ }
}
static FASTCALL void
@@ -368,18 +353,17 @@ fbFetch_a4b4g4r4 (pixman_image_t *image,
{
uint32_t r,g,b, a;
- ACCESS_MEM (
- const uint16_t *pixel = (const uint16_t *)bits + x;
- const uint16_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- a = ((p & 0xf000) | ((p & 0xf000) >> 4)) << 16;
- b = ((p & 0x0f00) | ((p & 0x0f00) >> 4)) >> 4;
- g = ((p & 0x00f0) | ((p & 0x00f0) >> 4)) << 8;
- r = ((p & 0x000f) | ((p & 0x000f) << 4)) << 16;
- WRITE(buffer++, (a | r | g | b));
- });
+ const uint16_t *pixel = (const uint16_t *)bits + x;
+ const uint16_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ a = ((p & 0xf000) | ((p & 0xf000) >> 4)) << 16;
+ b = ((p & 0x0f00) | ((p & 0x0f00) >> 4)) >> 4;
+ g = ((p & 0x00f0) | ((p & 0x00f0) >> 4)) << 8;
+ r = ((p & 0x000f) | ((p & 0x000f) << 4)) << 16;
+ WRITE(buffer++, (a | r | g | b));
+ }
}
static FASTCALL void
@@ -388,29 +372,27 @@ fbFetch_x4b4g4r4 (pixman_image_t *image,
{
uint32_t r,g,b;
- ACCESS_MEM (
- const uint16_t *pixel = (const uint16_t *)bits + x;
- const uint16_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- b = ((p & 0x0f00) | ((p & 0x0f00) >> 4)) >> 4;
- g = ((p & 0x00f0) | ((p & 0x00f0) >> 4)) << 8;
- r = ((p & 0x000f) | ((p & 0x000f) << 4)) << 16;
- WRITE(buffer++, (0xff000000 | r | g | b));
- });
+ const uint16_t *pixel = (const uint16_t *)bits + x;
+ const uint16_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ b = ((p & 0x0f00) | ((p & 0x0f00) >> 4)) >> 4;
+ g = ((p & 0x00f0) | ((p & 0x00f0) >> 4)) << 8;
+ r = ((p & 0x000f) | ((p & 0x000f) << 4)) << 16;
+ WRITE(buffer++, (0xff000000 | r | g | b));
+ }
}
static FASTCALL void
fbFetch_a8 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- const uint8_t *pixel = (const uint8_t *)bits + x;
- const uint8_t *end = pixel + width;
- while (pixel < end) {
- WRITE(buffer++, READ(pixel++) << 24);
- });
+ const uint8_t *pixel = (const uint8_t *)bits + x;
+ const uint8_t *end = pixel + width;
+ while (pixel < end) {
+ WRITE(buffer++, READ(pixel++) << 24);
+ }
}
static FASTCALL void
@@ -419,20 +401,19 @@ fbFetch_r3g3b2 (pixman_image_t *image,
{
uint32_t r,g,b;
- ACCESS_MEM (
- const uint8_t *pixel = (const uint8_t *)bits + x;
- const uint8_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- r = ((p & 0xe0) | ((p & 0xe0) >> 3) | ((p & 0xc0) >> 6)) << 16;
- g = ((p & 0x1c) | ((p & 0x18) >> 3) | ((p & 0x1c) << 3)) << 8;
- b = (((p & 0x03) ) |
- ((p & 0x03) << 2) |
- ((p & 0x03) << 4) |
- ((p & 0x03) << 6));
- WRITE(buffer++, (0xff000000 | r | g | b));
- });
+ const uint8_t *pixel = (const uint8_t *)bits + x;
+ const uint8_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ r = ((p & 0xe0) | ((p & 0xe0) >> 3) | ((p & 0xc0) >> 6)) << 16;
+ g = ((p & 0x1c) | ((p & 0x18) >> 3) | ((p & 0x1c) << 3)) << 8;
+ b = (((p & 0x03) ) |
+ ((p & 0x03) << 2) |
+ ((p & 0x03) << 4) |
+ ((p & 0x03) << 6));
+ WRITE(buffer++, (0xff000000 | r | g | b));
+ }
}
static FASTCALL void
@@ -441,22 +422,21 @@ fbFetch_b2g3r3 (pixman_image_t *image,
{
uint32_t r,g,b;
- ACCESS_MEM (
- const uint8_t *pixel = (const uint8_t *)bits + x;
- const uint8_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- b = (((p & 0xc0) ) |
- ((p & 0xc0) >> 2) |
- ((p & 0xc0) >> 4) |
- ((p & 0xc0) >> 6));
- g = ((p & 0x38) | ((p & 0x38) >> 3) | ((p & 0x30) << 2)) << 8;
- r = (((p & 0x07) ) |
- ((p & 0x07) << 3) |
- ((p & 0x06) << 6)) << 16;
- WRITE(buffer++, (0xff000000 | r | g | b));
- });
+ const uint8_t *pixel = (const uint8_t *)bits + x;
+ const uint8_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ b = (((p & 0xc0) ) |
+ ((p & 0xc0) >> 2) |
+ ((p & 0xc0) >> 4) |
+ ((p & 0xc0) >> 6));
+ g = ((p & 0x38) | ((p & 0x38) >> 3) | ((p & 0x30) << 2)) << 8;
+ r = (((p & 0x07) ) |
+ ((p & 0x07) << 3) |
+ ((p & 0x06) << 6)) << 16;
+ WRITE(buffer++, (0xff000000 | r | g | b));
+ }
}
static FASTCALL void
@@ -464,18 +444,17 @@ fbFetch_a2r2g2b2 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- const uint8_t *pixel = (const uint8_t *)bits + x;
- const uint8_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- a = ((p & 0xc0) * 0x55) << 18;
- r = ((p & 0x30) * 0x55) << 12;
- g = ((p & 0x0c) * 0x55) << 6;
- b = ((p & 0x03) * 0x55);
- WRITE(buffer++, a|r|g|b);
- });
+ const uint8_t *pixel = (const uint8_t *)bits + x;
+ const uint8_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ a = ((p & 0xc0) * 0x55) << 18;
+ r = ((p & 0x30) * 0x55) << 12;
+ g = ((p & 0x0c) * 0x55) << 6;
+ b = ((p & 0x03) * 0x55);
+ WRITE(buffer++, a|r|g|b);
+ }
}
static FASTCALL void
@@ -483,44 +462,41 @@ fbFetch_a2b2g2r2 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- const uint8_t *pixel = (const uint8_t *)bits + x;
- const uint8_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
-
- a = ((p & 0xc0) * 0x55) << 18;
- b = ((p & 0x30) * 0x55) >> 6;
- g = ((p & 0x0c) * 0x55) << 6;
- r = ((p & 0x03) * 0x55) << 16;
- WRITE(buffer++, a|r|g|b);
- });
+ const uint8_t *pixel = (const uint8_t *)bits + x;
+ const uint8_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+
+ a = ((p & 0xc0) * 0x55) << 18;
+ b = ((p & 0x30) * 0x55) >> 6;
+ g = ((p & 0x0c) * 0x55) << 6;
+ r = ((p & 0x03) * 0x55) << 16;
+ WRITE(buffer++, a|r|g|b);
+ }
}
static FASTCALL void
fbFetch_c8 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- const uint8_t *pixel = (const uint8_t *)bits + x;
- const uint8_t *end = pixel + width;
- while (pixel < end) {
- uint32_t p = READ(pixel++);
- WRITE(buffer++, indexed->rgba[p]);
- });
+ const uint8_t *pixel = (const uint8_t *)bits + x;
+ const uint8_t *end = pixel + width;
+ while (pixel < end) {
+ uint32_t p = READ(pixel++);
+ WRITE(buffer++, indexed->rgba[p]);
+ }
}
static FASTCALL void
fbFetch_x4a4 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- const uint8_t *pixel = (const uint8_t *)bits + x;
- const uint8_t *end = pixel + width;
- while (pixel < end) {
- uint8_t p = READ(pixel++) & 0xf;
- WRITE(buffer++, (p | (p << 4)) << 24);
- });
+ const uint8_t *pixel = (const uint8_t *)bits + x;
+ const uint8_t *end = pixel + width;
+ while (pixel < end) {
+ uint8_t p = READ(pixel++) & 0xf;
+ WRITE(buffer++, (p | (p << 4)) << 24);
+ }
}
#define Fetch8(l,o) (((uint8_t *) (l))[(o) >> 2])
@@ -534,14 +510,13 @@ static FASTCALL void
fbFetch_a4 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t p = Fetch4(bits, i + x);
-
- p |= p << 4;
- WRITE(buffer++, p << 24);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t p = Fetch4(bits, i + x);
+
+ p |= p << 4;
+ WRITE(buffer++, p << 24);
+ }
}
static FASTCALL void
@@ -549,16 +524,15 @@ fbFetch_r1g2b1 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t p = Fetch4(bits, i + x);
-
- r = ((p & 0x8) * 0xff) << 13;
- g = ((p & 0x6) * 0x55) << 7;
- b = ((p & 0x1) * 0xff);
- WRITE(buffer++, 0xff000000|r|g|b);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t p = Fetch4(bits, i + x);
+
+ r = ((p & 0x8) * 0xff) << 13;
+ g = ((p & 0x6) * 0x55) << 7;
+ b = ((p & 0x1) * 0xff);
+ WRITE(buffer++, 0xff000000|r|g|b);
+ }
}
static FASTCALL void
@@ -566,16 +540,15 @@ fbFetch_b1g2r1 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t p = Fetch4(bits, i + x);
-
- b = ((p & 0x8) * 0xff) >> 3;
- g = ((p & 0x6) * 0x55) << 7;
- r = ((p & 0x1) * 0xff) << 16;
- WRITE(buffer++, 0xff000000|r|g|b);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t p = Fetch4(bits, i + x);
+
+ b = ((p & 0x8) * 0xff) >> 3;
+ g = ((p & 0x6) * 0x55) << 7;
+ r = ((p & 0x1) * 0xff) << 16;
+ WRITE(buffer++, 0xff000000|r|g|b);
+ }
}
static FASTCALL void
@@ -583,17 +556,16 @@ fbFetch_a1r1g1b1 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t p = Fetch4(bits, i + x);
-
- a = ((p & 0x8) * 0xff) << 21;
- r = ((p & 0x4) * 0xff) << 14;
- g = ((p & 0x2) * 0xff) << 7;
- b = ((p & 0x1) * 0xff);
- WRITE(buffer++, a|r|g|b);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t p = Fetch4(bits, i + x);
+
+ a = ((p & 0x8) * 0xff) << 21;
+ r = ((p & 0x4) * 0xff) << 14;
+ g = ((p & 0x2) * 0xff) << 7;
+ b = ((p & 0x1) * 0xff);
+ WRITE(buffer++, a|r|g|b);
+ }
}
static FASTCALL void
@@ -601,30 +573,28 @@ fbFetch_a1b1g1r1 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t p = Fetch4(bits, i + x);
-
- a = ((p & 0x8) * 0xff) << 21;
- r = ((p & 0x4) * 0xff) >> 3;
- g = ((p & 0x2) * 0xff) << 7;
- b = ((p & 0x1) * 0xff) << 16;
- WRITE(buffer++, a|r|g|b);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t p = Fetch4(bits, i + x);
+
+ a = ((p & 0x8) * 0xff) << 21;
+ r = ((p & 0x4) * 0xff) >> 3;
+ g = ((p & 0x2) * 0xff) << 7;
+ b = ((p & 0x1) * 0xff) << 16;
+ WRITE(buffer++, a|r|g|b);
+ }
}
static FASTCALL void
fbFetch_c4 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t p = Fetch4(bits, i + x);
-
- WRITE(buffer++, indexed->rgba[p]);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t p = Fetch4(bits, i + x);
+
+ WRITE(buffer++, indexed->rgba[p]);
+ }
}
@@ -632,41 +602,39 @@ static FASTCALL void
fbFetch_a1 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t p = ((uint32_t *)bits)[(i + x) >> 5];
- uint32_t a;
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t p = ((uint32_t *)bits)[(i + x) >> 5];
+ uint32_t a;
#if BITMAP_BIT_ORDER == MSBFirst
- a = p >> (0x1f - ((i+x) & 0x1f));
+ a = p >> (0x1f - ((i+x) & 0x1f));
#else
- a = p >> ((i+x) & 0x1f);
+ a = p >> ((i+x) & 0x1f);
#endif
- a = a & 1;
- a |= a << 1;
- a |= a << 2;
- a |= a << 4;
- WRITE(buffer++, a << 24);
- });
+ a = a & 1;
+ a |= a << 1;
+ a |= a << 2;
+ a |= a << 4;
+ WRITE(buffer++, a << 24);
+ }
}
static FASTCALL void
fbFetch_g1 (pixman_image_t *image,
const uint32_t *bits, int x, int width, uint32_t *buffer, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t p = ((uint32_t *)bits)[(i+x) >> 5];
- uint32_t a;
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t p = ((uint32_t *)bits)[(i+x) >> 5];
+ uint32_t a;
#if BITMAP_BIT_ORDER == MSBFirst
- a = p >> (0x1f - ((i+x) & 0x1f));
+ a = p >> (0x1f - ((i+x) & 0x1f));
#else
- a = p >> ((i+x) & 0x1f);
+ a = p >> ((i+x) & 0x1f);
#endif
- a = a & 1;
- WRITE(buffer++, indexed->rgba[a]);
- });
+ a = a & 1;
+ WRITE(buffer++, indexed->rgba[a]);
+ }
}
static fetchProc fetchProcForPicture (bits_image_t * pict)
@@ -733,86 +701,74 @@ static FASTCALL uint32_t
fbFetchPixel_a8r8g8b8 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- return READ((uint32_t *)bits + offset);
- );
+ return READ((uint32_t *)bits + offset);
}
static FASTCALL uint32_t
fbFetchPixel_x8r8g8b8 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- return READ((uint32_t *)bits + offset) | 0xff000000;
- );
+ return READ((uint32_t *)bits + offset) | 0xff000000;
}
static FASTCALL uint32_t
fbFetchPixel_a8b8g8r8 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- uint32_t pixel = READ((uint32_t *)bits + offset);
-
- return ((pixel & 0xff000000) |
- ((pixel >> 16) & 0xff) |
- (pixel & 0x0000ff00) |
- ((pixel & 0xff) << 16));
- );
+ uint32_t pixel = READ((uint32_t *)bits + offset);
+
+ return ((pixel & 0xff000000) |
+ ((pixel >> 16) & 0xff) |
+ (pixel & 0x0000ff00) |
+ ((pixel & 0xff) << 16));
}
static FASTCALL uint32_t
fbFetchPixel_x8b8g8r8 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- uint32_t pixel = READ((uint32_t *)bits + offset);
-
- return ((0xff000000) |
- ((pixel >> 16) & 0xff) |
- (pixel & 0x0000ff00) |
- ((pixel & 0xff) << 16));
- );
+ uint32_t pixel = READ((uint32_t *)bits + offset);
+
+ return ((0xff000000) |
+ ((pixel >> 16) & 0xff) |
+ (pixel & 0x0000ff00) |
+ ((pixel & 0xff) << 16));
}
static FASTCALL uint32_t
fbFetchPixel_r8g8b8 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- uint8_t *pixel = ((uint8_t *) bits) + (offset*3);
+ uint8_t *pixel = ((uint8_t *) bits) + (offset*3);
#if IMAGE_BYTE_ORDER == MSBFirst
- return (0xff000000 |
- (READ(pixel + 0) << 16) |
- (READ(pixel + 1) << 8) |
- (READ(pixel + 2)));
+ return (0xff000000 |
+ (READ(pixel + 0) << 16) |
+ (READ(pixel + 1) << 8) |
+ (READ(pixel + 2)));
#else
- return (0xff000000 |
- (READ(pixel + 2) << 16) |
- (READ(pixel + 1) << 8) |
- (READ(pixel + 0)));
+ return (0xff000000 |
+ (READ(pixel + 2) << 16) |
+ (READ(pixel + 1) << 8) |
+ (READ(pixel + 0)));
#endif
- );
}
static FASTCALL uint32_t
fbFetchPixel_b8g8r8 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- uint8_t *pixel = ((uint8_t *) bits) + (offset*3);
+ uint8_t *pixel = ((uint8_t *) bits) + (offset*3);
#if IMAGE_BYTE_ORDER == MSBFirst
- return (0xff000000 |
- (READ(pixel + 2) << 16) |
- (READ(pixel + 1) << 8) |
- (READ(pixel + 0)));
+ return (0xff000000 |
+ (READ(pixel + 2) << 16) |
+ (READ(pixel + 1) << 8) |
+ (READ(pixel + 0)));
#else
- return (0xff000000 |
- (READ(pixel + 0) << 16) |
- (READ(pixel + 1) << 8) |
- (READ(pixel + 2)));
+ return (0xff000000 |
+ (READ(pixel + 0) << 16) |
+ (READ(pixel + 1) << 8) |
+ (READ(pixel + 2)));
#endif
- );
}
static FASTCALL uint32_t
@@ -820,14 +776,12 @@ fbFetchPixel_r5g6b5 (pixman_image_t *ima
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint16_t *) bits + offset);
-
- r = ((pixel & 0xf800) | ((pixel & 0xe000) >> 5)) << 8;
- g = ((pixel & 0x07e0) | ((pixel & 0x0600) >> 6)) << 5;
- b = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) >> 2;
- return (0xff000000 | r | g | b);
- );
+ uint32_t pixel = READ((uint16_t *) bits + offset);
+
+ r = ((pixel & 0xf800) | ((pixel & 0xe000) >> 5)) << 8;
+ g = ((pixel & 0x07e0) | ((pixel & 0x0600) >> 6)) << 5;
+ b = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) >> 2;
+ return (0xff000000 | r | g | b);
}
static FASTCALL uint32_t
@@ -835,14 +789,12 @@ fbFetchPixel_b5g6r5 (pixman_image_t *ima
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint16_t *) bits + offset);
-
- b = ((pixel & 0xf800) | ((pixel & 0xe000) >> 5)) >> 8;
- g = ((pixel & 0x07e0) | ((pixel & 0x0600) >> 6)) << 5;
- r = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) << 14;
- return (0xff000000 | r | g | b);
- );
+ uint32_t pixel = READ((uint16_t *) bits + offset);
+
+ b = ((pixel & 0xf800) | ((pixel & 0xe000) >> 5)) >> 8;
+ g = ((pixel & 0x07e0) | ((pixel & 0x0600) >> 6)) << 5;
+ r = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) << 14;
+ return (0xff000000 | r | g | b);
}
static FASTCALL uint32_t
@@ -850,15 +802,13 @@ fbFetchPixel_a1r5g5b5 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint16_t *) bits + offset);
-
- a = (uint32_t) ((uint8_t) (0 - ((pixel & 0x8000) >> 15))) << 24;
- r = ((pixel & 0x7c00) | ((pixel & 0x7000) >> 5)) << 9;
- g = ((pixel & 0x03e0) | ((pixel & 0x0380) >> 5)) << 6;
- b = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) >> 2;
- return (a | r | g | b);
- );
+ uint32_t pixel = READ((uint16_t *) bits + offset);
+
+ a = (uint32_t) ((uint8_t) (0 - ((pixel & 0x8000) >> 15))) << 24;
+ r = ((pixel & 0x7c00) | ((pixel & 0x7000) >> 5)) << 9;
+ g = ((pixel & 0x03e0) | ((pixel & 0x0380) >> 5)) << 6;
+ b = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) >> 2;
+ return (a | r | g | b);
}
static FASTCALL uint32_t
@@ -866,14 +816,12 @@ fbFetchPixel_x1r5g5b5 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint16_t *) bits + offset);
-
- r = ((pixel & 0x7c00) | ((pixel & 0x7000) >> 5)) << 9;
- g = ((pixel & 0x03e0) | ((pixel & 0x0380) >> 5)) << 6;
- b = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) >> 2;
- return (0xff000000 | r | g | b);
- );
+ uint32_t pixel = READ((uint16_t *) bits + offset);
+
+ r = ((pixel & 0x7c00) | ((pixel & 0x7000) >> 5)) << 9;
+ g = ((pixel & 0x03e0) | ((pixel & 0x0380) >> 5)) << 6;
+ b = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) >> 2;
+ return (0xff000000 | r | g | b);
}
static FASTCALL uint32_t
@@ -881,15 +829,13 @@ fbFetchPixel_a1b5g5r5 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint16_t *) bits + offset);
-
- a = (uint32_t) ((uint8_t) (0 - ((pixel & 0x8000) >> 15))) << 24;
- b = ((pixel & 0x7c00) | ((pixel & 0x7000) >> 5)) >> 7;
- g = ((pixel & 0x03e0) | ((pixel & 0x0380) >> 5)) << 6;
- r = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) << 14;
- return (a | r | g | b);
- );
+ uint32_t pixel = READ((uint16_t *) bits + offset);
+
+ a = (uint32_t) ((uint8_t) (0 - ((pixel & 0x8000) >> 15))) << 24;
+ b = ((pixel & 0x7c00) | ((pixel & 0x7000) >> 5)) >> 7;
+ g = ((pixel & 0x03e0) | ((pixel & 0x0380) >> 5)) << 6;
+ r = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) << 14;
+ return (a | r | g | b);
}
static FASTCALL uint32_t
@@ -897,14 +843,12 @@ fbFetchPixel_x1b5g5r5 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint16_t *) bits + offset);
-
- b = ((pixel & 0x7c00) | ((pixel & 0x7000) >> 5)) >> 7;
- g = ((pixel & 0x03e0) | ((pixel & 0x0380) >> 5)) << 6;
- r = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) << 14;
- return (0xff000000 | r | g | b);
- );
+ uint32_t pixel = READ((uint16_t *) bits + offset);
+
+ b = ((pixel & 0x7c00) | ((pixel & 0x7000) >> 5)) >> 7;
+ g = ((pixel & 0x03e0) | ((pixel & 0x0380) >> 5)) << 6;
+ r = ((pixel & 0x001c) | ((pixel & 0x001f) << 5)) << 14;
+ return (0xff000000 | r | g | b);
}
static FASTCALL uint32_t
@@ -912,15 +856,13 @@ fbFetchPixel_a4r4g4b4 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint16_t *) bits + offset);
-
- a = ((pixel & 0xf000) | ((pixel & 0xf000) >> 4)) << 16;
- r = ((pixel & 0x0f00) | ((pixel & 0x0f00) >> 4)) << 12;
- g = ((pixel & 0x00f0) | ((pixel & 0x00f0) >> 4)) << 8;
- b = ((pixel & 0x000f) | ((pixel & 0x000f) << 4));
- return (a | r | g | b);
- );
+ uint32_t pixel = READ((uint16_t *) bits + offset);
+
+ a = ((pixel & 0xf000) | ((pixel & 0xf000) >> 4)) << 16;
+ r = ((pixel & 0x0f00) | ((pixel & 0x0f00) >> 4)) << 12;
+ g = ((pixel & 0x00f0) | ((pixel & 0x00f0) >> 4)) << 8;
+ b = ((pixel & 0x000f) | ((pixel & 0x000f) << 4));
+ return (a | r | g | b);
}
static FASTCALL uint32_t
@@ -928,14 +870,12 @@ fbFetchPixel_x4r4g4b4 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint16_t *) bits + offset);
-
- r = ((pixel & 0x0f00) | ((pixel & 0x0f00) >> 4)) << 12;
- g = ((pixel & 0x00f0) | ((pixel & 0x00f0) >> 4)) << 8;
- b = ((pixel & 0x000f) | ((pixel & 0x000f) << 4));
- return (0xff000000 | r | g | b);
- );
+ uint32_t pixel = READ((uint16_t *) bits + offset);
+
+ r = ((pixel & 0x0f00) | ((pixel & 0x0f00) >> 4)) << 12;
+ g = ((pixel & 0x00f0) | ((pixel & 0x00f0) >> 4)) << 8;
+ b = ((pixel & 0x000f) | ((pixel & 0x000f) << 4));
+ return (0xff000000 | r | g | b);
}
static FASTCALL uint32_t
@@ -943,15 +883,13 @@ fbFetchPixel_a4b4g4r4 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint16_t *) bits + offset);
-
- a = ((pixel & 0xf000) | ((pixel & 0xf000) >> 4)) << 16;
- b = ((pixel & 0x0f00) | ((pixel & 0x0f00) >> 4)) >> 4;
- g = ((pixel & 0x00f0) | ((pixel & 0x00f0) >> 4)) << 8;
- r = ((pixel & 0x000f) | ((pixel & 0x000f) << 4)) << 16;
- return (a | r | g | b);
- );
+ uint32_t pixel = READ((uint16_t *) bits + offset);
+
+ a = ((pixel & 0xf000) | ((pixel & 0xf000) >> 4)) << 16;
+ b = ((pixel & 0x0f00) | ((pixel & 0x0f00) >> 4)) >> 4;
+ g = ((pixel & 0x00f0) | ((pixel & 0x00f0) >> 4)) << 8;
+ r = ((pixel & 0x000f) | ((pixel & 0x000f) << 4)) << 16;
+ return (a | r | g | b);
}
static FASTCALL uint32_t
@@ -959,25 +897,21 @@ fbFetchPixel_x4b4g4r4 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint16_t *) bits + offset);
-
- b = ((pixel & 0x0f00) | ((pixel & 0x0f00) >> 4)) >> 4;
- g = ((pixel & 0x00f0) | ((pixel & 0x00f0) >> 4)) << 8;
- r = ((pixel & 0x000f) | ((pixel & 0x000f) << 4)) << 16;
- return (0xff000000 | r | g | b);
- );
+ uint32_t pixel = READ((uint16_t *) bits + offset);
+
+ b = ((pixel & 0x0f00) | ((pixel & 0x0f00) >> 4)) >> 4;
+ g = ((pixel & 0x00f0) | ((pixel & 0x00f0) >> 4)) << 8;
+ r = ((pixel & 0x000f) | ((pixel & 0x000f) << 4)) << 16;
+ return (0xff000000 | r | g | b);
}
static FASTCALL uint32_t
fbFetchPixel_a8 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- uint32_t pixel = READ((uint8_t *) bits + offset);
-
- return pixel << 24;
- );
+ uint32_t pixel = READ((uint8_t *) bits + offset);
+
+ return pixel << 24;
}
static FASTCALL uint32_t
@@ -985,17 +919,15 @@ fbFetchPixel_r3g3b2 (pixman_image_t *ima
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint8_t *) bits + offset);
-
- r = ((pixel & 0xe0) | ((pixel & 0xe0) >> 3) | ((pixel & 0xc0) >> 6)) << 16;
- g = ((pixel & 0x1c) | ((pixel & 0x18) >> 3) | ((pixel & 0x1c) << 3)) << 8;
- b = (((pixel & 0x03) ) |
- ((pixel & 0x03) << 2) |
- ((pixel & 0x03) << 4) |
- ((pixel & 0x03) << 6));
- return (0xff000000 | r | g | b);
- );
+ uint32_t pixel = READ((uint8_t *) bits + offset);
+
+ r = ((pixel & 0xe0) | ((pixel & 0xe0) >> 3) | ((pixel & 0xc0) >> 6)) << 16;
+ g = ((pixel & 0x1c) | ((pixel & 0x18) >> 3) | ((pixel & 0x1c) << 3)) << 8;
+ b = (((pixel & 0x03) ) |
+ ((pixel & 0x03) << 2) |
+ ((pixel & 0x03) << 4) |
+ ((pixel & 0x03) << 6));
+ return (0xff000000 | r | g | b);
}
static FASTCALL uint32_t
@@ -1003,19 +935,17 @@ fbFetchPixel_b2g3r3 (pixman_image_t *ima
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint8_t *) bits + offset);
-
- b = (((pixel & 0xc0) ) |
- ((pixel & 0xc0) >> 2) |
- ((pixel & 0xc0) >> 4) |
- ((pixel & 0xc0) >> 6));
- g = ((pixel & 0x38) | ((pixel & 0x38) >> 3) | ((pixel & 0x30) << 2)) << 8;
- r = (((pixel & 0x07) ) |
- ((pixel & 0x07) << 3) |
- ((pixel & 0x06) << 6)) << 16;
- return (0xff000000 | r | g | b);
- );
+ uint32_t pixel = READ((uint8_t *) bits + offset);
+
+ b = (((pixel & 0xc0) ) |
+ ((pixel & 0xc0) >> 2) |
+ ((pixel & 0xc0) >> 4) |
+ ((pixel & 0xc0) >> 6));
+ g = ((pixel & 0x38) | ((pixel & 0x38) >> 3) | ((pixel & 0x30) << 2)) << 8;
+ r = (((pixel & 0x07) ) |
+ ((pixel & 0x07) << 3) |
+ ((pixel & 0x06) << 6)) << 16;
+ return (0xff000000 | r | g | b);
}
static FASTCALL uint32_t
@@ -1023,15 +953,13 @@ fbFetchPixel_a2r2g2b2 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint8_t *) bits + offset);
-
- a = ((pixel & 0xc0) * 0x55) << 18;
- r = ((pixel & 0x30) * 0x55) << 12;
- g = ((pixel & 0x0c) * 0x55) << 6;
- b = ((pixel & 0x03) * 0x55);
- return a|r|g|b;
- );
+ uint32_t pixel = READ((uint8_t *) bits + offset);
+
+ a = ((pixel & 0xc0) * 0x55) << 18;
+ r = ((pixel & 0x30) * 0x55) << 12;
+ g = ((pixel & 0x0c) * 0x55) << 6;
+ b = ((pixel & 0x03) * 0x55);
+ return a|r|g|b;
}
static FASTCALL uint32_t
@@ -1039,36 +967,30 @@ fbFetchPixel_a2b2g2r2 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- uint32_t pixel = READ((uint8_t *) bits + offset);
-
- a = ((pixel & 0xc0) * 0x55) << 18;
- b = ((pixel & 0x30) * 0x55) >> 6;
- g = ((pixel & 0x0c) * 0x55) << 6;
- r = ((pixel & 0x03) * 0x55) << 16;
- return a|r|g|b;
- );
+ uint32_t pixel = READ((uint8_t *) bits + offset);
+
+ a = ((pixel & 0xc0) * 0x55) << 18;
+ b = ((pixel & 0x30) * 0x55) >> 6;
+ g = ((pixel & 0x0c) * 0x55) << 6;
+ r = ((pixel & 0x03) * 0x55) << 16;
+ return a|r|g|b;
}
static FASTCALL uint32_t
fbFetchPixel_c8 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- uint32_t pixel = READ((uint8_t *) bits + offset);
- return indexed->rgba[pixel];
- );
+ uint32_t pixel = READ((uint8_t *) bits + offset);
+ return indexed->rgba[pixel];
}
static FASTCALL uint32_t
fbFetchPixel_x4a4 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- uint32_t pixel = READ((uint8_t *) bits + offset);
-
- return ((pixel & 0xf) | ((pixel & 0xf) << 4)) << 24;
- );
+ uint32_t pixel = READ((uint8_t *) bits + offset);
+
+ return ((pixel & 0xf) | ((pixel & 0xf) << 4)) << 24;
}
#define Fetch8(l,o) (((uint8_t *) (l))[(o) >> 2])
@@ -1082,12 +1004,10 @@ static FASTCALL uint32_t
fbFetchPixel_a4 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- uint32_t pixel = Fetch4(bits, offset);
-
- pixel |= pixel << 4;
- return pixel << 24;
- );
+ uint32_t pixel = Fetch4(bits, offset);
+
+ pixel |= pixel << 4;
+ return pixel << 24;
}
static FASTCALL uint32_t
@@ -1095,14 +1015,12 @@ fbFetchPixel_r1g2b1 (pixman_image_t *ima
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- uint32_t pixel = Fetch4(bits, offset);
-
- r = ((pixel & 0x8) * 0xff) << 13;
- g = ((pixel & 0x6) * 0x55) << 7;
- b = ((pixel & 0x1) * 0xff);
- return 0xff000000|r|g|b;
- );
+ uint32_t pixel = Fetch4(bits, offset);
+
+ r = ((pixel & 0x8) * 0xff) << 13;
+ g = ((pixel & 0x6) * 0x55) << 7;
+ b = ((pixel & 0x1) * 0xff);
+ return 0xff000000|r|g|b;
}
static FASTCALL uint32_t
@@ -1110,14 +1028,12 @@ fbFetchPixel_b1g2r1 (pixman_image_t *ima
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t r,g,b;
- ACCESS_MEM (
- uint32_t pixel = Fetch4(bits, offset);
-
- b = ((pixel & 0x8) * 0xff) >> 3;
- g = ((pixel & 0x6) * 0x55) << 7;
- r = ((pixel & 0x1) * 0xff) << 16;
- return 0xff000000|r|g|b;
- );
+ uint32_t pixel = Fetch4(bits, offset);
+
+ b = ((pixel & 0x8) * 0xff) >> 3;
+ g = ((pixel & 0x6) * 0x55) << 7;
+ r = ((pixel & 0x1) * 0xff) << 16;
+ return 0xff000000|r|g|b;
}
static FASTCALL uint32_t
@@ -1125,15 +1041,13 @@ fbFetchPixel_a1r1g1b1 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- uint32_t pixel = Fetch4(bits, offset);
-
- a = ((pixel & 0x8) * 0xff) << 21;
- r = ((pixel & 0x4) * 0xff) << 14;
- g = ((pixel & 0x2) * 0xff) << 7;
- b = ((pixel & 0x1) * 0xff);
- return a|r|g|b;
- );
+ uint32_t pixel = Fetch4(bits, offset);
+
+ a = ((pixel & 0x8) * 0xff) << 21;
+ r = ((pixel & 0x4) * 0xff) << 14;
+ g = ((pixel & 0x2) * 0xff) << 7;
+ b = ((pixel & 0x1) * 0xff);
+ return a|r|g|b;
}
static FASTCALL uint32_t
@@ -1141,26 +1055,22 @@ fbFetchPixel_a1b1g1r1 (pixman_image_t *i
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
uint32_t a,r,g,b;
- ACCESS_MEM (
- uint32_t pixel = Fetch4(bits, offset);
-
- a = ((pixel & 0x8) * 0xff) << 21;
- r = ((pixel & 0x4) * 0xff) >> 3;
- g = ((pixel & 0x2) * 0xff) << 7;
- b = ((pixel & 0x1) * 0xff) << 16;
- return a|r|g|b;
- );
+ uint32_t pixel = Fetch4(bits, offset);
+
+ a = ((pixel & 0x8) * 0xff) << 21;
+ r = ((pixel & 0x4) * 0xff) >> 3;
+ g = ((pixel & 0x2) * 0xff) << 7;
+ b = ((pixel & 0x1) * 0xff) << 16;
+ return a|r|g|b;
}
static FASTCALL uint32_t
fbFetchPixel_c4 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- uint32_t pixel = Fetch4(bits, offset);
-
- return indexed->rgba[pixel];
- );
+ uint32_t pixel = Fetch4(bits, offset);
+
+ return indexed->rgba[pixel];
}
@@ -1168,37 +1078,33 @@ static FASTCALL uint32_t
fbFetchPixel_a1 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- uint32_t pixel = ((uint32_t *)bits)[offset >> 5];
- uint32_t a;
+ uint32_t pixel = ((uint32_t *)bits)[offset >> 5];
+ uint32_t a;
#if BITMAP_BIT_ORDER == MSBFirst
- a = pixel >> (0x1f - (offset & 0x1f));
+ a = pixel >> (0x1f - (offset & 0x1f));
#else
- a = pixel >> (offset & 0x1f);
+ a = pixel >> (offset & 0x1f);
#endif
- a = a & 1;
- a |= a << 1;
- a |= a << 2;
- a |= a << 4;
- return a << 24;
- );
+ a = a & 1;
+ a |= a << 1;
+ a |= a << 2;
+ a |= a << 4;
+ return a << 24;
}
static FASTCALL uint32_t
fbFetchPixel_g1 (pixman_image_t *image,
const uint32_t *bits, int offset, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- uint32_t pixel = ((uint32_t *)bits)[offset >> 5];
- uint32_t a;
+ uint32_t pixel = ((uint32_t *)bits)[offset >> 5];
+ uint32_t a;
#if BITMAP_BIT_ORDER == MSBFirst
- a = pixel >> (0x1f - (offset & 0x1f));
+ a = pixel >> (0x1f - (offset & 0x1f));
#else
- a = pixel >> (offset & 0x1f);
+ a = pixel >> (offset & 0x1f);
#endif
- a = a & 1;
- return indexed->rgba[a];
- );
+ a = a & 1;
+ return indexed->rgba[a];
}
static fetchPixelProc fetchPixelProcForPicture (bits_image_t * pict)
@@ -1269,45 +1175,37 @@ static FASTCALL void
fbStore_a8r8g8b8 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- MEMCPY_WRAPPED(((uint32_t *)bits) + x, values, width*sizeof(uint32_t));
- );
+ MEMCPY_WRAPPED(((uint32_t *)bits) + x, values, width*sizeof(uint32_t));
}
static FASTCALL void
fbStore_x8r8g8b8 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint32_t *pixel = (uint32_t *)bits + x;
- for (i = 0; i < width; ++i)
- WRITE(pixel++, READ(values + i) & 0xffffff);
- );
+ int i;
+ uint32_t *pixel = (uint32_t *)bits + x;
+ for (i = 0; i < width; ++i)
+ WRITE(pixel++, READ(values + i) & 0xffffff);
}
static FASTCALL void
fbStore_a8b8g8r8 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint32_t *pixel = (uint32_t *)bits + x;
- for (i = 0; i < width; ++i)
- WRITE(pixel++, (READ(values + i) & 0xff00ff00) | ((READ(values + i) >> 16) & 0xff) | ((READ(values + i) & 0xff) << 16));
- );
+ int i;
+ uint32_t *pixel = (uint32_t *)bits + x;
+ for (i = 0; i < width; ++i)
+ WRITE(pixel++, (READ(values + i) & 0xff00ff00) | ((READ(values + i) >> 16) & 0xff) | ((READ(values + i) & 0xff) << 16));
}
static FASTCALL void
fbStore_x8b8g8r8 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint32_t *pixel = (uint32_t *)bits + x;
- for (i = 0; i < width; ++i)
- WRITE(pixel++, (READ(values + i) & 0x0000ff00) | ((READ(values + i) >> 16) & 0xff) | ((READ(values + i) & 0xff) << 16));
- );
+ int i;
+ uint32_t *pixel = (uint32_t *)bits + x;
+ for (i = 0; i < width; ++i)
+ WRITE(pixel++, (READ(values + i) & 0x0000ff00) | ((READ(values + i) >> 16) & 0xff) | ((READ(values + i) & 0xff) << 16));
}
static FASTCALL void
@@ -1315,272 +1213,252 @@ fbStore_r8g8b8 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width,
const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint8_t *pixel = ((uint8_t *) bits) + 3*x;
- for (i = 0; i < width; ++i) {
- Store24(pixel, READ(values + i));
- pixel += 3;
- }
- );
+ int i;
+ uint8_t *pixel = ((uint8_t *) bits) + 3*x;
+ for (i = 0; i < width; ++i) {
+ Store24(pixel, READ(values + i));
+ pixel += 3;
+ }
}
static FASTCALL void
fbStore_b8g8r8 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint8_t *pixel = ((uint8_t *) bits) + 3*x;
- for (i = 0; i < width; ++i) {
- uint32_t val = READ(values + i);
+ int i;
+ uint8_t *pixel = ((uint8_t *) bits) + 3*x;
+ for (i = 0; i < width; ++i) {
+ uint32_t val = READ(values + i);
#if IMAGE_BYTE_ORDER == MSBFirst
- WRITE(pixel++, Blue(val));
- WRITE(pixel++, Green(val));
- WRITE(pixel++, Red(val));
+ WRITE(pixel++, Blue(val));
+ WRITE(pixel++, Green(val));
+ WRITE(pixel++, Red(val));
#else
- WRITE(pixel++, Red(val));
- WRITE(pixel++, Green(val));
- WRITE(pixel++, Blue(val));
+ WRITE(pixel++, Red(val));
+ WRITE(pixel++, Green(val));
+ WRITE(pixel++, Blue(val));
#endif
- }
- );
+ }
}
static FASTCALL void
fbStore_r5g6b5 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint16_t *pixel = ((uint16_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- uint32_t s = READ(values + i);
- WRITE(pixel++, ((s >> 3) & 0x001f) |
- ((s >> 5) & 0x07e0) |
- ((s >> 8) & 0xf800));
- });
+ int i;
+ uint16_t *pixel = ((uint16_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ uint32_t s = READ(values + i);
+ WRITE(pixel++, ((s >> 3) & 0x001f) |
+ ((s >> 5) & 0x07e0) |
+ ((s >> 8) & 0xf800));
+ }
}
static FASTCALL void
fbStore_b5g6r5 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint16_t *pixel = ((uint16_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Split(READ(values + i));
- WRITE(pixel++, ((b << 8) & 0xf800) |
- ((g << 3) & 0x07e0) |
- ((r >> 3) ));
- });
+ int i;
+ uint16_t *pixel = ((uint16_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Split(READ(values + i));
+ WRITE(pixel++, ((b << 8) & 0xf800) |
+ ((g << 3) & 0x07e0) |
+ ((r >> 3) ));
+ }
}
static FASTCALL void
fbStore_a1r5g5b5 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint16_t *pixel = ((uint16_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Splita(READ(values + i));
- WRITE(pixel++, ((a << 8) & 0x8000) |
- ((r << 7) & 0x7c00) |
- ((g << 2) & 0x03e0) |
- ((b >> 3) ));
- });
+ int i;
+ uint16_t *pixel = ((uint16_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Splita(READ(values + i));
+ WRITE(pixel++, ((a << 8) & 0x8000) |
+ ((r << 7) & 0x7c00) |
+ ((g << 2) & 0x03e0) |
+ ((b >> 3) ));
+ }
}
static FASTCALL void
fbStore_x1r5g5b5 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint16_t *pixel = ((uint16_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Split(READ(values + i));
- WRITE(pixel++, ((r << 7) & 0x7c00) |
- ((g << 2) & 0x03e0) |
- ((b >> 3) ));
- });
+ int i;
+ uint16_t *pixel = ((uint16_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Split(READ(values + i));
+ WRITE(pixel++, ((r << 7) & 0x7c00) |
+ ((g << 2) & 0x03e0) |
+ ((b >> 3) ));
+ }
}
static FASTCALL void
fbStore_a1b5g5r5 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint16_t *pixel = ((uint16_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Splita(READ(values + i));
- WRITE(pixel++, ((a << 8) & 0x8000) |
- ((b << 7) & 0x7c00) |
- ((g << 2) & 0x03e0) |
- ((r >> 3) ));
- });
+ int i;
+ uint16_t *pixel = ((uint16_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Splita(READ(values + i));
+ WRITE(pixel++, ((a << 8) & 0x8000) |
+ ((b << 7) & 0x7c00) |
+ ((g << 2) & 0x03e0) |
+ ((r >> 3) ));
+ }
}
static FASTCALL void
fbStore_x1b5g5r5 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint16_t *pixel = ((uint16_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Split(READ(values + i));
- WRITE(pixel++, ((b << 7) & 0x7c00) |
- ((g << 2) & 0x03e0) |
- ((r >> 3) ));
- });
+ int i;
+ uint16_t *pixel = ((uint16_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Split(READ(values + i));
+ WRITE(pixel++, ((b << 7) & 0x7c00) |
+ ((g << 2) & 0x03e0) |
+ ((r >> 3) ));
+ }
}
static FASTCALL void
fbStore_a4r4g4b4 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint16_t *pixel = ((uint16_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Splita(READ(values + i));
- WRITE(pixel++, ((a << 8) & 0xf000) |
- ((r << 4) & 0x0f00) |
- ((g ) & 0x00f0) |
- ((b >> 4) ));
- });
+ int i;
+ uint16_t *pixel = ((uint16_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Splita(READ(values + i));
+ WRITE(pixel++, ((a << 8) & 0xf000) |
+ ((r << 4) & 0x0f00) |
+ ((g ) & 0x00f0) |
+ ((b >> 4) ));
+ }
}
static FASTCALL void
fbStore_x4r4g4b4 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint16_t *pixel = ((uint16_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Split(READ(values + i));
- WRITE(pixel++, ((r << 4) & 0x0f00) |
- ((g ) & 0x00f0) |
- ((b >> 4) ));
- });
+ int i;
+ uint16_t *pixel = ((uint16_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Split(READ(values + i));
+ WRITE(pixel++, ((r << 4) & 0x0f00) |
+ ((g ) & 0x00f0) |
+ ((b >> 4) ));
+ }
}
static FASTCALL void
fbStore_a4b4g4r4 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint16_t *pixel = ((uint16_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Splita(READ(values + i));
- WRITE(pixel++, ((a << 8) & 0xf000) |
- ((b << 4) & 0x0f00) |
- ((g ) & 0x00f0) |
- ((r >> 4) ));
- });
+ int i;
+ uint16_t *pixel = ((uint16_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Splita(READ(values + i));
+ WRITE(pixel++, ((a << 8) & 0xf000) |
+ ((b << 4) & 0x0f00) |
+ ((g ) & 0x00f0) |
+ ((r >> 4) ));
+ }
}
static FASTCALL void
fbStore_x4b4g4r4 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint16_t *pixel = ((uint16_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Split(READ(values + i));
- WRITE(pixel++, ((b << 4) & 0x0f00) |
- ((g ) & 0x00f0) |
- ((r >> 4) ));
- });
+ int i;
+ uint16_t *pixel = ((uint16_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Split(READ(values + i));
+ WRITE(pixel++, ((b << 4) & 0x0f00) |
+ ((g ) & 0x00f0) |
+ ((r >> 4) ));
+ }
}
static FASTCALL void
fbStore_a8 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint8_t *pixel = ((uint8_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- WRITE(pixel++, READ(values + i) >> 24);
- });
+ int i;
+ uint8_t *pixel = ((uint8_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ WRITE(pixel++, READ(values + i) >> 24);
+ }
}
static FASTCALL void
fbStore_r3g3b2 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint8_t *pixel = ((uint8_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Split(READ(values + i));
- WRITE(pixel++, ((r ) & 0xe0) |
- ((g >> 3) & 0x1c) |
- ((b >> 6) ));
- });
+ int i;
+ uint8_t *pixel = ((uint8_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Split(READ(values + i));
+ WRITE(pixel++, ((r ) & 0xe0) |
+ ((g >> 3) & 0x1c) |
+ ((b >> 6) ));
+ }
}
static FASTCALL void
fbStore_b2g3r3 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint8_t *pixel = ((uint8_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Split(READ(values + i));
- WRITE(pixel++, ((b ) & 0xe0) |
- ((g >> 3) & 0x1c) |
- ((r >> 6) ));
- });
+ int i;
+ uint8_t *pixel = ((uint8_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Split(READ(values + i));
+ WRITE(pixel++, ((b ) & 0xe0) |
+ ((g >> 3) & 0x1c) |
+ ((r >> 6) ));
+ }
}
static FASTCALL void
fbStore_a2r2g2b2 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint8_t *pixel = ((uint8_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- Splita(READ(values + i));
- WRITE(pixel++, ((a ) & 0xc0) |
- ((r >> 2) & 0x30) |
- ((g >> 4) & 0x0c) |
- ((b >> 6) ));
- });
+ int i;
+ uint8_t *pixel = ((uint8_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ Splita(READ(values + i));
+ WRITE(pixel++, ((a ) & 0xc0) |
+ ((r >> 2) & 0x30) |
+ ((g >> 4) & 0x0c) |
+ ((b >> 6) ));
+ }
}
static FASTCALL void
fbStore_c8 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint8_t *pixel = ((uint8_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- WRITE(pixel++, miIndexToEnt24(indexed,READ(values + i)));
- });
+ int i;
+ uint8_t *pixel = ((uint8_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ WRITE(pixel++, miIndexToEnt24(indexed,READ(values + i)));
+ }
}
static FASTCALL void
fbStore_x4a4 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- uint8_t *pixel = ((uint8_t *) bits) + x;
- for (i = 0; i < width; ++i) {
- WRITE(pixel++, READ(values + i) >> 28);
- });
+ int i;
+ uint8_t *pixel = ((uint8_t *) bits) + x;
+ for (i = 0; i < width; ++i) {
+ WRITE(pixel++, READ(values + i) >> 28);
+ }
}
#define Store8(l,o,v) (((uint8_t *) l)[(o) >> 3] = (v))
@@ -1598,123 +1476,115 @@ static FASTCALL void
fbStore_a4 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- Store4(bits, i + x, READ(values + i)>>28);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ Store4(bits, i + x, READ(values + i)>>28);
+ }
}
static FASTCALL void
fbStore_r1g2b1 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t pixel;
-
- Split(READ(values + i));
- pixel = (((r >> 4) & 0x8) |
- ((g >> 5) & 0x6) |
- ((b >> 7) ));
- Store4(bits, i + x, pixel);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t pixel;
+
+ Split(READ(values + i));
+ pixel = (((r >> 4) & 0x8) |
+ ((g >> 5) & 0x6) |
+ ((b >> 7) ));
+ Store4(bits, i + x, pixel);
+ }
}
static FASTCALL void
fbStore_b1g2r1 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t pixel;
-
- Split(READ(values + i));
- pixel = (((b >> 4) & 0x8) |
- ((g >> 5) & 0x6) |
- ((r >> 7) ));
- Store4(bits, i + x, pixel);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t pixel;
+
+ Split(READ(values + i));
+ pixel = (((b >> 4) & 0x8) |
+ ((g >> 5) & 0x6) |
+ ((r >> 7) ));
+ Store4(bits, i + x, pixel);
+ }
}
static FASTCALL void
fbStore_a1r1g1b1 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t pixel;
- Splita(READ(values + i));
- pixel = (((a >> 4) & 0x8) |
- ((r >> 5) & 0x4) |
- ((g >> 6) & 0x2) |
- ((b >> 7) ));
- Store4(bits, i + x, pixel);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t pixel;
+ Splita(READ(values + i));
+ pixel = (((a >> 4) & 0x8) |
+ ((r >> 5) & 0x4) |
+ ((g >> 6) & 0x2) |
+ ((b >> 7) ));
+ Store4(bits, i + x, pixel);
+ }
}
static FASTCALL void
fbStore_a1b1g1r1 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t pixel;
- Splita(READ(values + i));
- pixel = (((a >> 4) & 0x8) |
- ((b >> 5) & 0x4) |
- ((g >> 6) & 0x2) |
- ((r >> 7) ));
- Store4(bits, i + x, pixel);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t pixel;
+ Splita(READ(values + i));
+ pixel = (((a >> 4) & 0x8) |
+ ((b >> 5) & 0x4) |
+ ((g >> 6) & 0x2) |
+ ((r >> 7) ));
+ Store4(bits, i + x, pixel);
+ }
}
static FASTCALL void
fbStore_c4 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t pixel;
-
- pixel = miIndexToEnt24(indexed, READ(values + i));
- Store4(bits, i + x, pixel);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t pixel;
+
+ pixel = miIndexToEnt24(indexed, READ(values + i));
+ Store4(bits, i + x, pixel);
+ }
}
static FASTCALL void
fbStore_a1 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t *pixel = ((uint32_t *) bits) + ((i+x) >> 5);
- uint32_t mask = FbStipMask((i+x) & 0x1f, 1);
-
- uint32_t v = READ(values + i) & 0x80000000 ? mask : 0;
- WRITE(pixel, (READ(pixel) & ~mask) | v);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t *pixel = ((uint32_t *) bits) + ((i+x) >> 5);
+ uint32_t mask = FbStipMask((i+x) & 0x1f, 1);
+
+ uint32_t v = READ(values + i) & 0x80000000 ? mask : 0;
+ WRITE(pixel, (READ(pixel) & ~mask) | v);
+ }
}
static FASTCALL void
fbStore_g1 (pixman_image_t *image,
uint32_t *bits, const uint32_t *values, int x, int width, const pixman_indexed_t * indexed)
{
- ACCESS_MEM (
- int i;
- for (i = 0; i < width; ++i) {
- uint32_t *pixel = ((uint32_t *) bits) + ((i+x) >> 5);
- uint32_t mask = FbStipMask((i+x) & 0x1f, 1);
-
- uint32_t v = miIndexToEntY24(indexed,READ(values + i)) ? mask : 0;
- WRITE(pixel, (READ(pixel) & ~mask) | v);
- });
+ int i;
+ for (i = 0; i < width; ++i) {
+ uint32_t *pixel = ((uint32_t *) bits) + ((i+x) >> 5);
+ uint32_t mask = FbStipMask((i+x) & 0x1f, 1);
+
+ uint32_t v = miIndexToEntY24(indexed,READ(values + i)) ? mask : 0;
+ WRITE(pixel, (READ(pixel) & ~mask) | v);
+ }
}
diff --git a/pixman/pixman-edge-imp.h b/pixman/pixman-edge-imp.h
index f87bea4..5655318 100644
--- a/pixman/pixman-edge-imp.h
+++ b/pixman/pixman-edge-imp.h
@@ -76,7 +76,6 @@ rasterizeEdges (pixman_image_t *image,
x &= FB_MASK;
FbMaskBits (x, width, startmask, nmiddle, endmask);
- ACCESS_MEM(
if (startmask) {
WRITE(a, READ(a) | startmask);
a++;
@@ -85,7 +84,6 @@ rasterizeEdges (pixman_image_t *image,
WRITE(a++, FB_ALLONES);
if (endmask)
WRITE(a, READ(a) | endmask);
- );
}
#else
{
@@ -98,29 +96,28 @@ rasterizeEdges (pixman_image_t *image,
rxs = RenderSamplesX (rx, N_BITS);
/* Add coverage across row */
- ACCESS_MEM(
- if (lxi == rxi)
+ if (lxi == rxi)
+ {
+ AddAlpha (rxs - lxs);
+ }
+ else
+ {
+ int xi;
+
+ AddAlpha (N_X_FRAC(N_BITS) - lxs);
+ StepAlpha;
+ for (xi = lxi + 1; xi < rxi; xi++)
{
- AddAlpha (rxs - lxs);
- }
- else
- {
- int xi;
-
- AddAlpha (N_X_FRAC(N_BITS) - lxs);
+ AddAlpha (N_X_FRAC(N_BITS));
StepAlpha;
- for (xi = lxi + 1; xi < rxi; xi++)
- {
- AddAlpha (N_X_FRAC(N_BITS));
- StepAlpha;
- }
- /* Do not add in a 0 alpha here. This check is necessary
- * to avoid a buffer overrun when rx is exactly on a pixel
- * boundary.
- */
- if (rxs != 0)
- AddAlpha (rxs);
- });
+ }
+ /* Do not add in a 0 alpha here. This check is necessary
+ * to avoid a buffer overrun when rx is exactly on a pixel
+ * boundary.
+ */
+ if (rxs != 0)
+ AddAlpha (rxs);
+ }
}
#endif
}
diff --git a/pixman/pixman-edge.c b/pixman/pixman-edge.c
index bfa34e3..1b28550 100644
--- a/pixman/pixman-edge.c
+++ b/pixman/pixman-edge.c
@@ -48,17 +48,17 @@
#define Get4(x,o) (((x) >> Shift4(o)) & 0xf)
#define Put4(x,o,v) (((x) & ~(0xf << Shift4(o))) | (((v) & 0xf) << Shift4(o)))
-#define DefineAlpha(line,x) \
+#define DefineAlpha(line,x) \
uint8_t *__ap = (uint8_t *) line + ((x) >> 1); \
int __ao = (x) & 1
#define StepAlpha ((__ap += __ao), (__ao ^= 1))
#define AddAlpha(a) { \
- uint8_t __o = READ(__ap); \
- uint8_t __a = (a) + Get4(__o, __ao); \
- WRITE(__ap, Put4 (__o, __ao, __a | (0 - ((__a) >> 4)))); \
-}
+ uint8_t __o = READ(__ap); \
+ uint8_t __a = (a) + Get4(__o, __ao); \
+ WRITE(__ap, Put4 (__o, __ao, __a | (0 - ((__a) >> 4)))); \
+ }
#include "pixman-edge-imp.h"
@@ -130,9 +130,9 @@ fbRasterizeEdges8 (pixman_image_t
uint32_t *buf = (image)->bits.bits;
uint32_t stride = (image)->bits.rowstride;
uint32_t width = (image)->bits.width;
-
+
line = buf + pixman_fixed_to_int (y) * stride;
-
+
for (;;)
{
uint8_t *ap = (uint8_t *) line;
@@ -151,114 +151,112 @@ fbRasterizeEdges8 (pixman_image_t
if (rx > lx)
{
int lxs, rxs;
-
+
/* Find pixel bounds for span. */
lxi = pixman_fixed_to_int (lx);
rxi = pixman_fixed_to_int (rx);
-
+
/* Sample coverage for edge pixels */
lxs = RenderSamplesX (lx, 8);
rxs = RenderSamplesX (rx, 8);
-
+
/* Add coverage across row */
- ACCESS_MEM (
- if (lxi == rxi)
+ if (lxi == rxi)
+ {
+ WRITE(ap +lxi, clip255 (READ(ap + lxi) + rxs - lxs));
+ }
+ else
+ {
+ WRITE(ap + lxi, clip255 (READ(ap + lxi) + N_X_FRAC(8) - lxs));
+
+ /* Move forward so that lxi/rxi is the pixel span */
+ lxi++;
+
+ /* Don't bother trying to optimize the fill unless
+ * the span is longer than 4 pixels. */
+ if (rxi - lxi > 4)
{
- WRITE(ap +lxi, clip255 (READ(ap + lxi) + rxs - lxs));
- }
- else
- {
- WRITE(ap + lxi, clip255 (READ(ap + lxi) + N_X_FRAC(8) - lxs));
-
- /* Move forward so that lxi/rxi is the pixel span */
- lxi++;
-
- /* Don't bother trying to optimize the fill unless
- * the span is longer than 4 pixels. */
- if (rxi - lxi > 4)
+ if (fill_start < 0)
+ {
+ fill_start = lxi;
+ fill_end = rxi;
+ fill_size++;
+ }
+ else
{
- if (fill_start < 0)
+ if (lxi >= fill_end || rxi < fill_start)
{
+ /* We're beyond what we saved, just fill it */
+ add_saturate_8 (ap + fill_start,
+ fill_size * N_X_FRAC(8),
+ fill_end - fill_start);
fill_start = lxi;
fill_end = rxi;
- fill_size++;
+ fill_size = 1;
}
else
{
- if (lxi >= fill_end || rxi < fill_start)
+ /* Update fill_start */
+ if (lxi > fill_start)
{
- /* We're beyond what we saved, just fill it */
add_saturate_8 (ap + fill_start,
fill_size * N_X_FRAC(8),
- fill_end - fill_start);
+ lxi - fill_start);
fill_start = lxi;
+ }
+ else if (lxi < fill_start)
+ {
+ add_saturate_8 (ap + lxi, N_X_FRAC(8),
+ fill_start - lxi);
+ }
+
+ /* Update fill_end */
+ if (rxi < fill_end)
+ {
+ add_saturate_8 (ap + rxi,
+ fill_size * N_X_FRAC(8),
+ fill_end - rxi);
fill_end = rxi;
- fill_size = 1;
}
- else
+ else if (fill_end < rxi)
{
- /* Update fill_start */
- if (lxi > fill_start)
- {
- add_saturate_8 (ap + fill_start,
- fill_size * N_X_FRAC(8),
- lxi - fill_start);
- fill_start = lxi;
- }
- else if (lxi < fill_start)
- {
- add_saturate_8 (ap + lxi, N_X_FRAC(8),
- fill_start - lxi);
- }
-
- /* Update fill_end */
- if (rxi < fill_end)
- {
- add_saturate_8 (ap + rxi,
- fill_size * N_X_FRAC(8),
- fill_end - rxi);
- fill_end = rxi;
- }
- else if (fill_end < rxi)
- {
- add_saturate_8 (ap + fill_end,
- N_X_FRAC(8),
- rxi - fill_end);
- }
- fill_size++;
+ add_saturate_8 (ap + fill_end,
+ N_X_FRAC(8),
+ rxi - fill_end);
}
+ fill_size++;
}
}
- else
- {
- add_saturate_8 (ap + lxi, N_X_FRAC(8), rxi - lxi);
- }
-
- /* Do not add in a 0 alpha here. This check is
- * necessary to avoid a buffer overrun, (when rx
- * is exactly on a pixel boundary). */
- if (rxs)
- WRITE(ap + rxi, clip255 (READ(ap + rxi) + rxs));
- });
+ }
+ else
+ {
+ add_saturate_8 (ap + lxi, N_X_FRAC(8), rxi - lxi);
+ }
+
+ /* Do not add in a 0 alpha here. This check is
+ * necessary to avoid a buffer overrun, (when rx
+ * is exactly on a pixel boundary). */
+ if (rxs)
+ WRITE(ap + rxi, clip255 (READ(ap + rxi) + rxs));
+ }
}
-
+
if (y == b) {
/* We're done, make sure we clean up any remaining fill. */
if (fill_start != fill_end) {
- ACCESS_MEM(
- if (fill_size == N_Y_FRAC(8))
- {
- MEMSET_WRAPPED (ap + fill_start, 0xff, fill_end - fill_start);
- }
- else
- {
- add_saturate_8 (ap + fill_start, fill_size * N_X_FRAC(8),
- fill_end - fill_start);
- });
+ if (fill_size == N_Y_FRAC(8))
+ {
+ MEMSET_WRAPPED (ap + fill_start, 0xff, fill_end - fill_start);
+ }
+ else
+ {
+ add_saturate_8 (ap + fill_start, fill_size * N_X_FRAC(8),
+ fill_end - fill_start);
+ }
}
break;
}
-
+
if (pixman_fixed_frac (y) != Y_FRAC_LAST(8))
{
RenderEdgeStepSmall (l);
@@ -272,16 +270,15 @@ fbRasterizeEdges8 (pixman_image_t
y += STEP_Y_BIG(8);
if (fill_start != fill_end)
{
- ACCESS_MEM(
- if (fill_size == N_Y_FRAC(8))
- {
- MEMSET_WRAPPED (ap + fill_start, 0xff, fill_end - fill_start);
- }
- else
- {
- add_saturate_8 (ap + fill_start, fill_size * N_X_FRAC(8),
- fill_end - fill_start);
- });
+ if (fill_size == N_Y_FRAC(8))
+ {
+ MEMSET_WRAPPED (ap + fill_start, 0xff, fill_end - fill_start);
+ }
+ else
+ {
+ add_saturate_8 (ap + fill_start, fill_size * N_X_FRAC(8),
+ fill_end - fill_start);
+ }
fill_start = fill_end = -1;
fill_size = 0;
}
diff --git a/pixman/pixman-private.h b/pixman/pixman-private.h
index 222e4cc..e29ef6d 100644
--- a/pixman/pixman-private.h
+++ b/pixman/pixman-private.h
@@ -572,6 +572,7 @@ union pixman_image
* where Fetch4 doesn't have a READ
*/
+#if 0
/* Framebuffer access support macros */
#define ACCESS_MEM(code) \
do { \
@@ -603,48 +604,48 @@ union pixman_image
{code} \
} \
} while (0)
+#endif
-#define READ(ptr) \
- (do_access__? read_func__ ((ptr), sizeof(*(ptr))) : (*(ptr)))
+#ifdef PIXMAN_FB_ACCESSORS
-#define WRITE(ptr, val) \
- (do_access__? \
- write_func__ ((ptr), (val), sizeof(*(ptr))) \
- : ((void)(*(ptr) = (val))))
+#define READ(ptr) \
+ (image->common.read_func ((ptr), sizeof(*(ptr))))
+#define WRITE(ptr,val) \
+ (image->common.write_func ((ptr), (val), sizeof (*(ptr))))
#define MEMCPY_WRAPPED(dst, src, size) \
- do { \
- if (do_access__) \
- { \
- size_t _i; \
- uint8_t *_dst = (uint8_t*)(dst), *_src = (uint8_t*)(src); \
- for(_i = 0; _i < size; _i++) { \
- WRITE(_dst +_i, READ(_src + _i)); \
- } \
- } \
- else \
- { \
- memcpy((dst), (src), (size)); \
+ do { \
+ size_t _i; \
+ uint8_t *_dst = (uint8_t*)(dst), *_src = (uint8_t*)(src); \
+ for(_i = 0; _i < size; _i++) { \
+ WRITE(_dst +_i, READ(_src + _i)); \
} \
} while (0)
#define MEMSET_WRAPPED(dst, val, size) \
do { \
- if (do_access__) \
- { \
- size_t _i; \
- uint8_t *_dst = (uint8_t*)(dst); \
- for(_i = 0; _i < size; _i++) { \
- WRITE(_dst +_i, (val)); \
- } \
- } \
- else \
- { \
- memset ((dst), (val), (size)); \
+ size_t _i; \
+ uint8_t *_dst = (uint8_t*)(dst); \
+ for(_i = 0; _i < size; _i++) { \
+ WRITE(_dst +_i, (val)); \
} \
} while (0)
-#define fbFinishAccess(x)
+/* FIXME */
+#define fbPrepareAccess(x)
+#define fbFinishAccess(x)
+
+#else
+
+#define READ(ptr) (*(ptr))
+#define WRITE(ptr, val) (*(ptr) = (val))
+#define MEMCPY_WRAPPED(dst, src, size) \
+ memcpy(dst, src, size)
+#define MEMSET_WRAPPED(dst, val, size) \
+ memset(dst, val, size)
+#define fbPrepareAccess(x)
+#define fbFinishAccess(x)
+#endif
#define fbComposeGetSolid(img, res, fmt) \
do \
More information about the xorg-commit
mailing list