1 | /*
|
---|
2 | * Copyright © 2000 SuSE, Inc.
|
---|
3 | *
|
---|
4 | * Permission to use, copy, modify, distribute, and sell this software and its
|
---|
5 | * documentation for any purpose is hereby granted without fee, provided that
|
---|
6 | * the above copyright notice appear in all copies and that both that
|
---|
7 | * copyright notice and this permission notice appear in supporting
|
---|
8 | * documentation, and that the name of SuSE not be used in advertising or
|
---|
9 | * publicity pertaining to distribution of the software without specific,
|
---|
10 | * written prior permission. SuSE makes no representations about the
|
---|
11 | * suitability of this software for any purpose. It is provided "as is"
|
---|
12 | * without express or implied warranty.
|
---|
13 | *
|
---|
14 | * SuSE DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
|
---|
15 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL SuSE
|
---|
16 | * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
---|
17 | * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
|
---|
18 | * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
|
---|
19 | * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
---|
20 | *
|
---|
21 | * Author: Keith Packard, SuSE, Inc.
|
---|
22 | */
|
---|
23 |
|
---|
24 | #ifndef _PICTURESTR_H_
|
---|
25 | #define _PICTURESTR_H_
|
---|
26 |
|
---|
27 | #include "scrnintstr.h"
|
---|
28 | #include "glyphstr.h"
|
---|
29 | #include "resource.h"
|
---|
30 | #include "privates.h"
|
---|
31 |
|
---|
32 | typedef struct _DirectFormat {
|
---|
33 | CARD16 red, redMask;
|
---|
34 | CARD16 green, greenMask;
|
---|
35 | CARD16 blue, blueMask;
|
---|
36 | CARD16 alpha, alphaMask;
|
---|
37 | } DirectFormatRec;
|
---|
38 |
|
---|
39 | typedef struct _IndexFormat {
|
---|
40 | VisualID vid;
|
---|
41 | ColormapPtr pColormap;
|
---|
42 | int nvalues;
|
---|
43 | xIndexValue *pValues;
|
---|
44 | void *devPrivate;
|
---|
45 | } IndexFormatRec;
|
---|
46 |
|
---|
47 | typedef struct _PictFormat {
|
---|
48 | CARD32 id;
|
---|
49 | CARD32 format; /* except bpp */
|
---|
50 | unsigned char type;
|
---|
51 | unsigned char depth;
|
---|
52 | DirectFormatRec direct;
|
---|
53 | IndexFormatRec index;
|
---|
54 | } PictFormatRec;
|
---|
55 |
|
---|
56 | typedef struct pixman_vector PictVector, *PictVectorPtr;
|
---|
57 | typedef struct pixman_transform PictTransform, *PictTransformPtr;
|
---|
58 |
|
---|
59 | #define pict_f_vector pixman_f_vector
|
---|
60 | #define pict_f_transform pixman_f_transform
|
---|
61 |
|
---|
62 | #define PICT_GRADIENT_STOPTABLE_SIZE 1024
|
---|
63 | #define SourcePictTypeSolidFill 0
|
---|
64 | #define SourcePictTypeLinear 1
|
---|
65 | #define SourcePictTypeRadial 2
|
---|
66 | #define SourcePictTypeConical 3
|
---|
67 |
|
---|
68 | #define SourcePictClassUnknown 0
|
---|
69 | #define SourcePictClassHorizontal 1
|
---|
70 | #define SourcePictClassVertical 2
|
---|
71 |
|
---|
72 | typedef struct _PictSolidFill {
|
---|
73 | unsigned int type;
|
---|
74 | unsigned int class;
|
---|
75 | CARD32 color;
|
---|
76 | } PictSolidFill, *PictSolidFillPtr;
|
---|
77 |
|
---|
78 | typedef struct _PictGradientStop {
|
---|
79 | xFixed x;
|
---|
80 | xRenderColor color;
|
---|
81 | } PictGradientStop, *PictGradientStopPtr;
|
---|
82 |
|
---|
83 | typedef struct _PictGradient {
|
---|
84 | unsigned int type;
|
---|
85 | unsigned int class;
|
---|
86 | int nstops;
|
---|
87 | PictGradientStopPtr stops;
|
---|
88 | int stopRange;
|
---|
89 | CARD32 *colorTable;
|
---|
90 | int colorTableSize;
|
---|
91 | } PictGradient, *PictGradientPtr;
|
---|
92 |
|
---|
93 | typedef struct _PictLinearGradient {
|
---|
94 | unsigned int type;
|
---|
95 | unsigned int class;
|
---|
96 | int nstops;
|
---|
97 | PictGradientStopPtr stops;
|
---|
98 | int stopRange;
|
---|
99 | CARD32 *colorTable;
|
---|
100 | int colorTableSize;
|
---|
101 | xPointFixed p1;
|
---|
102 | xPointFixed p2;
|
---|
103 | } PictLinearGradient, *PictLinearGradientPtr;
|
---|
104 |
|
---|
105 | typedef struct _PictCircle {
|
---|
106 | xFixed x;
|
---|
107 | xFixed y;
|
---|
108 | xFixed radius;
|
---|
109 | } PictCircle, *PictCirclePtr;
|
---|
110 |
|
---|
111 | typedef struct _PictRadialGradient {
|
---|
112 | unsigned int type;
|
---|
113 | unsigned int class;
|
---|
114 | int nstops;
|
---|
115 | PictGradientStopPtr stops;
|
---|
116 | int stopRange;
|
---|
117 | CARD32 *colorTable;
|
---|
118 | int colorTableSize;
|
---|
119 | PictCircle c1;
|
---|
120 | PictCircle c2;
|
---|
121 | double cdx;
|
---|
122 | double cdy;
|
---|
123 | double dr;
|
---|
124 | double A;
|
---|
125 | } PictRadialGradient, *PictRadialGradientPtr;
|
---|
126 |
|
---|
127 | typedef struct _PictConicalGradient {
|
---|
128 | unsigned int type;
|
---|
129 | unsigned int class;
|
---|
130 | int nstops;
|
---|
131 | PictGradientStopPtr stops;
|
---|
132 | int stopRange;
|
---|
133 | CARD32 *colorTable;
|
---|
134 | int colorTableSize;
|
---|
135 | xPointFixed center;
|
---|
136 | xFixed angle;
|
---|
137 | } PictConicalGradient, *PictConicalGradientPtr;
|
---|
138 |
|
---|
139 | typedef union _SourcePict {
|
---|
140 | unsigned int type;
|
---|
141 | PictSolidFill solidFill;
|
---|
142 | PictGradient gradient;
|
---|
143 | PictLinearGradient linear;
|
---|
144 | PictRadialGradient radial;
|
---|
145 | PictConicalGradient conical;
|
---|
146 | } SourcePict, *SourcePictPtr;
|
---|
147 |
|
---|
148 | typedef struct _Picture {
|
---|
149 | DrawablePtr pDrawable;
|
---|
150 | PictFormatPtr pFormat;
|
---|
151 | PictFormatShort format; /* PICT_FORMAT */
|
---|
152 | int refcnt;
|
---|
153 | CARD32 id;
|
---|
154 | PicturePtr pNext; /* chain on same drawable */
|
---|
155 |
|
---|
156 | unsigned int repeat : 1;
|
---|
157 | unsigned int graphicsExposures : 1;
|
---|
158 | unsigned int subWindowMode : 1;
|
---|
159 | unsigned int polyEdge : 1;
|
---|
160 | unsigned int polyMode : 1;
|
---|
161 | unsigned int freeCompClip : 1;
|
---|
162 | unsigned int clientClipType : 2;
|
---|
163 | unsigned int componentAlpha : 1;
|
---|
164 | unsigned int repeatType : 2;
|
---|
165 | unsigned int unused : 21;
|
---|
166 |
|
---|
167 | PicturePtr alphaMap;
|
---|
168 | DDXPointRec alphaOrigin;
|
---|
169 |
|
---|
170 | DDXPointRec clipOrigin;
|
---|
171 | pointer clientClip;
|
---|
172 |
|
---|
173 | Atom dither;
|
---|
174 |
|
---|
175 | unsigned long stateChanges;
|
---|
176 | unsigned long serialNumber;
|
---|
177 |
|
---|
178 | RegionPtr pCompositeClip;
|
---|
179 |
|
---|
180 | PrivateRec *devPrivates;
|
---|
181 |
|
---|
182 | PictTransform *transform;
|
---|
183 |
|
---|
184 | int filter;
|
---|
185 | xFixed *filter_params;
|
---|
186 | int filter_nparams;
|
---|
187 | SourcePictPtr pSourcePict;
|
---|
188 | } PictureRec;
|
---|
189 |
|
---|
190 | typedef Bool (*PictFilterValidateParamsProcPtr) (ScreenPtr pScreen, int id,
|
---|
191 | xFixed *params, int nparams,
|
---|
192 | int *width, int *height);
|
---|
193 | typedef struct {
|
---|
194 | char *name;
|
---|
195 | int id;
|
---|
196 | PictFilterValidateParamsProcPtr ValidateParams;
|
---|
197 | int width, height;
|
---|
198 | } PictFilterRec, *PictFilterPtr;
|
---|
199 |
|
---|
200 | #define PictFilterNearest 0
|
---|
201 | #define PictFilterBilinear 1
|
---|
202 |
|
---|
203 | #define PictFilterFast 2
|
---|
204 | #define PictFilterGood 3
|
---|
205 | #define PictFilterBest 4
|
---|
206 |
|
---|
207 | #define PictFilterConvolution 5
|
---|
208 |
|
---|
209 | typedef struct {
|
---|
210 | char *alias;
|
---|
211 | int alias_id;
|
---|
212 | int filter_id;
|
---|
213 | } PictFilterAliasRec, *PictFilterAliasPtr;
|
---|
214 |
|
---|
215 | typedef int (*CreatePictureProcPtr) (PicturePtr pPicture);
|
---|
216 | typedef void (*DestroyPictureProcPtr) (PicturePtr pPicture);
|
---|
217 | typedef int (*ChangePictureClipProcPtr) (PicturePtr pPicture,
|
---|
218 | int clipType,
|
---|
219 | pointer value,
|
---|
220 | int n);
|
---|
221 | typedef void (*DestroyPictureClipProcPtr)(PicturePtr pPicture);
|
---|
222 |
|
---|
223 | typedef int (*ChangePictureTransformProcPtr) (PicturePtr pPicture,
|
---|
224 | PictTransform *transform);
|
---|
225 |
|
---|
226 | typedef int (*ChangePictureFilterProcPtr) (PicturePtr pPicture,
|
---|
227 | int filter,
|
---|
228 | xFixed *params,
|
---|
229 | int nparams);
|
---|
230 |
|
---|
231 | typedef void (*DestroyPictureFilterProcPtr) (PicturePtr pPicture);
|
---|
232 |
|
---|
233 | typedef void (*ChangePictureProcPtr) (PicturePtr pPicture,
|
---|
234 | Mask mask);
|
---|
235 | typedef void (*ValidatePictureProcPtr) (PicturePtr pPicture,
|
---|
236 | Mask mask);
|
---|
237 | typedef void (*CompositeProcPtr) (CARD8 op,
|
---|
238 | PicturePtr pSrc,
|
---|
239 | PicturePtr pMask,
|
---|
240 | PicturePtr pDst,
|
---|
241 | INT16 xSrc,
|
---|
242 | INT16 ySrc,
|
---|
243 | INT16 xMask,
|
---|
244 | INT16 yMask,
|
---|
245 | INT16 xDst,
|
---|
246 | INT16 yDst,
|
---|
247 | CARD16 width,
|
---|
248 | CARD16 height);
|
---|
249 |
|
---|
250 | typedef void (*GlyphsProcPtr) (CARD8 op,
|
---|
251 | PicturePtr pSrc,
|
---|
252 | PicturePtr pDst,
|
---|
253 | PictFormatPtr maskFormat,
|
---|
254 | INT16 xSrc,
|
---|
255 | INT16 ySrc,
|
---|
256 | int nlists,
|
---|
257 | GlyphListPtr lists,
|
---|
258 | GlyphPtr *glyphs);
|
---|
259 |
|
---|
260 | typedef void (*CompositeRectsProcPtr) (CARD8 op,
|
---|
261 | PicturePtr pDst,
|
---|
262 | xRenderColor *color,
|
---|
263 | int nRect,
|
---|
264 | xRectangle *rects);
|
---|
265 |
|
---|
266 | typedef void (*RasterizeTrapezoidProcPtr)(PicturePtr pMask,
|
---|
267 | xTrapezoid *trap,
|
---|
268 | int x_off,
|
---|
269 | int y_off);
|
---|
270 |
|
---|
271 | typedef void (*TrapezoidsProcPtr) (CARD8 op,
|
---|
272 | PicturePtr pSrc,
|
---|
273 | PicturePtr pDst,
|
---|
274 | PictFormatPtr maskFormat,
|
---|
275 | INT16 xSrc,
|
---|
276 | INT16 ySrc,
|
---|
277 | int ntrap,
|
---|
278 | xTrapezoid *traps);
|
---|
279 |
|
---|
280 | typedef void (*TrianglesProcPtr) (CARD8 op,
|
---|
281 | PicturePtr pSrc,
|
---|
282 | PicturePtr pDst,
|
---|
283 | PictFormatPtr maskFormat,
|
---|
284 | INT16 xSrc,
|
---|
285 | INT16 ySrc,
|
---|
286 | int ntri,
|
---|
287 | xTriangle *tris);
|
---|
288 |
|
---|
289 | typedef void (*TriStripProcPtr) (CARD8 op,
|
---|
290 | PicturePtr pSrc,
|
---|
291 | PicturePtr pDst,
|
---|
292 | PictFormatPtr maskFormat,
|
---|
293 | INT16 xSrc,
|
---|
294 | INT16 ySrc,
|
---|
295 | int npoint,
|
---|
296 | xPointFixed *points);
|
---|
297 |
|
---|
298 | typedef void (*TriFanProcPtr) (CARD8 op,
|
---|
299 | PicturePtr pSrc,
|
---|
300 | PicturePtr pDst,
|
---|
301 | PictFormatPtr maskFormat,
|
---|
302 | INT16 xSrc,
|
---|
303 | INT16 ySrc,
|
---|
304 | int npoint,
|
---|
305 | xPointFixed *points);
|
---|
306 |
|
---|
307 | typedef Bool (*InitIndexedProcPtr) (ScreenPtr pScreen,
|
---|
308 | PictFormatPtr pFormat);
|
---|
309 |
|
---|
310 | typedef void (*CloseIndexedProcPtr) (ScreenPtr pScreen,
|
---|
311 | PictFormatPtr pFormat);
|
---|
312 |
|
---|
313 | typedef void (*UpdateIndexedProcPtr) (ScreenPtr pScreen,
|
---|
314 | PictFormatPtr pFormat,
|
---|
315 | int ndef,
|
---|
316 | xColorItem *pdef);
|
---|
317 |
|
---|
318 | typedef void (*AddTrapsProcPtr) (PicturePtr pPicture,
|
---|
319 | INT16 xOff,
|
---|
320 | INT16 yOff,
|
---|
321 | int ntrap,
|
---|
322 | xTrap *traps);
|
---|
323 |
|
---|
324 | typedef void (*AddTrianglesProcPtr) (PicturePtr pPicture,
|
---|
325 | INT16 xOff,
|
---|
326 | INT16 yOff,
|
---|
327 | int ntri,
|
---|
328 | xTriangle *tris);
|
---|
329 |
|
---|
330 | typedef Bool (*RealizeGlyphProcPtr) (ScreenPtr pScreen,
|
---|
331 | GlyphPtr glyph);
|
---|
332 |
|
---|
333 | typedef void (*UnrealizeGlyphProcPtr) (ScreenPtr pScreen,
|
---|
334 | GlyphPtr glyph);
|
---|
335 |
|
---|
336 | typedef struct _PictureScreen {
|
---|
337 | PictFormatPtr formats;
|
---|
338 | PictFormatPtr fallback;
|
---|
339 | int nformats;
|
---|
340 |
|
---|
341 | CreatePictureProcPtr CreatePicture;
|
---|
342 | DestroyPictureProcPtr DestroyPicture;
|
---|
343 | ChangePictureClipProcPtr ChangePictureClip;
|
---|
344 | DestroyPictureClipProcPtr DestroyPictureClip;
|
---|
345 |
|
---|
346 | ChangePictureProcPtr ChangePicture;
|
---|
347 | ValidatePictureProcPtr ValidatePicture;
|
---|
348 |
|
---|
349 | CompositeProcPtr Composite;
|
---|
350 | GlyphsProcPtr Glyphs; /* unused */
|
---|
351 | CompositeRectsProcPtr CompositeRects;
|
---|
352 |
|
---|
353 | DestroyWindowProcPtr DestroyWindow;
|
---|
354 | CloseScreenProcPtr CloseScreen;
|
---|
355 |
|
---|
356 | StoreColorsProcPtr StoreColors;
|
---|
357 |
|
---|
358 | InitIndexedProcPtr InitIndexed;
|
---|
359 | CloseIndexedProcPtr CloseIndexed;
|
---|
360 | UpdateIndexedProcPtr UpdateIndexed;
|
---|
361 |
|
---|
362 | int subpixel;
|
---|
363 |
|
---|
364 | PictFilterPtr filters;
|
---|
365 | int nfilters;
|
---|
366 | PictFilterAliasPtr filterAliases;
|
---|
367 | int nfilterAliases;
|
---|
368 |
|
---|
369 | /**
|
---|
370 | * Called immediately after a picture's transform is changed through the
|
---|
371 | * SetPictureTransform request. Not called for source-only pictures.
|
---|
372 | */
|
---|
373 | ChangePictureTransformProcPtr ChangePictureTransform;
|
---|
374 |
|
---|
375 | /**
|
---|
376 | * Called immediately after a picture's transform is changed through the
|
---|
377 | * SetPictureFilter request. Not called for source-only pictures.
|
---|
378 | */
|
---|
379 | ChangePictureFilterProcPtr ChangePictureFilter;
|
---|
380 |
|
---|
381 | DestroyPictureFilterProcPtr DestroyPictureFilter;
|
---|
382 |
|
---|
383 | TrapezoidsProcPtr Trapezoids;
|
---|
384 | TrianglesProcPtr Triangles;
|
---|
385 | TriStripProcPtr TriStrip;
|
---|
386 | TriFanProcPtr TriFan;
|
---|
387 |
|
---|
388 | RasterizeTrapezoidProcPtr RasterizeTrapezoid;
|
---|
389 |
|
---|
390 | AddTrianglesProcPtr AddTriangles;
|
---|
391 |
|
---|
392 | AddTrapsProcPtr AddTraps;
|
---|
393 |
|
---|
394 | RealizeGlyphProcPtr RealizeGlyph;
|
---|
395 | UnrealizeGlyphProcPtr UnrealizeGlyph;
|
---|
396 |
|
---|
397 | } PictureScreenRec, *PictureScreenPtr;
|
---|
398 |
|
---|
399 | extern _X_EXPORT DevPrivateKeyRec PictureScreenPrivateKeyRec;
|
---|
400 | #define PictureScreenPrivateKey (&PictureScreenPrivateKeyRec)
|
---|
401 |
|
---|
402 | extern _X_EXPORT DevPrivateKeyRec PictureWindowPrivateKeyRec;
|
---|
403 | #define PictureWindowPrivateKey (&PictureWindowPrivateKeyRec)
|
---|
404 |
|
---|
405 | extern _X_EXPORT RESTYPE PictureType;
|
---|
406 | extern _X_EXPORT RESTYPE PictFormatType;
|
---|
407 | extern _X_EXPORT RESTYPE GlyphSetType;
|
---|
408 |
|
---|
409 | #define GetPictureScreen(s) ((PictureScreenPtr)dixLookupPrivate(&(s)->devPrivates, PictureScreenPrivateKey))
|
---|
410 | #define GetPictureScreenIfSet(s) (dixPrivateKeyRegistered(PictureScreenPrivateKey) ? GetPictureScreen(s) : NULL)
|
---|
411 | #define SetPictureScreen(s,p) dixSetPrivate(&(s)->devPrivates, PictureScreenPrivateKey, p)
|
---|
412 | #define GetPictureWindow(w) ((PicturePtr)dixLookupPrivate(&(w)->devPrivates, PictureWindowPrivateKey))
|
---|
413 | #define SetPictureWindow(w,p) dixSetPrivate(&(w)->devPrivates, PictureWindowPrivateKey, p)
|
---|
414 |
|
---|
415 | #define VERIFY_PICTURE(pPicture, pid, client, mode) {\
|
---|
416 | int rc = dixLookupResourceByType((pointer)&(pPicture), pid,\
|
---|
417 | PictureType, client, mode);\
|
---|
418 | if (rc != Success)\
|
---|
419 | return rc;\
|
---|
420 | }
|
---|
421 |
|
---|
422 | #define VERIFY_ALPHA(pPicture, pid, client, mode) {\
|
---|
423 | if (pid == None) \
|
---|
424 | pPicture = 0; \
|
---|
425 | else { \
|
---|
426 | VERIFY_PICTURE(pPicture, pid, client, mode); \
|
---|
427 | } \
|
---|
428 | } \
|
---|
429 |
|
---|
430 | extern _X_EXPORT Bool
|
---|
431 | PictureDestroyWindow (WindowPtr pWindow);
|
---|
432 |
|
---|
433 | extern _X_EXPORT Bool
|
---|
434 | PictureCloseScreen (int Index, ScreenPtr pScreen);
|
---|
435 |
|
---|
436 | extern _X_EXPORT void
|
---|
437 | PictureStoreColors (ColormapPtr pColormap, int ndef, xColorItem *pdef);
|
---|
438 |
|
---|
439 | extern _X_EXPORT Bool
|
---|
440 | PictureInitIndexedFormat (ScreenPtr pScreen, PictFormatPtr format);
|
---|
441 |
|
---|
442 | extern _X_EXPORT Bool
|
---|
443 | PictureSetSubpixelOrder (ScreenPtr pScreen, int subpixel);
|
---|
444 |
|
---|
445 | extern _X_EXPORT int
|
---|
446 | PictureGetSubpixelOrder (ScreenPtr pScreen);
|
---|
447 |
|
---|
448 | extern _X_EXPORT PictFormatPtr
|
---|
449 | PictureCreateDefaultFormats (ScreenPtr pScreen, int *nformatp);
|
---|
450 |
|
---|
451 | extern _X_EXPORT PictFormatPtr
|
---|
452 | PictureMatchVisual (ScreenPtr pScreen, int depth, VisualPtr pVisual);
|
---|
453 |
|
---|
454 | extern _X_EXPORT PictFormatPtr
|
---|
455 | PictureMatchFormat (ScreenPtr pScreen, int depth, CARD32 format);
|
---|
456 |
|
---|
457 | extern _X_EXPORT Bool
|
---|
458 | PictureInit (ScreenPtr pScreen, PictFormatPtr formats, int nformats);
|
---|
459 |
|
---|
460 | extern _X_EXPORT int
|
---|
461 | PictureGetFilterId (char *filter, int len, Bool makeit);
|
---|
462 |
|
---|
463 | extern _X_EXPORT char *
|
---|
464 | PictureGetFilterName (int id);
|
---|
465 |
|
---|
466 | extern _X_EXPORT int
|
---|
467 | PictureAddFilter (ScreenPtr pScreen,
|
---|
468 | char *filter,
|
---|
469 | PictFilterValidateParamsProcPtr ValidateParams,
|
---|
470 | int width,
|
---|
471 | int height);
|
---|
472 |
|
---|
473 | extern _X_EXPORT Bool
|
---|
474 | PictureSetFilterAlias (ScreenPtr pScreen, char *filter, char *alias);
|
---|
475 |
|
---|
476 | extern _X_EXPORT Bool
|
---|
477 | PictureSetDefaultFilters (ScreenPtr pScreen);
|
---|
478 |
|
---|
479 | extern _X_EXPORT void
|
---|
480 | PictureResetFilters (ScreenPtr pScreen);
|
---|
481 |
|
---|
482 | extern _X_EXPORT PictFilterPtr
|
---|
483 | PictureFindFilter (ScreenPtr pScreen, char *name, int len);
|
---|
484 |
|
---|
485 | extern _X_EXPORT int
|
---|
486 | SetPicturePictFilter (PicturePtr pPicture, PictFilterPtr pFilter,
|
---|
487 | xFixed *params, int nparams);
|
---|
488 |
|
---|
489 | extern _X_EXPORT int
|
---|
490 | SetPictureFilter (PicturePtr pPicture, char *name, int len,
|
---|
491 | xFixed *params, int nparams);
|
---|
492 |
|
---|
493 | extern _X_EXPORT Bool
|
---|
494 | PictureFinishInit (void);
|
---|
495 |
|
---|
496 | extern _X_EXPORT void
|
---|
497 | SetPictureToDefaults (PicturePtr pPicture);
|
---|
498 |
|
---|
499 | extern _X_EXPORT PicturePtr
|
---|
500 | CreatePicture (Picture pid,
|
---|
501 | DrawablePtr pDrawable,
|
---|
502 | PictFormatPtr pFormat,
|
---|
503 | Mask mask,
|
---|
504 | XID *list,
|
---|
505 | ClientPtr client,
|
---|
506 | int *error);
|
---|
507 |
|
---|
508 | extern _X_EXPORT int
|
---|
509 | ChangePicture (PicturePtr pPicture,
|
---|
510 | Mask vmask,
|
---|
511 | XID *vlist,
|
---|
512 | DevUnion *ulist,
|
---|
513 | ClientPtr client);
|
---|
514 |
|
---|
515 | extern _X_EXPORT int
|
---|
516 | SetPictureClipRects (PicturePtr pPicture,
|
---|
517 | int xOrigin,
|
---|
518 | int yOrigin,
|
---|
519 | int nRect,
|
---|
520 | xRectangle *rects);
|
---|
521 |
|
---|
522 | extern _X_EXPORT int
|
---|
523 | SetPictureClipRegion (PicturePtr pPicture,
|
---|
524 | int xOrigin,
|
---|
525 | int yOrigin,
|
---|
526 | RegionPtr pRegion);
|
---|
527 |
|
---|
528 | extern _X_EXPORT int
|
---|
529 | SetPictureTransform (PicturePtr pPicture,
|
---|
530 | PictTransform *transform);
|
---|
531 |
|
---|
532 | extern _X_EXPORT void
|
---|
533 | CopyPicture (PicturePtr pSrc,
|
---|
534 | Mask mask,
|
---|
535 | PicturePtr pDst);
|
---|
536 |
|
---|
537 | extern _X_EXPORT void
|
---|
538 | ValidatePicture(PicturePtr pPicture);
|
---|
539 |
|
---|
540 | extern _X_EXPORT int
|
---|
541 | FreePicture (pointer pPicture,
|
---|
542 | XID pid);
|
---|
543 |
|
---|
544 | extern _X_EXPORT int
|
---|
545 | FreePictFormat (pointer pPictFormat,
|
---|
546 | XID pid);
|
---|
547 |
|
---|
548 | extern _X_EXPORT void
|
---|
549 | CompositePicture (CARD8 op,
|
---|
550 | PicturePtr pSrc,
|
---|
551 | PicturePtr pMask,
|
---|
552 | PicturePtr pDst,
|
---|
553 | INT16 xSrc,
|
---|
554 | INT16 ySrc,
|
---|
555 | INT16 xMask,
|
---|
556 | INT16 yMask,
|
---|
557 | INT16 xDst,
|
---|
558 | INT16 yDst,
|
---|
559 | CARD16 width,
|
---|
560 | CARD16 height);
|
---|
561 |
|
---|
562 | extern _X_EXPORT void
|
---|
563 | CompositeGlyphs (CARD8 op,
|
---|
564 | PicturePtr pSrc,
|
---|
565 | PicturePtr pDst,
|
---|
566 | PictFormatPtr maskFormat,
|
---|
567 | INT16 xSrc,
|
---|
568 | INT16 ySrc,
|
---|
569 | int nlist,
|
---|
570 | GlyphListPtr lists,
|
---|
571 | GlyphPtr *glyphs);
|
---|
572 |
|
---|
573 | extern _X_EXPORT void
|
---|
574 | CompositeRects (CARD8 op,
|
---|
575 | PicturePtr pDst,
|
---|
576 | xRenderColor *color,
|
---|
577 | int nRect,
|
---|
578 | xRectangle *rects);
|
---|
579 |
|
---|
580 | extern _X_EXPORT void
|
---|
581 | CompositeTrapezoids (CARD8 op,
|
---|
582 | PicturePtr pSrc,
|
---|
583 | PicturePtr pDst,
|
---|
584 | PictFormatPtr maskFormat,
|
---|
585 | INT16 xSrc,
|
---|
586 | INT16 ySrc,
|
---|
587 | int ntrap,
|
---|
588 | xTrapezoid *traps);
|
---|
589 |
|
---|
590 | extern _X_EXPORT void
|
---|
591 | CompositeTriangles (CARD8 op,
|
---|
592 | PicturePtr pSrc,
|
---|
593 | PicturePtr pDst,
|
---|
594 | PictFormatPtr maskFormat,
|
---|
595 | INT16 xSrc,
|
---|
596 | INT16 ySrc,
|
---|
597 | int ntriangles,
|
---|
598 | xTriangle *triangles);
|
---|
599 |
|
---|
600 | extern _X_EXPORT void
|
---|
601 | CompositeTriStrip (CARD8 op,
|
---|
602 | PicturePtr pSrc,
|
---|
603 | PicturePtr pDst,
|
---|
604 | PictFormatPtr maskFormat,
|
---|
605 | INT16 xSrc,
|
---|
606 | INT16 ySrc,
|
---|
607 | int npoints,
|
---|
608 | xPointFixed *points);
|
---|
609 |
|
---|
610 | extern _X_EXPORT void
|
---|
611 | CompositeTriFan (CARD8 op,
|
---|
612 | PicturePtr pSrc,
|
---|
613 | PicturePtr pDst,
|
---|
614 | PictFormatPtr maskFormat,
|
---|
615 | INT16 xSrc,
|
---|
616 | INT16 ySrc,
|
---|
617 | int npoints,
|
---|
618 | xPointFixed *points);
|
---|
619 |
|
---|
620 | extern _X_EXPORT CARD32
|
---|
621 | PictureGradientColor (PictGradientStopPtr stop1,
|
---|
622 | PictGradientStopPtr stop2,
|
---|
623 | CARD32 x);
|
---|
624 |
|
---|
625 | extern _X_EXPORT void RenderExtensionInit (void);
|
---|
626 |
|
---|
627 | Bool
|
---|
628 | AnimCurInit (ScreenPtr pScreen);
|
---|
629 |
|
---|
630 | int
|
---|
631 | AnimCursorCreate (CursorPtr *cursors, CARD32 *deltas, int ncursor, CursorPtr *ppCursor, ClientPtr client, XID cid);
|
---|
632 |
|
---|
633 | extern _X_EXPORT void
|
---|
634 | AddTraps (PicturePtr pPicture,
|
---|
635 | INT16 xOff,
|
---|
636 | INT16 yOff,
|
---|
637 | int ntraps,
|
---|
638 | xTrap *traps);
|
---|
639 |
|
---|
640 | extern _X_EXPORT PicturePtr
|
---|
641 | CreateSolidPicture (Picture pid,
|
---|
642 | xRenderColor *color,
|
---|
643 | int *error);
|
---|
644 |
|
---|
645 | extern _X_EXPORT PicturePtr
|
---|
646 | CreateLinearGradientPicture (Picture pid,
|
---|
647 | xPointFixed *p1,
|
---|
648 | xPointFixed *p2,
|
---|
649 | int nStops,
|
---|
650 | xFixed *stops,
|
---|
651 | xRenderColor *colors,
|
---|
652 | int *error);
|
---|
653 |
|
---|
654 | extern _X_EXPORT PicturePtr
|
---|
655 | CreateRadialGradientPicture (Picture pid,
|
---|
656 | xPointFixed *inner,
|
---|
657 | xPointFixed *outer,
|
---|
658 | xFixed innerRadius,
|
---|
659 | xFixed outerRadius,
|
---|
660 | int nStops,
|
---|
661 | xFixed *stops,
|
---|
662 | xRenderColor *colors,
|
---|
663 | int *error);
|
---|
664 |
|
---|
665 | extern _X_EXPORT PicturePtr
|
---|
666 | CreateConicalGradientPicture (Picture pid,
|
---|
667 | xPointFixed *center,
|
---|
668 | xFixed angle,
|
---|
669 | int nStops,
|
---|
670 | xFixed *stops,
|
---|
671 | xRenderColor *colors,
|
---|
672 | int *error);
|
---|
673 |
|
---|
674 | #ifdef PANORAMIX
|
---|
675 | extern _X_EXPORT void PanoramiXRenderInit (void);
|
---|
676 | extern _X_EXPORT void PanoramiXRenderReset (void);
|
---|
677 | #endif
|
---|
678 |
|
---|
679 | /*
|
---|
680 | * matrix.c
|
---|
681 | */
|
---|
682 |
|
---|
683 | extern _X_EXPORT void
|
---|
684 | PictTransform_from_xRenderTransform (PictTransformPtr pict,
|
---|
685 | xRenderTransform *render);
|
---|
686 |
|
---|
687 | extern _X_EXPORT void
|
---|
688 | xRenderTransform_from_PictTransform (xRenderTransform *render,
|
---|
689 | PictTransformPtr pict);
|
---|
690 |
|
---|
691 | extern _X_EXPORT Bool
|
---|
692 | PictureTransformPoint (PictTransformPtr transform,
|
---|
693 | PictVectorPtr vector);
|
---|
694 |
|
---|
695 | extern _X_EXPORT Bool
|
---|
696 | PictureTransformPoint3d (PictTransformPtr transform,
|
---|
697 | PictVectorPtr vector);
|
---|
698 |
|
---|
699 | #endif /* _PICTURESTR_H_ */
|
---|