VirtualBox

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

最後變更 在這個檔案從61386是 51223,由 vboxsync 提交於 11 年 前

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

  • 屬性 svn:executable 設為 *
檔案大小: 3.5 KB
 
1/*
2 * $Id: damagestr.h,v 1.6 2005/07/03 07:02:01 daniels Exp $
3 *
4 * Copyright © 2003 Keith Packard
5 *
6 * Permission to use, copy, modify, distribute, and sell this software and its
7 * documentation for any purpose is hereby granted without fee, provided that
8 * the above copyright notice appear in all copies and that both that
9 * copyright notice and this permission notice appear in supporting
10 * documentation, and that the name of Keith Packard not be used in
11 * advertising or publicity pertaining to distribution of the software without
12 * specific, written prior permission. Keith Packard makes no
13 * representations about the suitability of this software for any purpose. It
14 * is provided "as is" without express or implied warranty.
15 *
16 * KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
17 * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
18 * EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR
19 * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
20 * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
21 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
22 * PERFORMANCE OF THIS SOFTWARE.
23 */
24
25#ifdef HAVE_DIX_CONFIG_H
26#include <dix-config.h>
27#endif
28
29#ifndef _DAMAGESTR_H_
30#define _DAMAGESTR_H_
31
32#include "damage.h"
33#ifdef RENDER
34# include "picturestr.h"
35#endif
36
37typedef struct _damage {
38 DamagePtr pNext;
39 DamagePtr pNextWin;
40 RegionRec damage;
41
42 DamageReportLevel damageLevel;
43 Bool isInternal;
44 void *closure;
45 Bool isWindow;
46 DrawablePtr pDrawable;
47
48 DamageReportFunc damageReport;
49 DamageDestroyFunc damageDestroy;
50} DamageRec;
51
52typedef struct _damageScrPriv {
53 int internalLevel;
54
55 /*
56 * For DDXen which don't provide GetScreenPixmap, this provides
57 * a place to hook damage for windows on the screen
58 */
59 DamagePtr pScreenDamage;
60
61 PaintWindowBackgroundProcPtr PaintWindowBackground;
62 PaintWindowBorderProcPtr PaintWindowBorder;
63 CopyWindowProcPtr CopyWindow;
64 CloseScreenProcPtr CloseScreen;
65 CreateGCProcPtr CreateGC;
66 DestroyPixmapProcPtr DestroyPixmap;
67 SetWindowPixmapProcPtr SetWindowPixmap;
68 DestroyWindowProcPtr DestroyWindow;
69#ifdef RENDER
70 CompositeProcPtr Composite;
71 GlyphsProcPtr Glyphs;
72#endif
73 BSFuncRec BackingStoreFuncs;
74} DamageScrPrivRec, *DamageScrPrivPtr;
75
76typedef struct _damageGCPriv {
77 GCOps *ops;
78 GCFuncs *funcs;
79} DamageGCPrivRec, *DamageGCPrivPtr;
80
81extern int damageScrPrivateIndex;
82extern int damagePixPrivateIndex;
83extern int damageGCPrivateIndex;
84extern int damageWinPrivateIndex;
85
86#define damageGetScrPriv(pScr) \
87 ((DamageScrPrivPtr) (pScr)->devPrivates[damageScrPrivateIndex].ptr)
88
89#define damageScrPriv(pScr) \
90 DamageScrPrivPtr pScrPriv = damageGetScrPriv(pScr)
91
92#define damageGetPixPriv(pPix) \
93 ((DamagePtr) (pPix)->devPrivates[damagePixPrivateIndex].ptr)
94
95#define damgeSetPixPriv(pPix,v) \
96 ((pPix)->devPrivates[damagePixPrivateIndex].ptr = (pointer ) (v))
97
98#define damagePixPriv(pPix) \
99 DamagePtr pDamage = damageGetPixPriv(pPix)
100
101#define damageGetGCPriv(pGC) \
102 ((DamageGCPrivPtr) (pGC)->devPrivates[damageGCPrivateIndex].ptr)
103
104#define damageGCPriv(pGC) \
105 DamageGCPrivPtr pGCPriv = damageGetGCPriv(pGC)
106
107#define damageGetWinPriv(pWin) \
108 ((DamagePtr) (pWin)->devPrivates[damageWinPrivateIndex].ptr)
109
110#define damageSetWinPriv(pWin,d) \
111 ((pWin)->devPrivates[damageWinPrivateIndex].ptr = (d))
112
113#endif /* _DAMAGESTR_H_ */
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

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