summaryrefslogtreecommitdiff
path: root/fb/fb.h
diff options
context:
space:
mode:
authorAdam Jackson <ajax@nwnk.net>2004-07-30 20:30:57 +0000
committerAdam Jackson <ajax@nwnk.net>2004-07-30 20:30:57 +0000
commit48514fee3c8ec26f36e142ffc9272e510b9a4238 (patch)
tree2f0aaa0b3861f7ace00d2c1f5d0bc6a5e0ab8e93 /fb/fb.h
parent29012adb37c533f57c684ad94c4d83a6c31793e5 (diff)
Bug #400 (partial): Driver fixes for the dlloader. When using dlloader, all
framebuffer formats except cfb and the overlay modes should work, and r128 and radeon need to be loaded from the ati driver (both issues to be fixed soon). Tested on i740, s3virge, mach64, tdfx, vesa, and vga drivers. elfloader users shouldn't be affected.
Diffstat (limited to 'fb/fb.h')
-rw-r--r--fb/fb.h13
1 files changed, 9 insertions, 4 deletions
diff --git a/fb/fb.h b/fb/fb.h
index 0b5c98aff..d9bd145c2 100644
--- a/fb/fb.h
+++ b/fb/fb.h
@@ -22,7 +22,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $XdotOrg$ */
+/* $XdotOrg: xc/programs/Xserver/fb/fb.h,v 1.4 2004/06/21 13:51:57 ago Exp $ */
#ifndef _FB_H_
#define _FB_H_
@@ -564,9 +564,13 @@ extern void fbSetBits (FbStip *bits, int stride, FbStip data);
} \
}
+/* XXX fb*PrivateIndex should be static, but it breaks the ABI */
+
extern int fbGCPrivateIndex;
+extern int fbGetGCPrivateIndex(void);
#ifndef FB_NO_WINDOW_PIXMAPS
extern int fbWinPrivateIndex;
+extern int fbGetWinPrivateIndex(void);
#endif
extern const GCOps fbGCOps;
extern const GCFuncs fbGCFuncs;
@@ -587,6 +591,7 @@ extern WindowPtr *WindowTable;
#ifdef FB_SCREEN_PRIVATE
extern int fbScreenPrivateIndex;
+extern int fbGetScreenPrivateIndex(void);
/* private field of a screen */
typedef struct {
@@ -595,7 +600,7 @@ typedef struct {
} FbScreenPrivRec, *FbScreenPrivPtr;
#define fbGetScreenPrivate(pScreen) ((FbScreenPrivPtr) \
- (pScreen)->devPrivates[fbScreenPrivateIndex].ptr)
+ (pScreen)->devPrivates[fbGetScreenPrivateIndex()].ptr)
#endif
/* private field of GC */
@@ -619,7 +624,7 @@ typedef struct {
} FbGCPrivRec, *FbGCPrivPtr;
#define fbGetGCPrivate(pGC) ((FbGCPrivPtr)\
- (pGC)->devPrivates[fbGCPrivateIndex].ptr)
+ (pGC)->devPrivates[fbGetGCPrivateIndex()].ptr)
#ifdef FB_OLD_GC
#define fbGetCompositeClip(pGC) (fbGetGCPrivate(pGC)->pCompositeClip)
@@ -638,7 +643,7 @@ typedef struct {
#define fbGetWindowPixmap(d) fbGetScreenPixmap(((DrawablePtr) (d))->pScreen)
#else
#define fbGetWindowPixmap(pWin) ((PixmapPtr)\
- ((WindowPtr) (pWin))->devPrivates[fbWinPrivateIndex].ptr)
+ ((WindowPtr) (pWin))->devPrivates[fbGetWinPrivateIndex()].ptr)
#endif
#if defined(__DARWIN__)||defined(__CYGWIN__)