1 | /*
|
---|
2 | *
|
---|
3 | * Copyright © 2000 SuSE, Inc.
|
---|
4 | *
|
---|
5 | * Permission to use, copy, modify, distribute, and sell this software and its
|
---|
6 | * documentation for any purpose is hereby granted without fee, provided that
|
---|
7 | * the above copyright notice appear in all copies and that both that
|
---|
8 | * copyright notice and this permission notice appear in supporting
|
---|
9 | * documentation, and that the name of SuSE not be used in advertising or
|
---|
10 | * publicity pertaining to distribution of the software without specific,
|
---|
11 | * written prior permission. SuSE makes no representations about the
|
---|
12 | * suitability of this software for any purpose. It is provided "as is"
|
---|
13 | * without express or implied warranty.
|
---|
14 | *
|
---|
15 | * SuSE DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
|
---|
16 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL SuSE
|
---|
17 | * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
---|
18 | * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
|
---|
19 | * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
|
---|
20 | * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
---|
21 | *
|
---|
22 | * Author: Keith Packard, SuSE, Inc.
|
---|
23 | */
|
---|
24 |
|
---|
25 | #ifndef _FBOVERLAY_H_
|
---|
26 | #define _FBOVERLAY_H_
|
---|
27 |
|
---|
28 | #include "privates.h"
|
---|
29 |
|
---|
30 | extern _X_EXPORT DevPrivateKey fbOverlayGetScreenPrivateKey(void);
|
---|
31 |
|
---|
32 | #ifndef FB_OVERLAY_MAX
|
---|
33 | #define FB_OVERLAY_MAX 2
|
---|
34 | #endif
|
---|
35 |
|
---|
36 | typedef void (*fbOverlayPaintKeyProc) (DrawablePtr, RegionPtr, CARD32, int);
|
---|
37 |
|
---|
38 | typedef struct _fbOverlayLayer {
|
---|
39 | union {
|
---|
40 | struct {
|
---|
41 | pointer pbits;
|
---|
42 | int width;
|
---|
43 | int depth;
|
---|
44 | } init;
|
---|
45 | struct {
|
---|
46 | PixmapPtr pixmap;
|
---|
47 | RegionRec region;
|
---|
48 | } run;
|
---|
49 | } u;
|
---|
50 | CARD32 key; /* special pixel value */
|
---|
51 | } FbOverlayLayer;
|
---|
52 |
|
---|
53 | typedef struct _fbOverlayScrPriv {
|
---|
54 | int nlayers;
|
---|
55 | fbOverlayPaintKeyProc PaintKey;
|
---|
56 | miCopyProc CopyWindow;
|
---|
57 | FbOverlayLayer layer[FB_OVERLAY_MAX];
|
---|
58 | } FbOverlayScrPrivRec, *FbOverlayScrPrivPtr;
|
---|
59 |
|
---|
60 | #define fbOverlayGetScrPriv(s) \
|
---|
61 | dixLookupPrivate(&(s)->devPrivates, fbOverlayGetScreenPrivateKey())
|
---|
62 | extern _X_EXPORT Bool
|
---|
63 | fbOverlayCreateWindow(WindowPtr pWin);
|
---|
64 |
|
---|
65 | extern _X_EXPORT Bool
|
---|
66 | fbOverlayCloseScreen (int iScreen, ScreenPtr pScreen);
|
---|
67 |
|
---|
68 | extern _X_EXPORT int
|
---|
69 | fbOverlayWindowLayer(WindowPtr pWin);
|
---|
70 |
|
---|
71 | extern _X_EXPORT Bool
|
---|
72 | fbOverlayCreateScreenResources(ScreenPtr pScreen);
|
---|
73 |
|
---|
74 | extern _X_EXPORT void
|
---|
75 | fbOverlayPaintKey (DrawablePtr pDrawable,
|
---|
76 | RegionPtr pRegion,
|
---|
77 | CARD32 pixel,
|
---|
78 | int layer);
|
---|
79 | extern _X_EXPORT void
|
---|
80 | fbOverlayUpdateLayerRegion (ScreenPtr pScreen,
|
---|
81 | int layer,
|
---|
82 | RegionPtr prgn);
|
---|
83 |
|
---|
84 |
|
---|
85 | extern _X_EXPORT void
|
---|
86 | fbOverlayCopyWindow(WindowPtr pWin,
|
---|
87 | DDXPointRec ptOldOrg,
|
---|
88 | RegionPtr prgnSrc);
|
---|
89 |
|
---|
90 | extern _X_EXPORT void
|
---|
91 | fbOverlayWindowExposures (WindowPtr pWin,
|
---|
92 | RegionPtr prgn,
|
---|
93 | RegionPtr other_exposed);
|
---|
94 |
|
---|
95 | extern _X_EXPORT Bool
|
---|
96 | fbOverlaySetupScreen(ScreenPtr pScreen,
|
---|
97 | pointer pbits1,
|
---|
98 | pointer pbits2,
|
---|
99 | int xsize,
|
---|
100 | int ysize,
|
---|
101 | int dpix,
|
---|
102 | int dpiy,
|
---|
103 | int width1,
|
---|
104 | int width2,
|
---|
105 | int bpp1,
|
---|
106 | int bpp2);
|
---|
107 |
|
---|
108 | extern _X_EXPORT Bool
|
---|
109 | fbOverlayFinishScreenInit(ScreenPtr pScreen,
|
---|
110 | pointer pbits1,
|
---|
111 | pointer pbits2,
|
---|
112 | int xsize,
|
---|
113 | int ysize,
|
---|
114 | int dpix,
|
---|
115 | int dpiy,
|
---|
116 | int width1,
|
---|
117 | int width2,
|
---|
118 | int bpp1,
|
---|
119 | int bpp2,
|
---|
120 | int depth1,
|
---|
121 | int depth2);
|
---|
122 |
|
---|
123 | #endif /* _FBOVERLAY_H_ */
|
---|