VirtualBox

source: vbox/trunk/src/VBox/Additions/x11/x11include/xorg-server-1.10.0/xaalocal.h@ 107044

Last change on this file since 107044 was 36308, checked in by vboxsync, 14 years ago

fix OSE

  • Property svn:eol-style set to native
File size: 37.4 KB
Line 
1
2#ifndef _XAALOCAL_H
3#define _XAALOCAL_H
4
5/* This file is very unorganized ! */
6
7
8#include "gcstruct.h"
9#include "regionstr.h"
10#include "xf86fbman.h"
11#include "xaa.h"
12#include "mi.h"
13#include "picturestr.h"
14
15#define GCWhenForced (GCArcMode << 1)
16
17#define DO_COLOR_8x8 0x00000001
18#define DO_MONO_8x8 0x00000002
19#define DO_CACHE_BLT 0x00000003
20#define DO_COLOR_EXPAND 0x00000004
21#define DO_CACHE_EXPAND 0x00000005
22#define DO_IMAGE_WRITE 0x00000006
23#define DO_PIXMAP_COPY 0x00000007
24#define DO_SOLID 0x00000008
25
26
27typedef CARD32 * (*GlyphScanlineFuncPtr)(
28 CARD32 *base, unsigned int **glyphp, int line, int nglyph, int width
29);
30
31typedef CARD32 *(*StippleScanlineProcPtr)(CARD32*, CARD32*, int, int, int);
32
33typedef void (*RectFuncPtr) (ScrnInfoPtr, int, int, int, int, int, int,
34 XAACacheInfoPtr);
35typedef void (*TrapFuncPtr) (ScrnInfoPtr, int, int, int, int, int, int,
36 int, int, int, int, int, int,
37 XAACacheInfoPtr);
38
39
40
41typedef struct _XAAScreen {
42 CreateGCProcPtr CreateGC;
43 CloseScreenProcPtr CloseScreen;
44 GetImageProcPtr GetImage;
45 GetSpansProcPtr GetSpans;
46 CopyWindowProcPtr CopyWindow;
47 WindowExposuresProcPtr WindowExposures;
48 CreatePixmapProcPtr CreatePixmap;
49 DestroyPixmapProcPtr DestroyPixmap;
50 ChangeWindowAttributesProcPtr ChangeWindowAttributes;
51 XAAInfoRecPtr AccelInfoRec;
52 Bool (*EnterVT)(int, int);
53 void (*LeaveVT)(int, int);
54 int (*SetDGAMode)(int, int, DGADevicePtr);
55 void (*EnableDisableFBAccess)(int, Bool);
56 CompositeProcPtr Composite;
57 GlyphsProcPtr Glyphs;
58} XAAScreenRec, *XAAScreenPtr;
59
60#define OPS_ARE_PIXMAP 0x00000001
61#define OPS_ARE_ACCEL 0x00000002
62
63typedef struct _XAAGC {
64 GCOps *wrapOps;
65 GCFuncs *wrapFuncs;
66 GCOps *XAAOps;
67 int DashLength;
68 unsigned char* DashPattern;
69 unsigned long changes;
70 unsigned long flags;
71} XAAGCRec, *XAAGCPtr;
72
73#define REDUCIBILITY_CHECKED 0x00000001
74#define REDUCIBLE_TO_8x8 0x00000002
75#define REDUCIBLE_TO_2_COLOR 0x00000004
76#define DIRTY 0x00010000
77#define OFFSCREEN 0x00020000
78#define DGA_PIXMAP 0x00040000
79#define SHARED_PIXMAP 0x00080000
80#define LOCKED_PIXMAP 0x00100000
81
82#define REDUCIBILITY_MASK \
83 (REDUCIBILITY_CHECKED | REDUCIBLE_TO_8x8 | REDUCIBLE_TO_2_COLOR)
84
85typedef struct _XAAPixmap {
86 unsigned long flags;
87 CARD32 pattern0;
88 CARD32 pattern1;
89 int fg;
90 int bg;
91 FBAreaPtr offscreenArea;
92 Bool freeData;
93} XAAPixmapRec, *XAAPixmapPtr;
94
95
96extern _X_EXPORT Bool
97XAACreateGC(
98 GCPtr pGC
99);
100
101extern _X_EXPORT Bool
102XAAInitAccel(
103 ScreenPtr pScreen,
104 XAAInfoRecPtr infoRec
105);
106
107extern _X_EXPORT RegionPtr
108XAABitBlt(
109 DrawablePtr pSrcDrawable,
110 DrawablePtr pDstDrawable,
111 GC *pGC,
112 int srcx,
113 int srcy,
114 int width,
115 int height,
116 int dstx,
117 int dsty,
118 void (*doBitBlt)(DrawablePtr, DrawablePtr, GCPtr, RegionPtr, DDXPointPtr),
119 unsigned long bitPlane
120);
121
122extern _X_EXPORT void
123XAAScreenToScreenBitBlt(
124 ScrnInfoPtr pScrn,
125 int nbox,
126 DDXPointPtr pptSrc,
127 BoxPtr pbox,
128 int xdir,
129 int ydir,
130 int alu,
131 unsigned int planemask
132);
133
134extern _X_EXPORT void
135XAADoBitBlt(
136 DrawablePtr pSrc,
137 DrawablePtr pDst,
138 GC *pGC,
139 RegionPtr prgnDst,
140 DDXPointPtr pptSrc
141);
142
143extern _X_EXPORT void
144XAADoImageWrite(
145 DrawablePtr pSrc,
146 DrawablePtr pDst,
147 GC *pGC,
148 RegionPtr prgnDst,
149 DDXPointPtr pptSrc
150);
151
152extern _X_EXPORT void
153XAADoImageRead(
154 DrawablePtr pSrc,
155 DrawablePtr pDst,
156 GC *pGC,
157 RegionPtr prgnDst,
158 DDXPointPtr pptSrc
159);
160
161extern _X_EXPORT void
162XAACopyWindow(
163 WindowPtr pWin,
164 DDXPointRec ptOldOrg,
165 RegionPtr prgnSrc
166);
167
168
169extern _X_EXPORT RegionPtr
170XAACopyArea(
171 DrawablePtr pSrcDrawable,
172 DrawablePtr pDstDrawable,
173 GC *pGC,
174 int srcx,
175 int srcy,
176 int width,
177 int height,
178 int dstx,
179 int dsty
180);
181
182extern _X_EXPORT void
183XAAValidateCopyArea(
184 GCPtr pGC,
185 unsigned long changes,
186 DrawablePtr pDraw
187);
188
189extern _X_EXPORT void
190XAAValidatePutImage(
191 GCPtr pGC,
192 unsigned long changes,
193 DrawablePtr pDraw
194);
195
196extern _X_EXPORT void
197XAAValidateCopyPlane(
198 GCPtr pGC,
199 unsigned long changes,
200 DrawablePtr pDraw
201);
202
203extern _X_EXPORT void
204XAAValidatePushPixels(
205 GCPtr pGC,
206 unsigned long changes,
207 DrawablePtr pDraw
208);
209
210extern _X_EXPORT void
211XAAValidateFillSpans(
212 GCPtr pGC,
213 unsigned long changes,
214 DrawablePtr pDraw
215);
216
217extern _X_EXPORT void
218XAAValidatePolyGlyphBlt(
219 GCPtr pGC,
220 unsigned long changes,
221 DrawablePtr pDraw
222);
223
224extern _X_EXPORT void
225XAAValidateImageGlyphBlt(
226 GCPtr pGC,
227 unsigned long changes,
228 DrawablePtr pDraw
229);
230
231extern _X_EXPORT void
232XAAValidatePolylines(
233 GCPtr pGC,
234 unsigned long changes,
235 DrawablePtr pDraw
236);
237
238
239extern _X_EXPORT RegionPtr
240XAACopyPlaneColorExpansion(
241 DrawablePtr pSrc,
242 DrawablePtr pDst,
243 GCPtr pGC,
244 int srcx,
245 int srcy,
246 int width,
247 int height,
248 int dstx,
249 int dsty,
250 unsigned long bitPlane
251);
252
253
254extern _X_EXPORT void
255XAAPushPixelsSolidColorExpansion(
256 GCPtr pGC,
257 PixmapPtr pBitMap,
258 DrawablePtr pDrawable,
259 int dx,
260 int dy,
261 int xOrg,
262 int yOrg
263);
264
265extern _X_EXPORT void
266XAAWriteBitmapColorExpandMSBFirstFixedBase (
267 ScrnInfoPtr pScrn,
268 int x, int y, int w, int h,
269 unsigned char *src,
270 int srcwidth,
271 int skipleft,
272 int fg, int bg,
273 int rop,
274 unsigned int planemask
275);
276
277extern _X_EXPORT void
278XAAWriteBitmapColorExpand3MSBFirstFixedBase (
279 ScrnInfoPtr pScrn,
280 int x, int y, int w, int h,
281 unsigned char *src,
282 int srcwidth,
283 int skipleft,
284 int fg, int bg,
285 int rop,
286 unsigned int planemask
287);
288
289extern _X_EXPORT void
290XAAWriteBitmapColorExpandMSBFirst (
291 ScrnInfoPtr pScrn,
292 int x, int y, int w, int h,
293 unsigned char *src,
294 int srcwidth,
295 int skipleft,
296 int fg, int bg,
297 int rop,
298 unsigned int planemask
299);
300
301extern _X_EXPORT void
302XAAWriteBitmapColorExpand3MSBFirst (
303 ScrnInfoPtr pScrn,
304 int x, int y, int w, int h,
305 unsigned char *src,
306 int srcwidth,
307 int skipleft,
308 int fg, int bg,
309 int rop,
310 unsigned int planemask
311);
312
313extern _X_EXPORT void
314XAAWriteBitmapColorExpandLSBFirstFixedBase (
315 ScrnInfoPtr pScrn,
316 int x, int y, int w, int h,
317 unsigned char *src,
318 int srcwidth,
319 int skipleft,
320 int fg, int bg,
321 int rop,
322 unsigned int planemask
323);
324
325extern _X_EXPORT void
326XAAWriteBitmapColorExpand3LSBFirstFixedBase (
327 ScrnInfoPtr pScrn,
328 int x, int y, int w, int h,
329 unsigned char *src,
330 int srcwidth,
331 int skipleft,
332 int fg, int bg,
333 int rop,
334 unsigned int planemask
335);
336
337extern _X_EXPORT void
338XAAWriteBitmapColorExpandLSBFirst (
339 ScrnInfoPtr pScrn,
340 int x, int y, int w, int h,
341 unsigned char *src,
342 int srcwidth,
343 int skipleft,
344 int fg, int bg,
345 int rop,
346 unsigned int planemask
347);
348
349extern _X_EXPORT void
350XAAWriteBitmapColorExpand3LSBFirst (
351 ScrnInfoPtr pScrn,
352 int x, int y, int w, int h,
353 unsigned char *src,
354 int srcwidth,
355 int skipleft,
356 int fg, int bg,
357 int rop,
358 unsigned int planemask
359);
360
361
362extern _X_EXPORT void
363XAAWriteBitmapScanlineColorExpandMSBFirst (
364 ScrnInfoPtr pScrn,
365 int x, int y, int w, int h,
366 unsigned char *src,
367 int srcwidth,
368 int skipleft,
369 int fg, int bg,
370 int rop,
371 unsigned int planemask
372);
373
374extern _X_EXPORT void
375XAAWriteBitmapScanlineColorExpand3MSBFirst (
376 ScrnInfoPtr pScrn,
377 int x, int y, int w, int h,
378 unsigned char *src,
379 int srcwidth,
380 int skipleft,
381 int fg, int bg,
382 int rop,
383 unsigned int planemask
384);
385
386extern _X_EXPORT void
387XAAWriteBitmapScanlineColorExpandMSBFirstFixedBase (
388 ScrnInfoPtr pScrn,
389 int x, int y, int w, int h,
390 unsigned char *src,
391 int srcwidth,
392 int skipleft,
393 int fg, int bg,
394 int rop,
395 unsigned int planemask
396);
397
398extern _X_EXPORT void
399XAAWriteBitmapScanlineColorExpand3MSBFirstFixedBase (
400 ScrnInfoPtr pScrn,
401 int x, int y, int w, int h,
402 unsigned char *src,
403 int srcwidth,
404 int skipleft,
405 int fg, int bg,
406 int rop,
407 unsigned int planemask
408);
409
410extern _X_EXPORT void
411XAAWriteBitmapScanlineColorExpandLSBFirst (
412 ScrnInfoPtr pScrn,
413 int x, int y, int w, int h,
414 unsigned char *src,
415 int srcwidth,
416 int skipleft,
417 int fg, int bg,
418 int rop,
419 unsigned int planemask
420);
421
422extern _X_EXPORT void
423XAAWriteBitmapScanlineColorExpand3LSBFirst (
424 ScrnInfoPtr pScrn,
425 int x, int y, int w, int h,
426 unsigned char *src,
427 int srcwidth,
428 int skipleft,
429 int fg, int bg,
430 int rop,
431 unsigned int planemask
432);
433
434extern _X_EXPORT void
435XAAWriteBitmapScanlineColorExpandLSBFirstFixedBase (
436 ScrnInfoPtr pScrn,
437 int x, int y, int w, int h,
438 unsigned char *src,
439 int srcwidth,
440 int skipleft,
441 int fg, int bg,
442 int rop,
443 unsigned int planemask
444);
445
446extern _X_EXPORT void
447XAAWriteBitmapScanlineColorExpand3LSBFirstFixedBase (
448 ScrnInfoPtr pScrn,
449 int x, int y, int w, int h,
450 unsigned char *src,
451 int srcwidth,
452 int skipleft,
453 int fg, int bg,
454 int rop,
455 unsigned int planemask
456);
457
458extern _X_EXPORT void
459XAAWritePixmap (
460 ScrnInfoPtr pScrn,
461 int x, int y, int w, int h,
462 unsigned char *src,
463 int srcwidth,
464 int rop,
465 unsigned int planemask,
466 int transparency_color,
467 int bpp, int depth
468);
469
470extern _X_EXPORT void
471XAAWritePixmapScanline (
472 ScrnInfoPtr pScrn,
473 int x, int y, int w, int h,
474 unsigned char *src,
475 int srcwidth,
476 int rop,
477 unsigned int planemask,
478 int transparency_color,
479 int bpp, int depth
480);
481
482typedef void (*ClipAndRenderRectsFunc)(GCPtr, int, BoxPtr, int, int);
483
484
485extern _X_EXPORT void
486XAAClipAndRenderRects(
487 GCPtr pGC,
488 ClipAndRenderRectsFunc func,
489 int nrectFill,
490 xRectangle *prectInit,
491 int xorg, int yorg
492);
493
494
495typedef void (*ClipAndRenderSpansFunc)(GCPtr, int, DDXPointPtr, int*,
496 int, int, int);
497
498extern _X_EXPORT void
499XAAClipAndRenderSpans(
500 GCPtr pGC,
501 DDXPointPtr ppt,
502 int *pwidth,
503 int nspans,
504 int fSorted,
505 ClipAndRenderSpansFunc func,
506 int xorg,
507 int yorg
508);
509
510
511extern _X_EXPORT void
512XAAFillSolidRects(
513 ScrnInfoPtr pScrn,
514 int fg, int rop,
515 unsigned int planemask,
516 int nBox,
517 BoxPtr pBox
518);
519
520extern _X_EXPORT void
521XAAFillMono8x8PatternRects(
522 ScrnInfoPtr pScrn,
523 int fg, int bg, int rop,
524 unsigned int planemask,
525 int nBox,
526 BoxPtr pBox,
527 int pat0, int pat1,
528 int xorg, int yorg
529);
530
531extern _X_EXPORT void
532XAAFillMono8x8PatternRectsScreenOrigin(
533 ScrnInfoPtr pScrn,
534 int fg, int bg, int rop,
535 unsigned int planemask,
536 int nBox,
537 BoxPtr pBox,
538 int pat0, int pat1,
539 int xorg, int yorg
540);
541
542
543extern _X_EXPORT void
544XAAFillColor8x8PatternRectsScreenOrigin(
545 ScrnInfoPtr pScrn,
546 int rop,
547 unsigned int planemask,
548 int nBox,
549 BoxPtr pBox,
550 int xorigin, int yorigin,
551 XAACacheInfoPtr pCache
552);
553
554extern _X_EXPORT void
555XAAFillColor8x8PatternRects(
556 ScrnInfoPtr pScrn,
557 int rop,
558 unsigned int planemask,
559 int nBox,
560 BoxPtr pBox,
561 int xorigin, int yorigin,
562 XAACacheInfoPtr pCache
563);
564
565extern _X_EXPORT void
566XAAFillCacheBltRects(
567 ScrnInfoPtr pScrn,
568 int rop,
569 unsigned int planemask,
570 int nBox,
571 BoxPtr pBox,
572 int xorg, int yorg,
573 XAACacheInfoPtr pCache
574);
575
576extern _X_EXPORT void
577XAAFillCacheExpandRects(
578 ScrnInfoPtr pScrn,
579 int fg, int bg, int rop,
580 unsigned int planemask,
581 int nBox,
582 BoxPtr pBox,
583 int xorg, int yorg,
584 PixmapPtr pPix
585);
586
587extern _X_EXPORT void
588XAAFillImageWriteRects(
589 ScrnInfoPtr pScrn,
590 int rop,
591 unsigned int planemask,
592 int nBox,
593 BoxPtr pBox,
594 int xorg, int yorg,
595 PixmapPtr pPix
596);
597
598extern _X_EXPORT void
599XAAPolyFillRect(
600 DrawablePtr pDraw,
601 GCPtr pGC,
602 int nrectFill,
603 xRectangle *prectInit
604);
605
606
607extern _X_EXPORT void
608XAATEGlyphRendererMSBFirstFixedBase (
609 ScrnInfoPtr pScrn,
610 int x, int y, int w, int h, int skipleft, int startline,
611 unsigned int **glyphs, int glyphWidth,
612 int fg, int bg, int rop, unsigned planemask
613);
614
615extern _X_EXPORT void
616XAATEGlyphRenderer3MSBFirstFixedBase (
617 ScrnInfoPtr pScrn,
618 int x, int y, int w, int h, int skipleft, int startline,
619 unsigned int **glyphs, int glyphWidth,
620 int fg, int bg, int rop, unsigned planemask
621);
622
623extern _X_EXPORT void
624XAATEGlyphRendererMSBFirst (
625 ScrnInfoPtr pScrn,
626 int x, int y, int w, int h, int skipleft, int startline,
627 unsigned int **glyphs, int glyphWidth,
628 int fg, int bg, int rop, unsigned planemask
629);
630
631extern _X_EXPORT void
632XAATEGlyphRenderer3MSBFirst (
633 ScrnInfoPtr pScrn,
634 int x, int y, int w, int h, int skipleft, int startline,
635 unsigned int **glyphs, int glyphWidth,
636 int fg, int bg, int rop, unsigned planemask
637);
638
639extern _X_EXPORT void
640XAATEGlyphRendererLSBFirstFixedBase (
641 ScrnInfoPtr pScrn,
642 int x, int y, int w, int h, int skipleft, int startline,
643 unsigned int **glyphs, int glyphWidth,
644 int fg, int bg, int rop, unsigned planemask
645);
646
647
648extern _X_EXPORT void
649XAATEGlyphRenderer3LSBFirstFixedBase (
650 ScrnInfoPtr pScrn,
651 int x, int y, int w, int h, int skipleft, int startline,
652 unsigned int **glyphs, int glyphWidth,
653 int fg, int bg, int rop, unsigned planemask
654);
655
656extern _X_EXPORT void
657XAATEGlyphRendererLSBFirst (
658 ScrnInfoPtr pScrn,
659 int x, int y, int w, int h, int skipleft, int startline,
660 unsigned int **glyphs, int glyphWidth,
661 int fg, int bg, int rop, unsigned planemask
662);
663
664extern _X_EXPORT void
665XAATEGlyphRenderer3LSBFirst (
666 ScrnInfoPtr pScrn,
667 int x, int y, int w, int h, int skipleft, int startline,
668 unsigned int **glyphs, int glyphWidth,
669 int fg, int bg, int rop, unsigned planemask
670);
671
672
673extern _X_EXPORT void
674XAATEGlyphRendererScanlineMSBFirst (
675 ScrnInfoPtr pScrn,
676 int x, int y, int w, int h, int skipleft, int startline,
677 unsigned int **glyphs, int glyphWidth,
678 int fg, int bg, int rop, unsigned planemask
679);
680
681extern _X_EXPORT void
682XAATEGlyphRendererScanline3MSBFirst (
683 ScrnInfoPtr pScrn,
684 int x, int y, int w, int h, int skipleft, int startline,
685 unsigned int **glyphs, int glyphWidth,
686 int fg, int bg, int rop, unsigned planemask
687);
688
689extern _X_EXPORT void
690XAATEGlyphRendererScanlineLSBFirst (
691 ScrnInfoPtr pScrn,
692 int x, int y, int w, int h, int skipleft, int startline,
693 unsigned int **glyphs, int glyphWidth,
694 int fg, int bg, int rop, unsigned planemask
695);
696
697extern _X_EXPORT void
698XAATEGlyphRendererScanline3LSBFirst (
699 ScrnInfoPtr pScrn,
700 int x, int y, int w, int h, int skipleft, int startline,
701 unsigned int **glyphs, int glyphWidth,
702 int fg, int bg, int rop, unsigned planemask
703);
704
705
706extern _X_EXPORT CARD32 *(*XAAGlyphScanlineFuncMSBFirstFixedBase[32])(
707 CARD32 *base, unsigned int **glyphp, int line, int nglyph, int width
708);
709
710extern _X_EXPORT CARD32 *(*XAAGlyphScanlineFuncMSBFirst[32])(
711 CARD32 *base, unsigned int **glyphp, int line, int nglyph, int width
712);
713
714extern _X_EXPORT CARD32 *(*XAAGlyphScanlineFuncLSBFirstFixedBase[32])(
715 CARD32 *base, unsigned int **glyphp, int line, int nglyph, int width
716);
717
718extern _X_EXPORT CARD32 *(*XAAGlyphScanlineFuncLSBFirst[32])(
719 CARD32 *base, unsigned int **glyphp, int line, int nglyph, int width
720);
721
722extern _X_EXPORT GlyphScanlineFuncPtr *XAAGetGlyphScanlineFuncMSBFirstFixedBase(void);
723extern _X_EXPORT GlyphScanlineFuncPtr *XAAGetGlyphScanlineFuncMSBFirst(void);
724extern _X_EXPORT GlyphScanlineFuncPtr *XAAGetGlyphScanlineFuncLSBFirstFixedBase(void);
725extern _X_EXPORT GlyphScanlineFuncPtr *XAAGetGlyphScanlineFuncLSBFirst(void);
726
727extern _X_EXPORT void
728XAAFillColorExpandRectsLSBFirst(
729 ScrnInfoPtr pScrn,
730 int fg, int bg, int rop,
731 unsigned int planemask,
732 int nBox,
733 BoxPtr pBox,
734 int xorg, int yorg,
735 PixmapPtr pPix
736);
737
738extern _X_EXPORT void
739XAAFillColorExpandRects3LSBFirst(
740 ScrnInfoPtr pScrn,
741 int fg, int bg, int rop,
742 unsigned int planemask,
743 int nBox,
744 BoxPtr pBox,
745 int xorg, int yorg,
746 PixmapPtr pPix
747);
748
749extern _X_EXPORT void
750XAAFillColorExpandRectsLSBFirstFixedBase(
751 ScrnInfoPtr pScrn,
752 int fg, int bg, int rop,
753 unsigned int planemask,
754 int nBox,
755 BoxPtr pBox,
756 int xorg, int yorg,
757 PixmapPtr pPix
758);
759
760extern _X_EXPORT void
761XAAFillColorExpandRects3LSBFirstFixedBase(
762 ScrnInfoPtr pScrn,
763 int fg, int bg, int rop,
764 unsigned int planemask,
765 int nBox,
766 BoxPtr pBox,
767 int xorg, int yorg,
768 PixmapPtr pPix
769);
770
771extern _X_EXPORT void
772XAAFillColorExpandRectsMSBFirst(
773 ScrnInfoPtr pScrn,
774 int fg, int bg, int rop,
775 unsigned int planemask,
776 int nBox,
777 BoxPtr pBox,
778 int xorg, int yorg,
779 PixmapPtr pPix
780);
781
782extern _X_EXPORT void
783XAAFillColorExpandRects3MSBFirst(
784 ScrnInfoPtr pScrn,
785 int fg, int bg, int rop,
786 unsigned int planemask,
787 int nBox,
788 BoxPtr pBox,
789 int xorg, int yorg,
790 PixmapPtr pPix
791);
792
793extern _X_EXPORT void
794XAAFillColorExpandRectsMSBFirstFixedBase(
795 ScrnInfoPtr pScrn,
796 int fg, int bg, int rop,
797 unsigned int planemask,
798 int nBox,
799 BoxPtr pBox,
800 int xorg, int yorg,
801 PixmapPtr pPix
802);
803
804extern _X_EXPORT void
805XAAFillColorExpandRects3MSBFirstFixedBase(
806 ScrnInfoPtr pScrn,
807 int fg, int bg, int rop,
808 unsigned int planemask,
809 int nBox,
810 BoxPtr pBox,
811 int xorg, int yorg,
812 PixmapPtr pPix
813);
814
815extern _X_EXPORT void
816XAAFillScanlineColorExpandRectsLSBFirst(
817 ScrnInfoPtr pScrn,
818 int fg, int bg, int rop,
819 unsigned int planemask,
820 int nBox,
821 BoxPtr pBox,
822 int xorg, int yorg,
823 PixmapPtr pPix
824);
825
826extern _X_EXPORT void
827XAAFillScanlineColorExpandRects3LSBFirst(
828 ScrnInfoPtr pScrn,
829 int fg, int bg, int rop,
830 unsigned int planemask,
831 int nBox,
832 BoxPtr pBox,
833 int xorg, int yorg,
834 PixmapPtr pPix
835);
836
837extern _X_EXPORT void
838XAAFillScanlineColorExpandRectsMSBFirst(
839 ScrnInfoPtr pScrn,
840 int fg, int bg, int rop,
841 unsigned int planemask,
842 int nBox,
843 BoxPtr pBox,
844 int xorg, int yorg,
845 PixmapPtr pPix
846);
847
848extern _X_EXPORT void
849XAAFillScanlineColorExpandRects3MSBFirst(
850 ScrnInfoPtr pScrn,
851 int fg, int bg, int rop,
852 unsigned int planemask,
853 int nBox,
854 BoxPtr pBox,
855 int xorg, int yorg,
856 PixmapPtr pPix
857);
858
859extern _X_EXPORT void
860XAAFillColorExpandSpansLSBFirst(
861 ScrnInfoPtr pScrn,
862 int fg, int bg, int rop,
863 unsigned int planemask,
864 int n,
865 DDXPointPtr ppt,
866 int *pwidth,
867 int fSorted,
868 int xorg, int yorg,
869 PixmapPtr pPix
870);
871
872extern _X_EXPORT void
873XAAFillColorExpandSpans3LSBFirst(
874 ScrnInfoPtr pScrn,
875 int fg, int bg, int rop,
876 unsigned int planemask,
877 int n,
878 DDXPointPtr ppt,
879 int *pwidth,
880 int fSorted,
881 int xorg, int yorg,
882 PixmapPtr pPix
883);
884
885extern _X_EXPORT void
886XAAFillColorExpandSpansLSBFirstFixedBase(
887 ScrnInfoPtr pScrn,
888 int fg, int bg, int rop,
889 unsigned int planemask,
890 int n,
891 DDXPointPtr ppt,
892 int *pwidth,
893 int fSorted,
894 int xorg, int yorg,
895 PixmapPtr pPix
896);
897
898extern _X_EXPORT void
899XAAFillColorExpandSpans3LSBFirstFixedBase(
900 ScrnInfoPtr pScrn,
901 int fg, int bg, int rop,
902 unsigned int planemask,
903 int n,
904 DDXPointPtr ppt,
905 int *pwidth,
906 int fSorted,
907 int xorg, int yorg,
908 PixmapPtr pPix
909);
910
911extern _X_EXPORT void
912XAAFillColorExpandSpansMSBFirst(
913 ScrnInfoPtr pScrn,
914 int fg, int bg, int rop,
915 unsigned int planemask,
916 int n,
917 DDXPointPtr ppt,
918 int *pwidth,
919 int fSorted,
920 int xorg, int yorg,
921 PixmapPtr pPix
922);
923
924extern _X_EXPORT void
925XAAFillColorExpandSpans3MSBFirst(
926 ScrnInfoPtr pScrn,
927 int fg, int bg, int rop,
928 unsigned int planemask,
929 int n,
930 DDXPointPtr ppt,
931 int *pwidth,
932 int fSorted,
933 int xorg, int yorg,
934 PixmapPtr pPix
935);
936
937extern _X_EXPORT void
938XAAFillColorExpandSpansMSBFirstFixedBase(
939 ScrnInfoPtr pScrn,
940 int fg, int bg, int rop,
941 unsigned int planemask,
942 int n,
943 DDXPointPtr ppt,
944 int *pwidth,
945 int fSorted,
946 int xorg, int yorg,
947 PixmapPtr pPix
948);
949
950extern _X_EXPORT void
951XAAFillColorExpandSpans3MSBFirstFixedBase(
952 ScrnInfoPtr pScrn,
953 int fg, int bg, int rop,
954 unsigned int planemask,
955 int n,
956 DDXPointPtr ppt,
957 int *pwidth,
958 int fSorted,
959 int xorg, int yorg,
960 PixmapPtr pPix
961);
962
963extern _X_EXPORT void
964XAAFillScanlineColorExpandSpansLSBFirst(
965 ScrnInfoPtr pScrn,
966 int fg, int bg, int rop,
967 unsigned int planemask,
968 int n,
969 DDXPointPtr ppt,
970 int *pwidth,
971 int fSorted,
972 int xorg, int yorg,
973 PixmapPtr pPix
974);
975
976extern _X_EXPORT void
977XAAFillScanlineColorExpandSpans3LSBFirst(
978 ScrnInfoPtr pScrn,
979 int fg, int bg, int rop,
980 unsigned int planemask,
981 int n,
982 DDXPointPtr ppt,
983 int *pwidth,
984 int fSorted,
985 int xorg, int yorg,
986 PixmapPtr pPix
987);
988
989extern _X_EXPORT void
990XAAPutImage(
991 DrawablePtr pDraw,
992 GCPtr pGC,
993 int depth,
994 int x,
995 int y,
996 int w,
997 int h,
998 int leftPad,
999 int format,
1000 char *pImage
1001);
1002
1003extern _X_EXPORT void
1004XAAFillScanlineColorExpandSpansMSBFirst(
1005 ScrnInfoPtr pScrn,
1006 int fg, int bg, int rop,
1007 unsigned int planemask,
1008 int n,
1009 DDXPointPtr ppt,
1010 int *pwidth,
1011 int fSorted,
1012 int xorg, int yorg,
1013 PixmapPtr pPix
1014);
1015
1016extern _X_EXPORT void
1017XAAFillScanlineColorExpandSpans3MSBFirst(
1018 ScrnInfoPtr pScrn,
1019 int fg, int bg, int rop,
1020 unsigned int planemask,
1021 int n,
1022 DDXPointPtr ppt,
1023 int *pwidth,
1024 int fSorted,
1025 int xorg, int yorg,
1026 PixmapPtr pPix
1027);
1028
1029
1030extern _X_EXPORT CARD32 *(*XAAStippleScanlineFuncMSBFirstFixedBase[6])(
1031 CARD32* base, CARD32* src, int offset, int width, int dwords
1032);
1033
1034extern _X_EXPORT CARD32 *(*XAAStippleScanlineFuncMSBFirst[6])(
1035 CARD32* base, CARD32* src, int offset, int width, int dwords
1036);
1037
1038extern _X_EXPORT CARD32 *(*XAAStippleScanlineFuncLSBFirstFixedBase[6])(
1039 CARD32* base, CARD32* src, int offset, int width, int dwords
1040);
1041
1042extern _X_EXPORT CARD32 *(*XAAStippleScanlineFuncLSBFirst[6])(
1043 CARD32* base, CARD32* src, int offset, int width, int dwords
1044);
1045
1046extern _X_EXPORT StippleScanlineProcPtr *XAAGetStippleScanlineFuncMSBFirstFixedBase(void);
1047extern _X_EXPORT StippleScanlineProcPtr *XAAGetStippleScanlineFuncMSBFirst(void);
1048extern _X_EXPORT StippleScanlineProcPtr *XAAGetStippleScanlineFuncLSBFirstFixedBase(void);
1049extern _X_EXPORT StippleScanlineProcPtr *XAAGetStippleScanlineFuncLSBFirst(void);
1050extern _X_EXPORT StippleScanlineProcPtr *XAAGetStippleScanlineFunc3MSBFirstFixedBase(void);
1051extern _X_EXPORT StippleScanlineProcPtr *XAAGetStippleScanlineFunc3MSBFirst(void);
1052extern _X_EXPORT StippleScanlineProcPtr *XAAGetStippleScanlineFunc3LSBFirstFixedBase(void);
1053extern _X_EXPORT StippleScanlineProcPtr *XAAGetStippleScanlineFunc3LSBFirst(void);
1054
1055extern _X_EXPORT int
1056XAAPolyText8TEColorExpansion(
1057 DrawablePtr pDraw,
1058 GCPtr pGC,
1059 int x, int y,
1060 int count,
1061 char *chars
1062);
1063
1064extern _X_EXPORT int
1065XAAPolyText16TEColorExpansion(
1066 DrawablePtr pDraw,
1067 GCPtr pGC,
1068 int x, int y,
1069 int count,
1070 unsigned short *chars
1071);
1072
1073extern _X_EXPORT void
1074XAAImageText8TEColorExpansion(
1075 DrawablePtr pDraw,
1076 GCPtr pGC,
1077 int x, int y,
1078 int count,
1079 char *chars
1080);
1081
1082extern _X_EXPORT void
1083XAAImageText16TEColorExpansion(
1084 DrawablePtr pDraw,
1085 GCPtr pGC,
1086 int x, int y,
1087 int count,
1088 unsigned short *chars
1089);
1090
1091extern _X_EXPORT void
1092XAAImageGlyphBltTEColorExpansion(
1093 DrawablePtr pDrawable,
1094 GCPtr pGC,
1095 int xInit, int yInit,
1096 unsigned int nglyph,
1097 CharInfoPtr *ppci,
1098 pointer pglyphBase
1099);
1100
1101extern _X_EXPORT void
1102XAAPolyGlyphBltTEColorExpansion(
1103 DrawablePtr pDrawable,
1104 GCPtr pGC,
1105 int xInit, int yInit,
1106 unsigned int nglyph,
1107 CharInfoPtr *ppci,
1108 pointer pglyphBase
1109);
1110
1111
1112extern _X_EXPORT int
1113XAAPolyText8NonTEColorExpansion(
1114 DrawablePtr pDraw,
1115 GCPtr pGC,
1116 int x, int y,
1117 int count,
1118 char *chars
1119);
1120
1121extern _X_EXPORT int
1122XAAPolyText16NonTEColorExpansion(
1123 DrawablePtr pDraw,
1124 GCPtr pGC,
1125 int x, int y,
1126 int count,
1127 unsigned short *chars
1128);
1129
1130extern _X_EXPORT void
1131XAAImageText8NonTEColorExpansion(
1132 DrawablePtr pDraw,
1133 GCPtr pGC,
1134 int x, int y,
1135 int count,
1136 char *chars
1137);
1138
1139extern _X_EXPORT void
1140XAAImageText16NonTEColorExpansion(
1141 DrawablePtr pDraw,
1142 GCPtr pGC,
1143 int x, int y,
1144 int count,
1145 unsigned short *chars
1146);
1147
1148extern _X_EXPORT void
1149XAAImageGlyphBltNonTEColorExpansion(
1150 DrawablePtr pDrawable,
1151 GCPtr pGC,
1152 int xInit, int yInit,
1153 unsigned int nglyph,
1154 CharInfoPtr *ppci,
1155 pointer pglyphBase
1156);
1157
1158extern _X_EXPORT void
1159XAAPolyGlyphBltNonTEColorExpansion(
1160 DrawablePtr pDrawable,
1161 GCPtr pGC,
1162 int xInit, int yInit,
1163 unsigned int nglyph,
1164 CharInfoPtr *ppci,
1165 pointer pglyphBase
1166);
1167
1168
1169extern _X_EXPORT void XAANonTEGlyphRenderer(
1170 ScrnInfoPtr pScrn,
1171 int x, int y, int n,
1172 NonTEGlyphPtr glyphs,
1173 BoxPtr pbox,
1174 int fg, int rop,
1175 unsigned int planemask
1176);
1177
1178extern _X_EXPORT void
1179XAAFillSolidSpans(
1180 ScrnInfoPtr pScrn,
1181 int fg, int rop,
1182 unsigned int planemask,
1183 int n,
1184 DDXPointPtr ppt,
1185 int *pwidth, int fSorted
1186);
1187
1188extern _X_EXPORT void
1189XAAFillMono8x8PatternSpans(
1190 ScrnInfoPtr pScrn,
1191 int fg, int bg, int rop,
1192 unsigned int planemask,
1193 int n,
1194 DDXPointPtr ppt,
1195 int *pwidth, int fSorted,
1196 int patx, int paty,
1197 int xorg, int yorg
1198);
1199
1200extern _X_EXPORT void
1201XAAFillMono8x8PatternSpansScreenOrigin(
1202 ScrnInfoPtr pScrn,
1203 int fg, int bg, int rop,
1204 unsigned int planemask,
1205 int n,
1206 DDXPointPtr ppt,
1207 int *pwidth, int fSorted,
1208 int patx, int paty,
1209 int xorg, int yorg
1210);
1211
1212extern _X_EXPORT void
1213XAAFillColor8x8PatternSpansScreenOrigin(
1214 ScrnInfoPtr pScrn,
1215 int rop,
1216 unsigned int planemask,
1217 int n,
1218 DDXPointPtr ppt,
1219 int *pwidth, int fSorted,
1220 XAACacheInfoPtr,
1221 int xorigin, int yorigin
1222);
1223
1224extern _X_EXPORT void
1225XAAFillColor8x8PatternSpans(
1226 ScrnInfoPtr pScrn,
1227 int rop,
1228 unsigned int planemask,
1229 int n,
1230 DDXPointPtr ppt,
1231 int *pwidth, int fSorted,
1232 XAACacheInfoPtr,
1233 int xorigin, int yorigin
1234);
1235
1236extern _X_EXPORT void
1237XAAFillCacheBltSpans(
1238 ScrnInfoPtr pScrn,
1239 int rop,
1240 unsigned int planemask,
1241 int n,
1242 DDXPointPtr points,
1243 int *widths,
1244 int fSorted,
1245 XAACacheInfoPtr pCache,
1246 int xorg, int yorg
1247);
1248
1249extern _X_EXPORT void
1250XAAFillCacheExpandSpans(
1251 ScrnInfoPtr pScrn,
1252 int fg, int bg, int rop,
1253 unsigned int planemask,
1254 int n,
1255 DDXPointPtr ppt,
1256 int *pwidth,
1257 int fSorted,
1258 int xorg, int yorg,
1259 PixmapPtr pPix
1260);
1261
1262extern _X_EXPORT void
1263XAAFillSpans(
1264 DrawablePtr pDrawable,
1265 GC *pGC,
1266 int nInit,
1267 DDXPointPtr pptInit,
1268 int *pwidth,
1269 int fSorted
1270);
1271
1272
1273extern _X_EXPORT void
1274XAAInitPixmapCache(
1275 ScreenPtr pScreen,
1276 RegionPtr areas,
1277 pointer data
1278);
1279
1280extern _X_EXPORT void
1281XAAWriteBitmapToCache(
1282 ScrnInfoPtr pScrn,
1283 int x, int y, int w, int h,
1284 unsigned char *src,
1285 int srcwidth,
1286 int fg, int bg
1287);
1288
1289extern _X_EXPORT void
1290XAAWriteBitmapToCacheLinear(
1291 ScrnInfoPtr pScrn,
1292 int x, int y, int w, int h,
1293 unsigned char *src,
1294 int srcwidth,
1295 int fg, int bg
1296);
1297
1298extern _X_EXPORT void
1299XAAWritePixmapToCache(
1300 ScrnInfoPtr pScrn,
1301 int x, int y, int w, int h,
1302 unsigned char *src,
1303 int srcwidth,
1304 int bpp, int depth
1305);
1306
1307extern _X_EXPORT void
1308XAAWritePixmapToCacheLinear(
1309 ScrnInfoPtr pScrn,
1310 int x, int y, int w, int h,
1311 unsigned char *src,
1312 int srcwidth,
1313 int bpp, int depth
1314);
1315
1316extern _X_EXPORT void
1317XAASolidHorVertLineAsRects(
1318 ScrnInfoPtr pScrn,
1319 int x, int y, int len, int dir
1320);
1321
1322extern _X_EXPORT void
1323XAASolidHorVertLineAsTwoPoint(
1324 ScrnInfoPtr pScrn,
1325 int x, int y, int len, int dir
1326);
1327
1328extern _X_EXPORT void
1329XAASolidHorVertLineAsBresenham(
1330 ScrnInfoPtr pScrn,
1331 int x, int y, int len, int dir
1332);
1333
1334
1335extern _X_EXPORT void
1336XAAPolyRectangleThinSolid(
1337 DrawablePtr pDrawable,
1338 GCPtr pGC,
1339 int nRectsInit,
1340 xRectangle *pRectsInit
1341);
1342
1343
1344extern _X_EXPORT void
1345XAAPolylinesWideSolid (
1346 DrawablePtr pDrawable,
1347 GCPtr pGC,
1348 int mode,
1349 int npt,
1350 DDXPointPtr pPts
1351);
1352
1353extern _X_EXPORT void
1354XAAFillPolygonSolid(
1355 DrawablePtr pDrawable,
1356 GCPtr pGC,
1357 int shape,
1358 int mode,
1359 int count,
1360 DDXPointPtr ptsIn
1361);
1362
1363extern _X_EXPORT void
1364XAAFillPolygonStippled(
1365 DrawablePtr pDrawable,
1366 GCPtr pGC,
1367 int shape,
1368 int mode,
1369 int count,
1370 DDXPointPtr ptsIn
1371);
1372
1373
1374extern _X_EXPORT void
1375XAAFillPolygonTiled(
1376 DrawablePtr pDrawable,
1377 GCPtr pGC,
1378 int shape,
1379 int mode,
1380 int count,
1381 DDXPointPtr ptsIn
1382);
1383
1384
1385extern _X_EXPORT int
1386XAAIsEasyPolygon(
1387 DDXPointPtr ptsIn,
1388 int count,
1389 BoxPtr extents,
1390 int origin,
1391 DDXPointPtr *topPoint,
1392 int *topY, int *bottomY,
1393 int shape
1394);
1395
1396extern _X_EXPORT void
1397XAAFillPolygonHelper(
1398 ScrnInfoPtr pScrn,
1399 DDXPointPtr ptsIn,
1400 int count,
1401 DDXPointPtr topPoint,
1402 int y,
1403 int maxy,
1404 int origin,
1405 RectFuncPtr RectFunc,
1406 TrapFuncPtr TrapFunc,
1407 int xorg,
1408 int yorg,
1409 XAACacheInfoPtr pCache
1410);
1411
1412extern _X_EXPORT void
1413XAAPolySegment(
1414 DrawablePtr pDrawable,
1415 GCPtr pGC,
1416 int nseg,
1417 xSegment *pSeg
1418);
1419
1420extern _X_EXPORT void
1421XAAPolyLines(
1422 DrawablePtr pDrawable,
1423 GCPtr pGC,
1424 int mode,
1425 int npt,
1426 DDXPointPtr pptInit
1427);
1428
1429extern _X_EXPORT void
1430XAAPolySegmentDashed(
1431 DrawablePtr pDrawable,
1432 GCPtr pGC,
1433 int nseg,
1434 xSegment *pSeg
1435);
1436
1437extern _X_EXPORT void
1438XAAPolyLinesDashed(
1439 DrawablePtr pDrawable,
1440 GCPtr pGC,
1441 int mode,
1442 int npt,
1443 DDXPointPtr pptInit
1444);
1445
1446
1447extern _X_EXPORT void
1448XAAWriteMono8x8PatternToCache(ScrnInfoPtr pScrn, XAACacheInfoPtr pCache);
1449
1450extern _X_EXPORT void
1451XAAWriteColor8x8PatternToCache(
1452 ScrnInfoPtr pScrn,
1453 PixmapPtr pPix,
1454 XAACacheInfoPtr pCache
1455);
1456
1457extern _X_EXPORT void
1458XAARotateMonoPattern(
1459 int *pat0, int *pat1,
1460 int xoffset, int yoffset,
1461 Bool msbfirst
1462);
1463
1464extern _X_EXPORT void XAAComputeDash(GCPtr pGC);
1465
1466extern _X_EXPORT void XAAMoveDWORDS_FixedBase(
1467 register CARD32* dest,
1468 register CARD32* src,
1469 register int dwords
1470);
1471
1472extern _X_EXPORT void XAAMoveDWORDS_FixedSrc(
1473 register CARD32* dest,
1474 register CARD32* src,
1475 register int dwords
1476);
1477
1478extern _X_EXPORT void XAAMoveDWORDS(
1479 register CARD32* dest,
1480 register CARD32* src,
1481 register int dwords
1482);
1483
1484extern _X_EXPORT int
1485XAAGetRectClipBoxes(
1486 GCPtr pGC,
1487 BoxPtr pboxClippedBase,
1488 int nrectFill,
1489 xRectangle *prectInit
1490);
1491
1492extern _X_EXPORT void
1493XAASetupOverlay8_32Planar(ScreenPtr);
1494
1495extern _X_EXPORT void
1496XAAPolyFillArcSolid(DrawablePtr pDraw, GCPtr pGC, int narcs, xArc *parcs);
1497
1498extern _X_EXPORT XAACacheInfoPtr
1499XAACacheTile(ScrnInfoPtr Scrn, PixmapPtr pPix);
1500
1501extern _X_EXPORT XAACacheInfoPtr
1502XAACacheMonoStipple(ScrnInfoPtr Scrn, PixmapPtr pPix);
1503
1504extern _X_EXPORT XAACacheInfoPtr
1505XAACachePlanarMonoStipple(ScrnInfoPtr Scrn, PixmapPtr pPix);
1506
1507typedef XAACacheInfoPtr (*XAACachePlanarMonoStippleProc)(ScrnInfoPtr, PixmapPtr);
1508extern _X_EXPORT XAACachePlanarMonoStippleProc XAAGetCachePlanarMonoStipple(void);
1509
1510extern _X_EXPORT XAACacheInfoPtr
1511XAACacheStipple(ScrnInfoPtr Scrn, PixmapPtr pPix, int fg, int bg);
1512
1513extern _X_EXPORT XAACacheInfoPtr
1514XAACacheMono8x8Pattern(ScrnInfoPtr Scrn, int pat0, int pat1);
1515
1516extern _X_EXPORT XAACacheInfoPtr
1517XAACacheColor8x8Pattern(ScrnInfoPtr Scrn, PixmapPtr pPix, int fg, int bg);
1518
1519extern _X_EXPORT void
1520XAATileCache(ScrnInfoPtr pScrn, XAACacheInfoPtr pCache, int w, int h);
1521
1522extern _X_EXPORT void XAAClosePixmapCache(ScreenPtr pScreen);
1523void XAAInvalidatePixmapCache(ScreenPtr pScreen);
1524
1525extern _X_EXPORT Bool XAACheckStippleReducibility(PixmapPtr pPixmap);
1526extern _X_EXPORT Bool XAACheckTileReducibility(PixmapPtr pPixmap, Bool checkMono);
1527
1528extern _X_EXPORT int XAAStippledFillChooser(GCPtr pGC);
1529extern _X_EXPORT int XAAOpaqueStippledFillChooser(GCPtr pGC);
1530extern _X_EXPORT int XAATiledFillChooser(GCPtr pGC);
1531
1532extern _X_EXPORT void XAAMoveInOffscreenPixmaps(ScreenPtr pScreen);
1533extern _X_EXPORT void XAAMoveOutOffscreenPixmaps(ScreenPtr pScreen);
1534extern _X_EXPORT void XAARemoveAreaCallback(FBAreaPtr area);
1535extern _X_EXPORT void XAAMoveOutOffscreenPixmap(PixmapPtr pPix);
1536extern _X_EXPORT Bool XAAInitStateWrap(ScreenPtr pScreen, XAAInfoRecPtr infoRec);
1537
1538extern _X_EXPORT void
1539XAAComposite (CARD8 op,
1540 PicturePtr pSrc,
1541 PicturePtr pMask,
1542 PicturePtr pDst,
1543 INT16 xSrc,
1544 INT16 ySrc,
1545 INT16 xMask,
1546 INT16 yMask,
1547 INT16 xDst,
1548 INT16 yDst,
1549 CARD16 width,
1550 CARD16 height);
1551
1552
1553extern _X_EXPORT Bool
1554XAADoComposite (CARD8 op,
1555 PicturePtr pSrc,
1556 PicturePtr pMask,
1557 PicturePtr pDst,
1558 INT16 xSrc,
1559 INT16 ySrc,
1560 INT16 xMask,
1561 INT16 yMask,
1562 INT16 xDst,
1563 INT16 yDst,
1564 CARD16 width,
1565 CARD16 height);
1566
1567
1568extern _X_EXPORT void
1569XAAGlyphs (CARD8 op,
1570 PicturePtr pSrc,
1571 PicturePtr pDst,
1572 PictFormatPtr maskFormat,
1573 INT16 xSrc,
1574 INT16 ySrc,
1575 int nlist,
1576 GlyphListPtr list,
1577 GlyphPtr *glyphs);
1578
1579extern _X_EXPORT Bool
1580XAADoGlyphs (CARD8 op,
1581 PicturePtr pSrc,
1582 PicturePtr pDst,
1583 PictFormatPtr maskFormat,
1584 INT16 xSrc,
1585 INT16 ySrc,
1586 int nlist,
1587 GlyphListPtr list,
1588 GlyphPtr *glyphs);
1589
1590
1591
1592/* helpers */
1593extern _X_EXPORT void
1594XAA_888_plus_PICT_a8_to_8888 (
1595 CARD32 color,
1596 CARD8 *alphaPtr, /* in bytes */
1597 int alphaPitch,
1598 CARD32 *dstPtr,
1599 int dstPitch, /* in dwords */
1600 int width,
1601 int height
1602);
1603
1604extern _X_EXPORT Bool
1605XAAGetRGBAFromPixel(
1606 CARD32 pixel,
1607 CARD16 *red,
1608 CARD16 *green,
1609 CARD16 *blue,
1610 CARD16 *alpha,
1611 CARD32 format
1612);
1613
1614
1615extern _X_EXPORT Bool
1616XAAGetPixelFromRGBA (
1617 CARD32 *pixel,
1618 CARD16 red,
1619 CARD16 green,
1620 CARD16 blue,
1621 CARD16 alpha,
1622 CARD32 format
1623);
1624
1625/* XXX should be static */
1626extern _X_EXPORT GCOps XAAFallbackOps;
1627extern _X_EXPORT GCOps *XAAGetFallbackOps(void);
1628extern _X_EXPORT GCFuncs XAAGCFuncs;
1629extern _X_EXPORT DevPrivateKey XAAGetScreenKey(void);
1630extern _X_EXPORT DevPrivateKey XAAGetGCKey(void);
1631extern _X_EXPORT DevPrivateKey XAAGetPixmapKey(void);
1632
1633extern _X_EXPORT unsigned int XAAShiftMasks[32];
1634
1635extern _X_EXPORT unsigned int byte_expand3[256], byte_reversed_expand3[256];
1636
1637extern _X_EXPORT CARD32 XAAReverseBitOrder(CARD32 data);
1638
1639#define GET_XAASCREENPTR_FROM_SCREEN(pScreen)\
1640 dixLookupPrivate(&(pScreen)->devPrivates, XAAGetScreenKey())
1641
1642#define GET_XAASCREENPTR_FROM_GC(pGC)\
1643 dixLookupPrivate(&(pGC)->pScreen->devPrivates, XAAGetScreenKey())
1644
1645#define GET_XAASCREENPTR_FROM_DRAWABLE(pDraw)\
1646 dixLookupPrivate(&(pDraw)->pScreen->devPrivates, XAAGetScreenKey())
1647
1648#define GET_XAAINFORECPTR_FROM_SCREEN(pScreen)\
1649((XAAScreenPtr)dixLookupPrivate(&(pScreen)->devPrivates, XAAGetScreenKey()))->AccelInfoRec
1650
1651#define GET_XAAINFORECPTR_FROM_GC(pGC)\
1652((XAAScreenPtr)dixLookupPrivate(&(pGC)->pScreen->devPrivates, XAAGetScreenKey()))->AccelInfoRec
1653
1654#define GET_XAAINFORECPTR_FROM_DRAWABLE(pDraw)\
1655((XAAScreenPtr)dixLookupPrivate(&(pDraw)->pScreen->devPrivates, XAAGetScreenKey()))->AccelInfoRec
1656
1657#define GET_XAAINFORECPTR_FROM_SCRNINFOPTR(pScrn)\
1658((XAAScreenPtr)dixLookupPrivate(&(pScrn)->pScreen->devPrivates, XAAGetScreenKey()))->AccelInfoRec
1659
1660#define XAA_GET_PIXMAP_PRIVATE(pix)\
1661 (XAAPixmapPtr)dixLookupPrivate(&(pix)->devPrivates, XAAGetPixmapKey())
1662
1663#define CHECK_RGB_EQUAL(c) (!((((c) >> 8) ^ (c)) & 0xffff))
1664
1665#define CHECK_FG(pGC, flags) \
1666 (!(flags & RGB_EQUAL) || CHECK_RGB_EQUAL(pGC->fgPixel))
1667
1668#define CHECK_BG(pGC, flags) \
1669 (!(flags & RGB_EQUAL) || CHECK_RGB_EQUAL(pGC->bgPixel))
1670
1671#define CHECK_ROP(pGC, flags) \
1672 (!(flags & GXCOPY_ONLY) || (pGC->alu == GXcopy))
1673
1674#define CHECK_ROPSRC(pGC, flags) \
1675 (!(flags & ROP_NEEDS_SOURCE) || ((pGC->alu != GXclear) && \
1676 (pGC->alu != GXnoop) && (pGC->alu != GXinvert) && \
1677 (pGC->alu != GXset)))
1678
1679#define CHECK_PLANEMASK(pGC, flags) \
1680 (!(flags & NO_PLANEMASK) || \
1681 ((pGC->planemask & infoRec->FullPlanemasks[pGC->depth - 1]) == \
1682 infoRec->FullPlanemasks[pGC->depth - 1]))
1683
1684#define CHECK_COLORS(pGC, flags) \
1685 (!(flags & RGB_EQUAL) || \
1686 (CHECK_RGB_EQUAL(pGC->fgPixel) && CHECK_RGB_EQUAL(pGC->bgPixel)))
1687
1688#define CHECK_NO_GXCOPY(pGC, flags) \
1689 ((pGC->alu != GXcopy) || !(flags & NO_GXCOPY) || \
1690 ((pGC->planemask & infoRec->FullPlanemask) != infoRec->FullPlanemask))
1691
1692#define IS_OFFSCREEN_PIXMAP(pPix)\
1693 ((XAA_GET_PIXMAP_PRIVATE((PixmapPtr)(pPix)))->offscreenArea)
1694
1695#define PIXMAP_IS_SHARED(pPix)\
1696 ((XAA_GET_PIXMAP_PRIVATE((PixmapPtr)(pPix)))->flags & SHARED_PIXMAP)
1697
1698#define OFFSCREEN_PIXMAP_LOCKED(pPix)\
1699 ((XAA_GET_PIXMAP_PRIVATE((PixmapPtr)(pPix)))->flags & LOCKED_PIXMAP)
1700
1701#define XAA_DEPTH_BUG(pGC) \
1702 ((pGC->depth == 32) && (pGC->bgPixel == 0xffffffff))
1703
1704#define DELIST_OFFSCREEN_PIXMAP(pPix) { \
1705 PixmapLinkPtr _pLink, _prev; \
1706 _pLink = infoRec->OffscreenPixmaps; \
1707 _prev = NULL; \
1708 while(_pLink) { \
1709 if(_pLink->pPix == pPix) { \
1710 if(_prev) _prev->next = _pLink->next; \
1711 else infoRec->OffscreenPixmaps = _pLink->next; \
1712 free(_pLink); \
1713 break; \
1714 } \
1715 _prev = _pLink; \
1716 _pLink = _pLink->next; \
1717 }}
1718
1719
1720#define SWAP_BITS_IN_BYTES(v) \
1721 (((0x01010101 & (v)) << 7) | ((0x02020202 & (v)) << 5) | \
1722 ((0x04040404 & (v)) << 3) | ((0x08080808 & (v)) << 1) | \
1723 ((0x10101010 & (v)) >> 1) | ((0x20202020 & (v)) >> 3) | \
1724 ((0x40404040 & (v)) >> 5) | ((0x80808080 & (v)) >> 7))
1725
1726/*
1727 * Moved XAAPixmapCachePrivate here from xaaPCache.c, since driver
1728 * replacements for CacheMonoStipple need access to it
1729 */
1730
1731typedef struct {
1732 int Num512x512;
1733 int Current512;
1734 XAACacheInfoPtr Info512;
1735 int Num256x256;
1736 int Current256;
1737 XAACacheInfoPtr Info256;
1738 int Num128x128;
1739 int Current128;
1740 XAACacheInfoPtr Info128;
1741 int NumMono;
1742 int CurrentMono;
1743 XAACacheInfoPtr InfoMono;
1744 int NumColor;
1745 int CurrentColor;
1746 XAACacheInfoPtr InfoColor;
1747 int NumPartial;
1748 int CurrentPartial;
1749 XAACacheInfoPtr InfoPartial;
1750 DDXPointRec MonoOffsets[64];
1751 DDXPointRec ColorOffsets[64];
1752} XAAPixmapCachePrivate, *XAAPixmapCachePrivatePtr;
1753
1754
1755#endif /* _XAALOCAL_H */
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