VirtualBox

source: vbox/trunk/src/VBox/Additions/x11/x11include/xorg-server-1.0.1/cfbrrop24.h

Last change on this file was 51223, checked in by vboxsync, 11 years ago

Additions/x11/x11include: added header files for X.Org Server 1.0 and 1.1.

  • Property svn:eol-style set to native
File size: 1.9 KB
Line 
1/* $XFree86: xc/programs/Xserver/cfb24/cfbrrop24.h,v 3.1tsi Exp $ */
2
3#define RROP_DECLARE \
4 unsigned long piQxelAnd[3], piQxelXor[3], spiQxelXor[8];
5
6#define RROP_COPY_SETUP(ptn) \
7 spiQxelXor[0] = ptn & 0xFFFFFF; \
8 spiQxelXor[2] = ptn << 24; \
9 spiQxelXor[3] = (ptn & 0xFFFF00)>> 8; \
10 spiQxelXor[4] = ptn << 16; \
11 spiQxelXor[5] = (ptn & 0xFF0000)>> 16; \
12 spiQxelXor[6] = ptn << 8; \
13 spiQxelXor[1] = spiQxelXor[7] = 0;
14
15#define RROP_SOLID24_COPY(dst,index) {\
16 register int idx = ((index) & 3)<< 1; \
17 *(dst) = (*(dst) & cfbrmask[idx])|spiQxelXor[idx]; \
18 idx++; \
19 *((dst)+1) = (*((dst)+1) & cfbrmask[idx])|spiQxelXor[idx]; \
20 }
21
22#define RROP_SET_SETUP(xor, and) \
23 spiQxelXor[0] = xor & 0xFFFFFF; \
24 spiQxelXor[1] = xor << 24; \
25 spiQxelXor[2] = xor << 16; \
26 spiQxelXor[3] = xor << 8; \
27 spiQxelXor[4] = (xor >> 8) & 0xFFFF; \
28 spiQxelXor[5] = (xor >> 16) & 0xFF; \
29 piQxelAnd[0] = (and & 0xFFFFFF)|(and << 24); \
30 piQxelAnd[1] = (and << 16)|((and >> 8) & 0xFFFF); \
31 piQxelAnd[2] = (and << 8)|((and >> 16) & 0xFF); \
32 piQxelXor[0] = (xor & 0xFFFFFF)|(xor << 24); \
33 piQxelXor[1] = (xor << 16)|((xor >> 8) & 0xFFFF); \
34 piQxelXor[2] = (xor << 8)|((xor >> 16) & 0xFF);
35
36
37#define RROP_SOLID24_SET(dst,index) {\
38 switch((index) & 3){ \
39 case 0: \
40 *(dst) = ((*(dst) & (piQxelAnd[0] |0xFF000000))^(piQxelXor[0] & 0xFFFFFF)); \
41 break; \
42 case 3: \
43 *(dst) = ((*(dst) & (piQxelAnd[2]|0xFF))^(piQxelXor[2] & 0xFFFFFF00)); \
44 break; \
45 case 1: \
46 *(dst) = ((*(dst) & (piQxelAnd[0]|0xFFFFFF))^(piQxelXor[0] & 0xFF000000)); \
47 *((dst)+1) = ((*((dst)+1) & (piQxelAnd[1]|0xFFFF0000))^(piQxelXor[1] & 0xFFFF)); \
48 break; \
49 case 2: \
50 *(dst) = ((*(dst) & (piQxelAnd[1]|0xFFFF))^(piQxelXor[1] & 0xFFFF0000)); \
51 *((dst)+1) = ((*((dst)+1) & (piQxelAnd[2]|0xFFFFFF00))^(piQxelXor[2] & 0xFF)); \
52 break; \
53 } \
54 }
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette