DRI XFree86-4_3_99_12-merge import
[xf86-video-sis/mirage.git] / src / sis_dri.h
blobd38e39a05392d4aed9b7e90323be3e0aaa5ba7a3
1 /* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/sis/sis_dri.h,v 1.9 2003/08/29 08:50:54 twini Exp $ */
3 /* modified from tdfx_dri.h */
5 #ifndef _SIS_DRI_
6 #define _SIS_DRI_
8 #include "xf86drm.h"
10 #define SIS_MAX_DRAWABLES 256
11 #define SISIOMAPSIZE (64*1024)
13 typedef struct {
14 int CtxOwner;
15 int QueueLength;
16 unsigned int AGPCmdBufNext;
17 unsigned int FrameCount;
18 #ifdef SIS315DRI
19 /* For 315 series */
20 unsigned long sharedWPoffset;
21 #endif
22 #if 0
23 unsigned char *AGPCmdBufBase;
24 unsigned long AGPCmdBufAddr;
25 unsigned long AGPCmdBufOffset;
26 unsigned int AGPCmdBufSize;
27 unsigned long AGPCmdBufNext;
28 #endif
29 } SISSAREAPriv, *SISSAREAPrivPtr;
31 #define AGPVtxBufNext AGPCmdBufNext
33 #define SIS_FRONT 0
34 #define SIS_BACK 1
35 #define SIS_DEPTH 2
37 typedef struct {
38 drmHandle handle;
39 drmSize size;
40 drmAddress map;
41 } sisRegion, *sisRegionPtr;
43 typedef struct {
44 sisRegion regs, agp;
45 int deviceID;
46 int width;
47 int height;
48 int mem; /* unused in Mesa 3 DRI */
49 int bytesPerPixel;
50 int priv1; /* unused in Mesa 3 DRI */
51 int priv2; /* unused in Mesa 3 DRI */
52 int fbOffset; /* unused in Mesa 3 DRI */
53 int backOffset; /* unused in Mesa 3 DRI */
54 int depthOffset; /* unused in Mesa 3 DRI */
55 int textureOffset; /* unused in Mesa 3 DRI */
56 int textureSize; /* unused in Mesa 3 DRI */
57 unsigned int AGPCmdBufOffset;
58 unsigned int AGPCmdBufSize;
59 int irqEnabled; /* unused in Mesa 3 DRI */
60 unsigned int scrnX, scrnY; /* unused in Mesa 3 DRI */
61 } SISDRIRec, *SISDRIPtr;
63 #define AGPVtxBufOffset AGPCmdBufOffset
64 #define AGPVtxBufSize AGPCmdBufSize
66 typedef struct {
67 /* Nothing here yet */
68 int dummy;
69 } SISConfigPrivRec, *SISConfigPrivPtr;
71 typedef struct {
72 /* Nothing here yet */
73 int dummy;
74 } SISDRIContextRec, *SISDRIContextPtr;
76 #ifdef XFree86Server
78 #include "screenint.h"
80 Bool SISDRIScreenInit(ScreenPtr pScreen);
81 void SISDRICloseScreen(ScreenPtr pScreen);
82 Bool SISDRIFinishScreenInit(ScreenPtr pScreen);
84 #endif
85 #endif