Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nx-libs
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dimbor
nx-libs
Commits
5365f905
Commit
5365f905
authored
May 27, 2015
by
Mike Gabriel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
library clean-up: Drop nx-X11/lib/Xxf86rush and references to libglide{2,3}. Unused in nx-libs.
parent
fb2a4e4c
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
0 additions
and
792 deletions
+0
-792
Imake.tmpl
nx-X11/config/cf/Imake.tmpl
+0
-30
X11.tmpl
nx-X11/config/cf/X11.tmpl
+0
-40
host.def
nx-X11/config/cf/host.def
+0
-44
linux.cf
nx-X11/config/cf/linux.cf
+0
-20
xorg.cf
nx-X11/config/cf/xorg.cf
+0
-7
xorgsite.def
nx-X11/config/cf/xorgsite.def
+0
-42
Imakefile
nx-X11/include/extensions/Imakefile
+0
-6
xf86rush.h
nx-X11/include/extensions/xf86rush.h
+0
-113
xf86rushstr.h
nx-X11/include/extensions/xf86rushstr.h
+0
-163
Imakefile
nx-X11/lib/Imakefile
+0
-6
Imakefile
nx-X11/lib/Xxf86rush/Imakefile
+0
-30
XF86Rush.c
nx-X11/lib/Xxf86rush/XF86Rush.c
+0
-291
No files found.
nx-X11/config/cf/Imake.tmpl
View file @
5365f905
...
...
@@ -651,36 +651,6 @@ NCURSESLIBDIR = NCursesLibDir
#ifdef NCursesIncDir
NCURSESINCDIR = NCursesIncDir
#endif
#ifndef HasGlide2
#define HasGlide2 NO
#endif
#ifndef Glide2IncDir
#if HasGlide2
#define Glide2IncDir /usr/include/glide
#else
#define Glide2IncDir
#endif
#endif
GLIDE2INCDIR = Glide2IncDir
#ifndef HasGlide3
#define HasGlide3 NO
#endif
#ifndef Glide3IncDir
#if HasGlide3
#define Glide3IncDir /usr/include/glide3
#else
#define Glide3IncDir
#endif
#endif
GLIDE3INCDIR = Glide3IncDir
#ifndef Glide3LibName
#if HasGlide3
#define Glide3LibName glide3
#else
#define Glide3LibName
#endif
#endif
GLIDE3LIBNAME = Glide3LibName
#ifndef HasTk
#define HasTk NO
#endif
...
...
nx-X11/config/cf/X11.tmpl
View file @
5365f905
...
...
@@ -290,12 +290,6 @@ XORGRELSTRING = XorgManVersionString
#ifndef BuildOSMesaLib
#define BuildOSMesaLib BuildGlxExt
#endif
#ifndef BuildXF86RushExt
#define BuildXF86RushExt NO
#endif
#ifndef BuildXF86RushLibrary
#define BuildXF86RushLibrary (BuildXF86RushExt && !BuildServersOnly)
#endif
#ifndef BuildRender
#define BuildRender YES
#endif
...
...
@@ -1411,30 +1405,6 @@ ProjectUnsharedLibReferences(XONLY,NX_X11,$(XLIBSRC),XBuildLibDir)
#define ProfileLibXxf86dga NO
#endif
#if BuildXF86RushLibrary
#ifndef SharedLibXxf86rush
#define SharedLibXxf86rush HasSharedLibraries
#endif
#ifndef NormalLibXxf86rush
#define NormalLibXxf86rush (!SharedLibXxf86rush || ForceNormalLib)
#endif
#ifndef DebugLibXxf86rush
#define DebugLibXxf86rush NO
#endif
#ifndef ProfileLibXxf86rush
#define ProfileLibXxf86rush NO
#endif
#else
#undef SharedLibXxf86rush
#define SharedLibXxf86rush NO
#undef NormalLibXxf86rush
#define NormalLibXxf86rush NO
#undef DebugLibXxf86rush
#define DebugLibXxf86rush NO
#undef ProfileLibXxf86rush
#define ProfileLibXxf86rush NO
#endif
#if BuildXineramaLibrary
#ifndef SharedLibXinerama
#define SharedLibXinerama HasSharedLibraries
...
...
@@ -1587,16 +1557,6 @@ SharedLibReferences(XXF86DGA,NX_Xxf86dga,$(XXF86DGALIBSRC),SOXXF86DGAREV,SharedX
ProjectUnsharedLibReferences(XXF86DGA,NX_Xxf86dga,$(XXF86DGALIBSRC),XBuildLibDir)
#endif
XXF86RUSHLIBSRC = $(LIBSRC)/Xxf86rush
#if SharedLibXxf86rush
#ifndef SharedXxf86rushRev
#define SharedXxf86rushRev 1.0
#endif
SharedLibReferences(XXF86RUSH,NX_Xxf86rush,$(XXF86RUSHLIBSRC),SOXXF86RUSHREV,SharedXxf86rushRev)
#else
ProjectUnsharedLibReferences(XXF86RUSH,NX_Xxf86rush,$(XXF86RUSHLIBSRC),XBuildLibDir)
#endif
XINERAMALIBSRC = $(LIBSRC)/Xinerama
#if SharedLibXinerama
#ifndef SharedXineramaRev
...
...
nx-X11/config/cf/host.def
View file @
5365f905
...
...
@@ -185,34 +185,6 @@ XCOMM $XFree86: xc/config/cf/xf86site.def,v 3.186 2003/06/25 18:06:22 eich Exp $
#define UseSeparateConfDir NO
*/
/*
* To enable building the glide driver, you need to define
* HasGlide2 to YES and set the Glide2IncDir variable.
* HasGlide2 is per default NO.
*
#define HasGlide2 YES
*/
/*
* Set the path to your Glide include files.
*
#define Glide2IncDir /usr/include/glide
*/
/*
* Have glide 3?
*
#define HasGlide3 YES
*/
/*
* Set the path to your Glide 3 include files.
*
#define Glide3IncDir /usr/include/glide3
*/
/*
* Unless you're a developer you shouldn't need to change anything
* beyond this point.
...
...
@@ -440,22 +412,6 @@ XCOMM $XFree86: xc/config/cf/xf86site.def,v 3.186 2003/06/25 18:06:22 eich Exp $
#define GlxExtraDefines -D__GLX_ALIGN64
#endif
/*
* If you want to build the xf86rush extension, uncomment this line.
* This isn't recommended.
*
#define BuildXF86RushExt YES
*/
#define BuildXF86RushExt NO
/*
* If you want to build the client library for the xf86rush extension,
* uncomment this line. This isn't recommended.
*
#define BuildXF86RushLibrary NO
*/
#define BuildXF86RushLibrary NO
#define BuildXKB YES
#define BuildXKBlib YES
...
...
nx-X11/config/cf/linux.cf
View file @
5365f905
...
...
@@ -145,19 +145,6 @@ XCOMM binutils: (LinuxBinUtilsMajorVersion)
# endif
# define HasXdmAuth YES
# define HasLatex YES
/* at present, glide2 only works on i386 */
# if defined(__linux__) && defined(i386Architecture)
# define HasGlide2 YES
# define Glide2IncDir /usr/include/glide
# endif /* __linux__ && i386Architecture */
/* at present, glide3 only works on alpha, amd64, i386 and ia64 */
# if defined(__linux__) && (defined(i386Architecture) || \
defined(AlphaArchitecture) || defined(ia64Architecture) || \
defined(AMD64Architecture))
# define HasGlide3 YES
# define Glide3IncDir /usr/include/glide3
# endif /* __linux__ && (i386Architecture || AlphaArchitecture || \
ia64Architecture || AMD64Architecture) */
/* extended instruction set support */
# ifdef i386Architecture
# define HasX86Support YES
...
...
@@ -381,13 +368,6 @@ XCOMM binutils: (LinuxBinUtilsMajorVersion)
# endif
#endif
/*
* The Rush extension support.
*/
#ifndef BuildXF86RushExt
# define BuildXF86RushExt YES
#endif
#if defined(__linux__) && !defined(LinuxFBDevSupport)
# define LinuxFBDevSupport YES
#endif
...
...
nx-X11/config/cf/xorg.cf
View file @
5365f905
...
...
@@ -437,13 +437,6 @@ IPLAN2P8_DEFS = -DUSE_IPLAN2P8
# define XF86INT10_BUILD X86INT10_STUB
# endif
#endif
/*
* Build the Rush extension library (non standard extension for cooperation
* between glide library and X server). Enabled by default only for Linux.
*/
#ifndef BuildXF86RushExt
# define BuildXF86RushExt NO
#endif
#ifndef BuildRECORDlib
# define BuildRECORDlib YES
...
...
nx-X11/config/cf/xorgsite.def
View file @
5365f905
...
...
@@ -86,34 +86,6 @@ XCOMM $XFree86: xc/config/cf/xf86site.def,v 3.186 2003/06/25 18:06:22 eich Exp $
#define UseSeparateConfDir NO
*/
/*
* To enable building the glide driver, you need to define
* HasGlide2 to YES and set the Glide2IncDir variable.
* HasGlide2 is per default NO.
*
#define HasGlide2 YES
*/
/*
* Set the path to your Glide include files.
*
#define Glide2IncDir /usr/include/glide
*/
/*
* Have glide 3?
*
#define HasGlide3 YES
*/
/*
* Set the path to your Glide 3 include files.
*
#define Glide3IncDir /usr/include/glide3
*/
/*
* Unless you're a developer you shouldn't need to change anything
* beyond this point.
...
...
@@ -304,20 +276,6 @@ XCOMM $XFree86: xc/config/cf/xf86site.def,v 3.186 2003/06/25 18:06:22 eich Exp $
*/
/*
* If you want to build the xf86rush extension, uncomment this line.
* This isn't recommended.
*
#define BuildXF86RushExt YES
*/
/*
* If you want to build the client library for the xf86rush extension,
* uncomment this line. This isn't recommended.
*
#define BuildXF86RushLibrary NO
*/
/*
* If you are running NetBSD 0.9C or later, and have the aperture driver
* installed, uncomment this.
*
...
...
nx-X11/include/extensions/Imakefile
View file @
5365f905
...
...
@@ -32,9 +32,6 @@ LBXHEADERS = XLbx.h lbxbuf.h lbxbufstr.h lbxdeltastr.h lbximage.h lbxopts.h \
XVHEADERS = Xv.h Xvlib.h Xvproto.h
XVMCHEADERS = XvMC.h XvMClib.h XvMCproto.h vldXvMC.h
#endif
#if BuildXF86RushExt || BuildXF86RushLibrary
XF86RUSHHEADERS = xf86rush.h xf86rushstr.h
#endif
#if BuildFontCache
FONTCACHEHEADERS = fontcache.h fontcacheP.h fontcachstr.h
#endif
...
...
@@ -71,7 +68,6 @@ EXTRAHEADERS = \
$(LBXHEADERS) \
$(XVHEADERS) \
$(XVMCHEADERS) \
$(XF86RUSHHEADERS) \
$(FONTCACHEHEADERS) \
$(RENDERHEADERS) \
$(XFIXESHEADERS) \
...
...
@@ -119,8 +115,6 @@ InstallDriverSDKNonExecFile(dpms.h,$(DRIVERSDKINCLUDEDIR)/extensions)
InstallDriverSDKNonExecFile(xf86dga1str.h,$(DRIVERSDKINCLUDEDIR))
InstallDriverSDKNonExecFile(xf86dgastr.h,$(DRIVERSDKINCLUDEDIR)/extensions)
InstallDriverSDKNonExecFile(xf86misc.h,$(DRIVERSDKINCLUDEDIR)/extensions)
InstallDriverSDKNonExecFile(xf86rush.h,$(DRIVERSDKINCLUDEDIR))
InstallDriverSDKNonExecFile(xf86rushstr.h,$(DRIVERSDKINCLUDEDIR))
InstallDriverSDKNonExecFile(renderproto.h,$(DRIVERSDKINCLUDEDIR))
InstallDriverSDKNonExecFile(Xv.h,$(DRIVERSDKINCLUDEDIR)/extensions)
InstallDriverSDKNonExecFile(XvMC.h,$(DRIVERSDKINCLUDEDIR))
...
...
nx-X11/include/extensions/xf86rush.h
deleted
100644 → 0
View file @
fb2a4e4c
/* $XFree86: xc/include/extensions/xf86rush.h,v 1.4 2000/02/29 03:09:00 dawes Exp $ */
/*
Copyright (c) 1998 Daryll Strauss
*/
#ifndef _XF86RUSH_H_
#define _XF86RUSH_H_
#include <X11/extensions/Xv.h>
#include <X11/Xfuncproto.h>
#define X_XF86RushQueryVersion 0
#define X_XF86RushLockPixmap 1
#define X_XF86RushUnlockPixmap 2
#define X_XF86RushUnlockAllPixmaps 3
#define X_XF86RushGetCopyMode 4
#define X_XF86RushSetCopyMode 5
#define X_XF86RushGetPixelStride 6
#define X_XF86RushSetPixelStride 7
#define X_XF86RushOverlayPixmap 8
#define X_XF86RushStatusRegOffset 9
#define X_XF86RushAT3DEnableRegs 10
#define X_XF86RushAT3DDisableRegs 11
#define XF86RushNumberEvents 0
#define XF86RushClientNotLocal 0
#define XF86RushNumberErrors (XF86RushClientNotLocal + 1)
#ifndef _XF86RUSH_SERVER_
_XFUNCPROTOBEGIN
Bool
XF86RushQueryVersion
(
Display
*
/* dpy */
,
int
*
/* majorVersion */
,
int
*
/* minorVersion */
);
Bool
XF86RushQueryExtension
(
Display
*
/* dpy */
,
int
*
/* event_base */
,
int
*
/* error_base */
);
Bool
XF86RushLockPixmap
(
Display
*
/* dpy */
,
int
/* screen */
,
Pixmap
/* Pixmap */
,
void
**
/* Return address */
);
Bool
XF86RushUnlockPixmap
(
Display
*
/* dpy */
,
int
/* screen */
,
Pixmap
/* Pixmap */
);
Bool
XF86RushUnlockAllPixmaps
(
Display
*
/* dpy */
);
Bool
XF86RushSetCopyMode
(
Display
*
/* dpy */
,
int
/* screen */
,
int
/* copy mode */
);
Bool
XF86RushSetPixelStride
(
Display
*
/* dpy */
,
int
/* screen */
,
int
/* pixel stride */
);
Bool
XF86RushOverlayPixmap
(
Display
*
/* dpy */
,
XvPortID
/* port */
,
Drawable
/* d */
,
GC
/* gc */
,
Pixmap
/* pixmap */
,
int
/* src_x */
,
int
/* src_y */
,
unsigned
int
/* src_w */
,
unsigned
int
/* src_h */
,
int
/* dest_x */
,
int
/* dest_y */
,
unsigned
int
/* dest_w */
,
unsigned
int
/* dest_h */
,
unsigned
int
/* id */
);
int
XF86RushStatusRegOffset
(
Display
*
/* dpy */
,
int
/* screen */
);
Bool
XF86RushAT3DEnableRegs
(
Display
*
/* dpy */
,
int
/* screen */
);
Bool
XF86RushAT3DDisableRegs
(
Display
*
/* dpy */
,
int
/* screen */
);
_XFUNCPROTOEND
#endif
/* _XF86RUSH_SERVER_ */
#endif
/* _XF86RUSH_H_ */
nx-X11/include/extensions/xf86rushstr.h
deleted
100644 → 0
View file @
fb2a4e4c
/* $XFree86: xc/include/extensions/xf86rushstr.h,v 1.4 2000/02/29 03:09:02 dawes Exp $ */
/*
Copyright (c) 1998 Daryll Strauss
*/
#ifndef _XF86RUSHSTR_H_
#define _XF86RUSHSTR_H_
#include <X11/extensions/xf86rush.h>
#define XF86RUSHNAME "XFree86-Rush"
#define XF86RUSH_MAJOR_VERSION 1
/* current version numbers */
#define XF86RUSH_MINOR_VERSION 1
typedef
struct
_XF86RushQueryVersion
{
CARD8
reqType
;
/* always RushReqCode */
CARD8
rushReqType
;
/* always X_RushQueryVersion */
CARD16
length
B16
;
}
xXF86RushQueryVersionReq
;
#define sz_xXF86RushQueryVersionReq 4
typedef
struct
{
BYTE
type
;
/* X_Reply */
BOOL
pad1
;
CARD16
sequenceNumber
B16
;
CARD32
length
B32
;
CARD16
majorVersion
B16
;
/* major version of Rush protocol */
CARD16
minorVersion
B16
;
/* minor version of Rush protocol */
CARD32
pad2
B32
;
CARD32
pad3
B32
;
CARD32
pad4
B32
;
CARD32
pad5
B32
;
CARD32
pad6
B32
;
}
xXF86RushQueryVersionReply
;
#define sz_xXF86RushQueryVersionReply 32
typedef
struct
_XF86RushLockPixmap
{
CARD8
reqType
;
/* always RushReqCode */
CARD8
rushReqType
;
/* always X_RushLockPixmap */
CARD16
length
B16
;
CARD16
screen
B16
;
CARD16
pad
B16
;
CARD32
pixmap
B32
;
}
xXF86RushLockPixmapReq
;
#define sz_xXF86RushLockPixmapReq 12
typedef
struct
{
BYTE
type
;
BOOL
pad1
;
CARD16
sequenceNumber
B16
;
CARD32
length
B32
;
CARD32
addr
B32
;
CARD32
pad2
B32
;
CARD32
pad3
B32
;
CARD32
pad4
B32
;
CARD32
pad5
B32
;
CARD32
pad6
B32
;
}
xXF86RushLockPixmapReply
;
#define sz_xXF86RushLockPixmapReply 32
typedef
struct
_XF86RushUnlockPixmap
{
CARD8
reqType
;
/* always RushReqCode */
CARD8
rushReqType
;
/* always X_RushUnlockPixmap */
CARD16
length
B16
;
CARD16
screen
B16
;
CARD16
pad
B16
;
CARD32
pixmap
B32
;
}
xXF86RushUnlockPixmapReq
;
#define sz_xXF86RushUnlockPixmapReq 12
typedef
struct
_XF86RushUnlockAllPixmaps
{
CARD8
reqType
;
/* always RushReqCode */
CARD8
rushReqType
;
/* always X_RushUnlockAllPixmaps */
CARD16
length
B16
;
}
xXF86RushUnlockAllPixmapsReq
;
#define sz_xXF86RushUnlockAllPixmapsReq 4
typedef
struct
_XF86RushSetCopyMode
{
CARD8
reqType
;
/* always RushReqCode */
CARD8
rushReqType
;
/* always X_RushSetCopyMode */
CARD16
length
B16
;
CARD16
screen
B16
;
CARD16
pad
B16
;
CARD32
CopyMode
B32
;
}
xXF86RushSetCopyModeReq
;
#define sz_xXF86RushSetCopyModeReq 12
typedef
struct
_XF86RushSetPixelStride
{
CARD8
reqType
;
/* always RushReqCode */
CARD8
rushReqType
;
/* always X_RushSetCopyMode */
CARD16
length
B16
;
CARD16
screen
B16
;
CARD16
pad
B16
;
CARD32
PixelStride
B32
;
}
xXF86RushSetPixelStrideReq
;
#define sz_xXF86RushSetPixelStrideReq 12
typedef
struct
{
CARD8
reqType
;
/* always RushReqCode */
CARD8
rushReqType
;
/* always X_RushOverlayPixmap */
CARD16
length
B16
;
XvPortID
port
B32
;
Drawable
drawable
B32
;
GContext
gc
B32
;
Pixmap
pixmap
B32
;
CARD32
id
B32
;
INT16
src_x
B16
;
INT16
src_y
B16
;
CARD16
src_w
B16
;
CARD16
src_h
B16
;
INT16
drw_x
B16
;
INT16
drw_y
B16
;
CARD16
drw_w
B16
;
CARD16
drw_h
B16
;
}
xXF86RushOverlayPixmapReq
;
#define sz_xXF86RushOverlayPixmapReq 40
typedef
struct
_XF86RushStatusRegOffset
{
CARD8
reqType
;
/* always RushReqCode */
CARD8
rushReqType
;
/* always X_RushStatusRegOffset */
CARD16
length
B16
;
CARD16
screen
B16
;
CARD16
pad
B16
;
}
xXF86RushStatusRegOffsetReq
;
#define sz_xXF86RushStatusRegOffsetReq 8
typedef
struct
{
BYTE
type
;
/* X_Reply */
BOOL
pad1
;
CARD16
sequenceNumber
B16
;
CARD32
length
B32
;
CARD32
offset
B32
;
/* Offset of Rush status reg in mem */
CARD32
pad2
B32
;
CARD32
pad3
B32
;
CARD32
pad4
B32
;
CARD32
pad5
B32
;
CARD32
pad6
B32
;
}
xXF86RushStatusRegOffsetReply
;
#define sz_xXF86RushStatusRegOffsetReply 32
typedef
struct
_XF86RushAT3DEnableRegs
{
CARD8
reqType
;
/* always RushReqCode */
CARD8
rushReqType
;
/* always X_RushAT3DEnableRegs */
CARD16
length
B16
;
CARD16
screen
B16
;
CARD16
pad
B16
;
}
xXF86RushAT3DEnableRegsReq
;
#define sz_xXF86RushAT3DEnableRegsReq 8
typedef
struct
_XF86RushAT3DDisableRegs
{
CARD8
reqType
;
/* always RushReqCode */
CARD8
rushReqType
;
/* always X_RushAT3DDisableRegs */
CARD16
length
B16
;
CARD16
screen
B16
;
CARD16
pad
B16
;
}
xXF86RushAT3DDisableRegsReq
;
#define sz_xXF86RushAT3DDisableRegsReq 8
#endif
/* _XF86RUSHSTR_H_ */
nx-X11/lib/Imakefile
View file @
5365f905
...
...
@@ -27,10 +27,6 @@ XF86VMLIBDIR = Xxf86vm
XF86DGALIBDIR = Xxf86dga
#endif
#if BuildXF86RushLibrary
XF86RUSHLIBDIR = Xxf86rush
#endif
#if BuildXineramaLibrary
XINERAMADIR=Xinerama
#endif
...
...
@@ -51,7 +47,6 @@ XF86EXTLIBS = \
$(XF86MISCLIBDIR) \
$(XF86VMLIBDIR) \
$(XF86DGALIBDIR) \
$(XF86RUSHLIBDIR) \
$(NULL)
#if BuildXauLib
...
...
@@ -80,7 +75,6 @@ LINTSUBDIRS = \
$(XF86MISCLIBDIR) \
$(XF86VMLIBDIR) \
$(XF86DGALIBDIR) \
$(XF86RUSHLIBDIR) \
$(XTSTLIBDIR) \
$(XKBLIBDIR) \
$(XINERAMADIR) \
...
...
nx-X11/lib/Xxf86rush/Imakefile
deleted
100644 → 0
View file @
fb2a4e4c
XCOMM $XFree86: xc/lib/Xxf86rush/Imakefile,v 1.1 1999/09/04 09:14:09 dawes Exp $
#define DoNormalLib NormalLibXxf86rush
#define DoSharedLib SharedLibXxf86rush
#define DoDebugLib DebugLibXxf86rush
#define DoProfileLib ProfileLibXxf86rush
#define LibName Xxf86rush
#define SoRev SOXXF86RUSHREV
#define LibHeaders NO
#include <Threads.tmpl>
#ifdef SharedXxf86rushReqs
REQUIREDLIBS = SharedXxf86rushReqs
#endif
XF86RUSHSRCS = XF86Rush.c
XF86RUSHOBJS = XF86Rush.o
#if Malloc0ReturnsNull
ALLOC_DEFINES = -DMALLOC_0_RETURNS_NULL
#endif
DEFINES = $(ALLOC_DEFINES)
SRCS = $(XF86RUSHSRCS)
OBJS = $(XF86RUSHOBJS)
LINTLIBS = $(LINTXLIB)
#include <Library.tmpl>
DependTarget()
nx-X11/lib/Xxf86rush/XF86Rush.c
deleted
100644 → 0
View file @
fb2a4e4c
/* $XFree86: xc/lib/Xxf86rush/XF86Rush.c,v 1.5 2000/09/26 15:56:59 tsi Exp $ */
/*
Copyright (c) 1998 Daryll Strauss
*/
/* THIS IS NOT AN X CONSORTIUM STANDARD */
#define NEED_EVENTS
#define NEED_REPLIES
#include <X11/Xlibint.h>
#include <X11/extensions/xf86rushstr.h>
#include <X11/extensions/Xext.h>
#include <X11/extensions/extutil.h>
static
XExtensionInfo
_xf86rush_info_data
;
static
XExtensionInfo
*
xf86rush_info
=
&
_xf86rush_info_data
;
static
char
*
xf86rush_extension_name
=
XF86RUSHNAME
;
#define XF86RushCheckExtension(dpy,i,val) \
XextCheckExtension (dpy, i, xf86rush_extension_name, val)
/*****************************************************************************
* *
* private utility routines *
* *
*****************************************************************************/
static
int
close_display
();
static
/* const */
XExtensionHooks
xf86rush_extension_hooks
=
{
NULL
,
/* create_gc */
NULL
,
/* copy_gc */
NULL
,
/* flush_gc */
NULL
,
/* free_gc */
NULL
,
/* create_font */
NULL
,
/* free_font */
close_display
,
/* close_display */
NULL
,
/* wire_to_event */
NULL
,
/* event_to_wire */
NULL
,
/* error */
NULL
,
/* error_string */
};
static
XEXT_GENERATE_FIND_DISPLAY
(
find_display
,
xf86rush_info
,
xf86rush_extension_name
,
&
xf86rush_extension_hooks
,
0
,
NULL
)
static
XEXT_GENERATE_CLOSE_DISPLAY
(
close_display
,
xf86rush_info
)
/*****************************************************************************
* *
* public XFree86-DGA Extension routines *
* *
*****************************************************************************/
Bool
XF86RushQueryExtension
(
Display
*
dpy
,
int
*
event_basep
,
int
*
error_basep
)
{
XExtDisplayInfo
*
info
=
find_display
(
dpy
);
if
(
XextHasExtension
(
info
))
{
*
event_basep
=
info
->
codes
->
first_event
;
*
error_basep
=
info
->
codes
->
first_error
;
return
True
;
}
else
{
return
False
;
}
}
Bool
XF86RushQueryVersion
(
Display
*
dpy
,
int
*
majorVersion
,
int
*
minorVersion
)
{
XExtDisplayInfo
*
info
=
find_display
(
dpy
);
xXF86RushQueryVersionReply
rep
;
xXF86RushQueryVersionReq
*
req
;
XF86RushCheckExtension
(
dpy
,
info
,
False
);
LockDisplay
(
dpy
);
GetReq
(
XF86RushQueryVersion
,
req
);
req
->
reqType
=
info
->
codes
->
major_opcode
;
req
->
rushReqType
=
X_XF86RushQueryVersion
;
if
(
!
_XReply
(
dpy
,
(
xReply
*
)
&
rep
,
0
,
xFalse
))
{
UnlockDisplay
(
dpy
);
SyncHandle
();
return
False
;
}
*
majorVersion
=
rep
.
majorVersion
;
*
minorVersion
=
rep
.
minorVersion
;
UnlockDisplay
(
dpy
);
SyncHandle
();
return
True
;
}
Bool
XF86RushLockPixmap
(
Display
*
dpy
,
int
screen
,
Pixmap
pixmap
,
void
**
addr
)
{
XExtDisplayInfo
*
info
=
find_display
(
dpy
);
xXF86RushLockPixmapReply
rep
;
xXF86RushLockPixmapReq
*
req
;
XF86RushCheckExtension
(
dpy
,
info
,
False
);
LockDisplay
(
dpy
);
GetReq
(
XF86RushLockPixmap
,
req
);
req
->
reqType
=
info
->
codes
->
major_opcode
;
req
->
rushReqType
=
X_XF86RushLockPixmap
;
req
->
screen
=
screen
;
req
->
pixmap
=
pixmap
;
if
(
!
_XReply
(
dpy
,
(
xReply
*
)
&
rep
,
0
,
xFalse
))
{
UnlockDisplay
(
dpy
);
SyncHandle
();
return
False
;
}
if
(
addr
)
*
addr
=
(
void
*
)(
long
)
rep
.
addr
;
UnlockDisplay
(
dpy
);
SyncHandle
();
return
True
;
}
Bool
XF86RushUnlockPixmap
(
Display
*
dpy
,
int
screen
,
Pixmap
pixmap
)
{
XExtDisplayInfo
*
info
=
find_display
(
dpy
);
xXF86RushUnlockPixmapReq
*
req
;
XF86RushCheckExtension
(
dpy
,
info
,
False
);
LockDisplay
(
dpy
);
GetReq
(
XF86RushUnlockPixmap
,
req
);
req
->
reqType
=
info
->
codes
->
major_opcode
;
req
->
rushReqType
=
X_XF86RushUnlockPixmap
;
req
->
screen
=
screen
;
req
->
pixmap
=
pixmap
;
UnlockDisplay
(
dpy
);
SyncHandle
();
return
True
;
}
Bool
XF86RushUnlockAllPixmaps
(
Display
*
dpy
)
{
XExtDisplayInfo
*
info
=
find_display
(
dpy
);
xXF86RushUnlockAllPixmapsReq
*
req
;
XF86RushCheckExtension
(
dpy
,
info
,
False
);
LockDisplay
(
dpy
);
GetReq
(
XF86RushUnlockAllPixmaps
,
req
);
req
->
reqType
=
info
->
codes
->
major_opcode
;
req
->
rushReqType
=
X_XF86RushUnlockAllPixmaps
;
UnlockDisplay
(
dpy
);
SyncHandle
();
return
True
;
}
Bool
XF86RushSetCopyMode
(
Display
*
dpy
,
int
screen
,
int
mode
)
{
XExtDisplayInfo
*
info
=
find_display
(
dpy
);
xXF86RushSetCopyModeReq
*
req
;
XF86RushCheckExtension
(
dpy
,
info
,
False
);
LockDisplay
(
dpy
);
GetReq
(
XF86RushSetCopyMode
,
req
);
req
->
reqType
=
info
->
codes
->
major_opcode
;
req
->
rushReqType
=
X_XF86RushSetCopyMode
;
req
->
screen
=
screen
;
req
->
CopyMode
=
mode
;
UnlockDisplay
(
dpy
);
SyncHandle
();
return
True
;
}
Bool
XF86RushSetPixelStride
(
Display
*
dpy
,
int
screen
,
int
stride
)
{
XExtDisplayInfo
*
info
=
find_display
(
dpy
);
xXF86RushSetPixelStrideReq
*
req
;
XF86RushCheckExtension
(
dpy
,
info
,
False
);
LockDisplay
(
dpy
);
GetReq
(
XF86RushSetPixelStride
,
req
);
req
->
reqType
=
info
->
codes
->
major_opcode
;
req
->
rushReqType
=
X_XF86RushSetPixelStride
;
req
->
screen
=
screen
;
req
->
PixelStride
=
stride
;
UnlockDisplay
(
dpy
);
SyncHandle
();
return
True
;
}
int
XF86RushOverlayPixmap
(
Display
*
dpy
,
XvPortID
port
,
Drawable
d
,
GC
gc
,
Pixmap
pixmap
,
int
src_x
,
int
src_y
,
unsigned
int
src_w
,
unsigned
int
src_h
,
int
dest_x
,
int
dest_y
,
unsigned
int
dest_w
,
unsigned
int
dest_h
,
unsigned
int
id
)
{
XExtDisplayInfo
*
info
=
find_display
(
dpy
);
xXF86RushOverlayPixmapReq
*
req
;
XF86RushCheckExtension
(
dpy
,
info
,
False
);
FlushGC
(
dpy
,
gc
);
LockDisplay
(
dpy
);
GetReq
(
XF86RushOverlayPixmap
,
req
);
req
->
reqType
=
info
->
codes
->
major_opcode
;
req
->
rushReqType
=
X_XF86RushOverlayPixmap
;
req
->
port
=
port
;
req
->
drawable
=
d
;
req
->
gc
=
gc
->
gid
;
req
->
id
=
id
;
req
->
pixmap
=
pixmap
;
req
->
src_x
=
src_x
;
req
->
src_y
=
src_y
;
req
->
src_w
=
src_w
;
req
->
src_h
=
src_h
;
req
->
drw_x
=
dest_x
;
req
->
drw_y
=
dest_y
;
req
->
drw_w
=
dest_w
;
req
->
drw_h
=
dest_h
;
UnlockDisplay
(
dpy
);
SyncHandle
();
return
Success
;
}
int
XF86RushStatusRegOffset
(
Display
*
dpy
,
int
screen
)
{
XExtDisplayInfo
*
info
=
find_display
(
dpy
);
xXF86RushStatusRegOffsetReq
*
req
;
xXF86RushStatusRegOffsetReply
rep
;
XF86RushCheckExtension
(
dpy
,
info
,
False
);
LockDisplay
(
dpy
);
GetReq
(
XF86RushStatusRegOffset
,
req
);
req
->
reqType
=
info
->
codes
->
major_opcode
;
req
->
rushReqType
=
X_XF86RushStatusRegOffset
;
req
->
screen
=
screen
;
if
(
!
_XReply
(
dpy
,
(
xReply
*
)
&
rep
,
0
,
xFalse
))
{
UnlockDisplay
(
dpy
);
SyncHandle
();
return
False
;
}
UnlockDisplay
(
dpy
);
SyncHandle
();
return
rep
.
offset
;
}
Bool
XF86RushAT3DEnableRegs
(
Display
*
dpy
,
int
screen
)
{
XExtDisplayInfo
*
info
=
find_display
(
dpy
);
xXF86RushAT3DEnableRegsReq
*
req
;
XF86RushCheckExtension
(
dpy
,
info
,
False
);
LockDisplay
(
dpy
);
GetReq
(
XF86RushAT3DEnableRegs
,
req
);
req
->
reqType
=
info
->
codes
->
major_opcode
;
req
->
rushReqType
=
X_XF86RushAT3DEnableRegs
;
req
->
screen
=
screen
;
UnlockDisplay
(
dpy
);
SyncHandle
();
/*
* The request has to be processed to stay in sync...
*/
XSync
(
dpy
,
False
);
return
Success
;
}
Bool
XF86RushAT3DDisableRegs
(
Display
*
dpy
,
int
screen
)
{
XExtDisplayInfo
*
info
=
find_display
(
dpy
);
xXF86RushAT3DDisableRegsReq
*
req
;
XF86RushCheckExtension
(
dpy
,
info
,
False
);
LockDisplay
(
dpy
);
GetReq
(
XF86RushAT3DDisableRegs
,
req
);
req
->
reqType
=
info
->
codes
->
major_opcode
;
req
->
rushReqType
=
X_XF86RushAT3DDisableRegs
;
req
->
screen
=
screen
;
UnlockDisplay
(
dpy
);
SyncHandle
();
return
Success
;
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment