2 /* Copyright (C) 2002 Olivier Chapuis */
7 /* ---------------------------- included header files ---------------------- */
10 #include "PictureBase.h"
13 #define Picture XRenderPicture
14 #include <X11/extensions/Xrender.h>
18 /* ---------------------------- global definitions ------------------------- */
20 /* ---------------------------- global macros ------------------------------ */
22 /* ---------------------------- type definitions --------------------------- */
25 typedef XRenderDirectFormat FRenderDirectFormat
;
26 typedef PictFormat FRPictFormat
;
27 typedef XRenderPictFormat FRenderPictFormat
;
28 typedef XRenderPicture FRenderPicture
;
29 #if 0 /* this has disappeared */
30 typedef XRenderVisual FRenderVisual
;
31 typedef XRenderDepth FRenderDepth
;
32 typedef XRenderInfo FRenderInfo
;
34 typedef XRenderPictureAttributes FRenderPictureAttributes
;
35 typedef XRenderColor FRenderColor
;
36 typedef XGlyphInfo FGlyphInfo
;
38 #define FRenderPictFormatID PictFormatID
39 #define FRenderPictFormatType PictFormatType
40 #define FRenderPictFormatDepth PictFormatDepth
41 #define FRenderPictFormatRed PictFormatRed
42 #define FRenderPictFormatRedMask PictFormatRedMask
43 #define FRenderPictFormatGreen PictFormatGreen
44 #define FRenderPictFormatGreenMask PictFormatGreenMask
45 #define FRenderPictFormatBlue PictFormatBlue
46 #define FRenderPictFormatBlueMask PictFormatBlueMask
47 #define FRenderPictFormatAlpha PictFormatAlpha
48 #define FRenderPictFormatAlphaMask PictFormatAlphaMask
49 #define FRenderPictFormatColormap PictFormatColormap
51 #define FRenderBadPictFormat 0
52 #define FRenderBadPicture 1
53 #define FRenderBadPictOp 2
54 #define FRenderBadGlyphSet 3
55 #define FRenderBadGlyph 4
56 #define FRenderRenderNumberErrors (FRenderBadGlyph+1)
58 #define FRenderPictTypeIndexed PictTypeIndexed
59 #define FRenderPictTypeDirect PictTypeDirect
61 #define FRenderPictOpMinimum PictOpMinimum
62 #define FRenderPictOpClear PictOpClear
63 #define FRenderPictOpSrc PictOpSrc
64 #define FRenderPictOpDst PictOpDst
65 #define FRenderPictOpOver PictOpOver
66 #define FRenderPictOpOverReverse PictOpOverReverse
67 #define FRenderPictOpIn PictOpIn
68 #define FRenderPictOpInReverse PictOpInReverse
69 #define FRenderPictOpOut PictOpOut
70 #define FRenderPictOpOutReverse PictOpOutReverse
71 #define FRenderPictOpAtop PictOpAtop
72 #define FRenderPictOpAtopReverse PictOpAtopReverse
73 #define FRenderPictOpXor PictOpXor
74 #define FRenderPictOpAdd PictOpAdd
75 #define FRenderPictOpSaturate PictOpSaturate
76 #define FRenderPictOpMaximum PictOpMaximum
78 * Operators only available in version 0.2
81 #define FRenderPictOpDisjointMinimum PictOpDisjointMinimum
82 #define FRenderPictOpDisjointClear PictOpDisjointClear
83 #define FRenderPictOpDisjointSrc PictOpDisjointSrc
84 #define FRenderPictOpDisjointDst PictOpDisjointDst
85 #define FRenderPictOpDisjointOver PictOpDisjointOver
86 #define FRenderPictOpDisjointOverReverse PictOpDisjointOverReverse
87 #define FRenderPictOpDisjointIn PictOpDisjointIn
88 #define FRenderPictOpDisjointInReverse PictOpDisjointInReverse
89 #define FRenderPictOpDisjointOut PictOpDisjointOut
90 #define FRenderPictOpDisjointOutReverse PictOpDisjointOutReverse
91 #define FRenderPictOpDisjointAtop PictOpDisjointAtop
92 #define FRenderPictOpDisjointAtopReverse PictOpDisjointAtopReverse
93 #define FRenderPictOpDisjointXor PictOpDisjointXor
94 #define FRenderPictOpDisjointMaximum PictOpDisjointMaximum
96 #define FRenderPictOpConjointMinimum PictOpConjointMinimum
97 #define FRenderPictOpConjointClear PictOpConjointClear
98 #define FRenderPictOpConjointSrc PictOpConjointSrc
99 #define FRenderPictOpConjointDst PictOpConjointDst
100 #define FRenderPictOpConjointOver PictOpConjointOver
101 #define FRenderPictOpConjointOverReverse PictOpConjointOverReverse
102 #define FRenderPictOpConjointIn PictOpConjointIn
103 #define FRenderPictOpConjointInReverse PictOpConjointInReverse
104 #define FRenderPictOpConjointOut PictOpConjointOut
105 #define FRenderPictOpConjointOutReverse PictOpConjointOutReverse
106 #define FRenderPictOpConjointAtop PictOpConjointAtop
107 #define FRenderPictOpConjointAtopReverse PictOpConjointAtopReverse
108 #define FRenderPictOpConjointXor PictOpConjointXor
109 #define FRenderPictOpConjointMaximum PictOpConjointMaximum
112 #define FRenderPolyEdgeSharp PolyEdgeSharp
113 #define FRenderPolyEdgeSmooth PolyEdgeSmooth
115 #define FRenderPolyModePrecise
116 #define FRenderPolyModeImprecise
118 #define FRenderCPRepeat CPRepeat
119 #define FRenderCPAlphaMap CPAlphaMap
120 #define FRenderCPAlphaXOrigin CPAlphaXOrigin
121 #define FRenderCPAlphaYOrigin CPAlphaYOrigin
122 #define FRenderCPClipXOrigin CPClipXOrigin
123 #define FRenderCPClipYOrigin CPClipYOrigin
124 #define FRenderCPClipMask CPClipMask
125 #define FRenderCPGraphicsExposure CPGraphicsExposure
126 #define FRenderCPSubwindowMode CPSubwindowMode
127 #define FRenderCPPolyEdge CPPolyEdge
128 #define FRenderCPPolyMode CPPolyMode
129 #define FRenderCPDither CPDither
130 #define FRenderCPComponentAlpha CPComponentAlpha
131 #define FRenderCPLastBit CPLastBit
133 #define FRenderQueryExtension(a,b,c) XRenderQueryExtension(a,b,c)
134 #define FRenderQueryVersion(a,b,c) XRenderQueryVersion(a,b,c)
135 #define FRenderQueryFormats(a) XRenderQueryFormats(a)
136 #define FRenderFindVisualFormat(a,b) XRenderFindVisualFormat(a,b)
137 #define FRenderFindFormat(a,b,c,d) XRenderFindFormat(a,b,c,d)
138 #define FRenderCreatePicture(a,b,c,d,e) XRenderCreatePicture(a,b,c,d,e)
139 #define FRenderChangePicture(a,b,c,d) XRenderChangePicture(a,b,c,d)
140 #define FRenderSetPictureClipRectangles(a,b,c,d,e,f) \
141 XRenderSetPictureClipRectangles(a,b,c,d,e,f)
142 #define FRenderSetPictureClipRegion(a,b,c) XRenderSetPictureClipRegion(a,b,c)
143 #define FRenderFreePicture(a,b) XRenderFreePicture(a,b)
144 #define FRenderComposite(a,b,c,d,e,f,g,h,i,j,k,l,m) \
145 XRenderComposite(a,b,c,d,e,f,g,h,i,j,k,l,m)
146 #define FRenderFillRectangle(a,b,c,d,e,f,g,h) \
147 XRenderFillRectangle(a,b,c,d,e,f,g,h)
148 #define FRenderFillRectangles(a,b,c,d,e,f) XRenderFillRectangles(a,b,c,d,e,f)
150 #else /* !XRenderSupport */
152 typedef unsigned long FRenderPicture
;
153 typedef unsigned long FRPictFormat
;
164 } FRenderDirectFormat
;
171 FRenderDirectFormat direct
;
178 FRenderPictFormat
*format
;
185 FRenderVisual
*visuals
;
190 FRenderDepth
*depths
;
192 FRenderPictFormat
*fallback
;
195 typedef struct _FRenderInfo
197 FRenderPictFormat
*format
;
199 FRenderScreen
*screen
;
203 FRenderVisual
*visual
;
207 typedef struct _FRenderPictureAttributes
210 FRenderPicture alpha_map
;
216 Bool graphics_exposures
;
221 Bool component_alpha
;
222 } FRenderPictureAttributes
;
226 unsigned short green
;
228 unsigned short alpha
;
230 typedef struct _FGlyphInfo
232 unsigned short width
;
233 unsigned short height
;
240 #define FRenderPictFormatID 0
241 #define FRenderPictFormatType 0
242 #define FRenderPictFormatDepth 0
243 #define FRenderPictFormatRed 0
244 #define FRenderPictFormatRedMask 0
245 #define FRenderPictFormatGreen 0
246 #define FRenderPictFormatGreenMask 0
247 #define FRenderPictFormatBlue 0
248 #define FRenderPictFormatBlueMask 0
249 #define FRenderPictFormatAlpha 0
250 #define FRenderPictFormatAlphaMask 0
251 #define FRenderPictFormatColormap 0
253 #define FRenderBadPictFormat 0
254 #define FRenderBadPicture 1
255 #define FRenderBadPictOp 2
256 #define FRenderBadGlyphSet 3
257 #define FRenderBadGlyph 4
258 #define FRenderRenderNumberErrors (FRenderBadGlyph+1)
260 #define FRenderPictTypeIndexed 0
261 #define FRenderPictTypeDirect 0
263 #define FRenderPictOpMinimum 0
264 #define FRenderPictOpClear 0
265 #define FRenderPictOpSrc 0
266 #define FRenderPictOpDst 0
267 #define FRenderPictOpOver 0
268 #define FRenderPictOpOverReverse 0
269 #define FRenderPictOpIn 0
270 #define FRenderPictOpInReverse 0
271 #define FRenderPictOpOut 0
272 #define FRenderPictOpOutReverse 0
273 #define FRenderPictOpAtop 0
274 #define FRenderPictOpAtopReverse 0
275 #define FRenderPictOpXor 0
276 #define FRenderPictOpAdd 0
277 #define FRenderPictOpSaturate 0
278 #define FRenderPictOpMaximum 0
280 * Operators only available in version 0.2
283 #define FRenderPictOpDisjointMinimum 0
284 #define FRenderPictOpDisjointClear 0
285 #define FRenderPictOpDisjointSrc 0
286 #define FRenderPictOpDisjointDst 0
287 #define FRenderPictOpDisjointOver 0
288 #define FRenderPictOpDisjointOverReverse 0
289 #define FRenderPictOpDisjointIn 0
290 #define FRenderPictOpDisjointInReverse 0
291 #define FRenderPictOpDisjointOut 0
292 #define FRenderPictOpDisjointOutReverse 0
293 #define FRenderPictOpDisjointAtop 0
294 #define FRenderPictOpDisjointAtopReverse 0
295 #define FRenderPictOpDisjointXor 0
296 #define FRenderPictOpDisjointMaximum 0
298 #define FRenderPictOpConjointMinimum 0
299 #define FRenderPictOpConjointClear 0
300 #define FRenderPictOpConjointSrc 0
301 #define FRenderPictOpConjointDst 0
302 #define FRenderPictOpConjointOver 0
303 #define FRenderPictOpConjointOverReverse 0
304 #define FRenderPictOpConjointIn 0
305 #define FRenderPictOpConjointInReverse 0
306 #define FRenderPictOpConjointOut 0
307 #define FRenderPictOpConjointOutReverse 0
308 #define FRenderPictOpConjointAtop 0
309 #define FRenderPictOpConjointAtopReverse 0
310 #define FRenderPictOpConjointXor 0
311 #define FRenderPictOpConjointMaximum 0
314 #define FRenderPolyEdgeSharp 0
315 #define FRenderPolyEdgeSmooth 0
317 #define FRenderPolyModePrecise 0
318 #define FRenderPolyModeImprecise 0
320 #define FRenderCPRepeat 0
321 #define FRenderCPAlphaMap 0
322 #define FRenderCPAlphaXOrigin 0
323 #define FRenderCPAlphaYOrigin 0
324 #define FRenderCPClipXOrigin 0
325 #define FRenderCPClipYOrigin 0
326 #define FRenderCPClipMask 0
327 #define FRenderCPGraphicsExposure 0
328 #define FRenderCPSubwindowMode 0
329 #define FRenderCPPolyEdge 0
330 #define FRenderCPPolyMode 0
331 #define FRenderCPDither 0
332 #define FRenderCPComponentAlpha 0
333 #define FRenderCPLastBit 0
335 #define FRenderQueryExtension(a,b,c) 0
336 #define FRenderQueryVersion(a,b,c) 0
337 #define FRenderQueryFormats(a) 0
338 #define FRenderFindVisualFormat(a,b) NULL
339 #define FRenderFindFormat(a,b,c,d) NULL
340 #define FRenderCreatePicture(a,b,c,d,e) None
341 #define FRenderChangePicture(a,b,c,d)
342 #define FRenderSetPictureClipRectangles(a,b,c,d,e,f)
343 #define FRenderSetPictureClipRegion(a,b,c)
344 #define FRenderFreePicture(a,b)
345 #define FRenderComposite(a,b,c,d,e,f,g,h,i,j,k,l,m)
346 #define FRenderFillRectangle(a,b,c,d,e,f,g,h)
347 #define FRenderFillRectangles(a,b,c,d,e,f)
350 #endif /* FRENDER_H */