mirror of
https://gitlab.freedesktop.org/xorg/proto/xorgproto.git
synced 2026-05-08 17:08:01 +02:00
Remove most LBX headers.
XLbx.h and lbxstr.h are required for libXext to build, and we're not allowed to remove API from that.
This commit is contained in:
parent
7629def073
commit
57d09e47d0
7 changed files with 0 additions and 555 deletions
|
|
@ -6,13 +6,7 @@ xext_HEADERS = \
|
|||
ge.h \
|
||||
geproto.h \
|
||||
Xge.h \
|
||||
lbxbuf.h \
|
||||
lbxbufstr.h \
|
||||
lbxdeltastr.h \
|
||||
lbximage.h \
|
||||
lbxopts.h \
|
||||
lbxstr.h \
|
||||
lbxzlib.h \
|
||||
MITMisc.h \
|
||||
mitmiscstr.h \
|
||||
multibuf.h \
|
||||
|
|
|
|||
51
lbxbuf.h
51
lbxbuf.h
|
|
@ -1,51 +0,0 @@
|
|||
/* $Xorg: lbxbuf.h,v 1.3 2000/08/18 04:05:45 coskrey Exp $ */
|
||||
/*
|
||||
* Copyright 1988, 1989, 1990, 1994 Network Computing Devices, Inc.
|
||||
*
|
||||
* Permission to use, copy, modify, distribute, and sell this software and
|
||||
* its documentation for any purpose is hereby granted without fee, provided
|
||||
* that the above copyright notice appear in all copies and that both that
|
||||
* copyright notice and this permission notice appear in supporting
|
||||
* documentation, and that the name Network Computing Devices, Inc. not be
|
||||
* used in advertising or publicity pertaining to distribution of this
|
||||
* software without specific, written prior permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED `AS-IS'. NETWORK COMPUTING DEVICES, INC.,
|
||||
* DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING WITHOUT
|
||||
* LIMITATION ALL IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
|
||||
* PARTICULAR PURPOSE, OR NONINFRINGEMENT. IN NO EVENT SHALL NETWORK
|
||||
* COMPUTING DEVICES, INC., BE LIABLE FOR ANY DAMAGES WHATSOEVER, INCLUDING
|
||||
* SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES, INCLUDING LOSS OF USE,
|
||||
* DATA, OR PROFITS, EVEN IF ADVISED OF THE POSSIBILITY THEREOF, AND
|
||||
* REGARDLESS OF WHETHER IN AN ACTION IN CONTRACT, TORT OR NEGLIGENCE,
|
||||
* ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
|
||||
* SOFTWARE.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef _BUFFER_H_
|
||||
#define _BUFFER_H_
|
||||
|
||||
#define INBUFFER_SIZE (1 << 13) /* 8K */
|
||||
#define OUTBUFFER_SIZE (1 << 12) /* 4K */
|
||||
|
||||
#ifndef TRUE
|
||||
#define TRUE 1
|
||||
#endif
|
||||
#ifndef FALSE
|
||||
#define FALSE 0
|
||||
#endif
|
||||
|
||||
typedef struct _zlibbuffer *ZlibBufferPtr;
|
||||
|
||||
#include <X11/Xfuncproto.h>
|
||||
|
||||
_XFUNCPROTOBEGIN
|
||||
|
||||
extern int InitZlibBuffer(ZlibBufferPtr b, int size);
|
||||
extern void FreeZlibBuffer(ZlibBufferPtr b);
|
||||
extern char *ReserveOutBuf(ZlibBufferPtr outbuf, int outlen);
|
||||
|
||||
_XFUNCPROTOEND
|
||||
|
||||
#endif /* _BUFFER_H_ */
|
||||
45
lbxbufstr.h
45
lbxbufstr.h
|
|
@ -1,45 +0,0 @@
|
|||
/* $Xorg: lbxbufstr.h,v 1.3 2000/08/18 04:05:45 coskrey Exp $ */
|
||||
/*
|
||||
* Copyright 1988, 1989, 1990, 1994 Network Computing Devices, Inc.
|
||||
*
|
||||
* Permission to use, copy, modify, distribute, and sell this software and
|
||||
* its documentation for any purpose is hereby granted without fee, provided
|
||||
* that the above copyright notice appear in all copies and that both that
|
||||
* copyright notice and this permission notice appear in supporting
|
||||
* documentation, and that the name Network Computing Devices, Inc. not be
|
||||
* used in advertising or publicity pertaining to distribution of this
|
||||
* software without specific, written prior permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED `AS-IS'. NETWORK COMPUTING DEVICES, INC.,
|
||||
* DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING WITHOUT
|
||||
* LIMITATION ALL IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
|
||||
* PARTICULAR PURPOSE, OR NONINFRINGEMENT. IN NO EVENT SHALL NETWORK
|
||||
* COMPUTING DEVICES, INC., BE LIABLE FOR ANY DAMAGES WHATSOEVER, INCLUDING
|
||||
* SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES, INCLUDING LOSS OF USE,
|
||||
* DATA, OR PROFITS, EVEN IF ADVISED OF THE POSSIBILITY THEREOF, AND
|
||||
* REGARDLESS OF WHETHER IN AN ACTION IN CONTRACT, TORT OR NEGLIGENCE,
|
||||
* ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
|
||||
* SOFTWARE.
|
||||
*
|
||||
*/
|
||||
/* $XFree86$ */
|
||||
|
||||
#ifndef _BUFFERSTR_H_
|
||||
#define _BUFFERSTR_H_
|
||||
|
||||
#include <X11/extensions/lbxbuf.h>
|
||||
|
||||
/*
|
||||
* ZLIB Input/Output buffer
|
||||
*/
|
||||
typedef struct _zlibbuffer {
|
||||
char *bufbase;
|
||||
char *bufend;
|
||||
char *bufptr;
|
||||
int bufcnt;
|
||||
} ZlibBuffer;
|
||||
|
||||
#define BYTES_AVAIL(inbuf, len) \
|
||||
(((inbuf)->bufcnt >= (len)) ? (inbuf)->bufptr : NULL)
|
||||
|
||||
#endif /* _BUFFERSTR_H_ */
|
||||
105
lbxdeltastr.h
105
lbxdeltastr.h
|
|
@ -1,105 +0,0 @@
|
|||
/* $Xorg: lbxdeltastr.h,v 1.3 2000/08/18 04:05:45 coskrey Exp $ */
|
||||
/*
|
||||
* Copyright 1993 Network Computing Devices
|
||||
*
|
||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||
* documentation for any purpose is hereby granted without fee, provided that
|
||||
* the above copyright notice appear in all copies and that both that
|
||||
* copyright notice and this permission notice appear in supporting
|
||||
* documentation, and that the name of NCD. not be used in advertising or
|
||||
* publicity pertaining to distribution of the software without specific,
|
||||
* written prior permission. NCD. makes no representations about the
|
||||
* suitability of this software for any purpose. It is provided "as is"
|
||||
* without express or implied warranty.
|
||||
*
|
||||
* NCD. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL NCD.
|
||||
* BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
|
||||
* OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
|
||||
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef LBX_DELTA_STRUCT_H
|
||||
#define LBX_DELTA_STRUCT_H
|
||||
|
||||
#define MIN_CACHEABLE_LEN 8
|
||||
|
||||
#define DELTA_CACHEABLE(pcache, len) \
|
||||
((len) > MIN_CACHEABLE_LEN && (len) <= (pcache)->maxDeltasize)
|
||||
|
||||
/*
|
||||
* An entry in the delta compactor cache
|
||||
*/
|
||||
typedef struct _LBXDeltaElem {
|
||||
int length;
|
||||
unsigned char *buf;
|
||||
} LBXDeltaElemRec, *LBXDeltaElemPtr;
|
||||
|
||||
|
||||
/*
|
||||
* Delta compactor cache
|
||||
*/
|
||||
typedef struct _LBXDeltas {
|
||||
unsigned short nDeltas;
|
||||
unsigned short maxDeltasize;
|
||||
LBXDeltaElemPtr deltas;
|
||||
unsigned short nextDelta;
|
||||
unsigned short activeDeltas; /* only needed for outgoing */
|
||||
} LBXDeltasRec, *LBXDeltasPtr;
|
||||
|
||||
|
||||
/*
|
||||
* Motion delta cache
|
||||
*/
|
||||
|
||||
typedef struct {
|
||||
BYTE swapped;
|
||||
BYTE detail;
|
||||
CARD16 sequenceNumber B16;
|
||||
Time time B32;
|
||||
Window root B32, event B32, child B32;
|
||||
INT16 rootX B16, rootY B16, eventX B16, eventY B16;
|
||||
KeyButMask state B16;
|
||||
BOOL sameScreen;
|
||||
} lbxMotionCache;
|
||||
|
||||
|
||||
/*
|
||||
* Motion delta events
|
||||
*/
|
||||
|
||||
typedef struct {
|
||||
BYTE type; /* always eventBase + LbxQuickMotionDeltaEvent */
|
||||
CARD8 deltaTime;
|
||||
INT8 deltaX;
|
||||
INT8 deltaY;
|
||||
} lbxQuickMotionDeltaEvent;
|
||||
#define sz_lbxQuickMotionDeltaEvent 4
|
||||
|
||||
typedef struct {
|
||||
BYTE type; /* always eventBase + LbxEvent */
|
||||
BYTE lbxType; /* LbxMotionDeltaEvent */
|
||||
INT8 deltaX;
|
||||
INT8 deltaY;
|
||||
CARD16 deltaTime B16;
|
||||
CARD16 deltaSequence B16;
|
||||
} lbxMotionDeltaEvent;
|
||||
#define sz_lbxMotionDeltaEvent 8
|
||||
|
||||
extern int LBXInitDeltaCache ( LBXDeltasPtr pcache, int nDeltas,
|
||||
int maxDeltasize );
|
||||
extern void LBXFreeDeltaCache ( LBXDeltasPtr pcache );
|
||||
extern int LBXDeltaMinDiffs ( LBXDeltasPtr pcache, unsigned char *inmsg,
|
||||
int inmsglen, int maxdiff, int *pindex );
|
||||
extern void LBXEncodeDelta ( LBXDeltasPtr pcache, unsigned char *inmsg,
|
||||
int ndiff, int index, unsigned char *buf );
|
||||
extern int LBXDecodeDelta ( LBXDeltasPtr pcache, xLbxDiffItem *deltas,
|
||||
int ndiff, int index, unsigned char **buf );
|
||||
extern void LBXAddDeltaOut ( LBXDeltasPtr pcache, unsigned char *inmsg,
|
||||
int inmsglen );
|
||||
extern void LBXAddDeltaIn ( LBXDeltasPtr pcache, unsigned char *inmsg,
|
||||
int inmsglen );
|
||||
|
||||
#endif /* LBX_DELTA_STRUCT_H */
|
||||
151
lbximage.h
151
lbximage.h
|
|
@ -1,151 +0,0 @@
|
|||
/* $Xorg: lbximage.h,v 1.4 2001/02/09 02:03:24 xorgcvs Exp $ */
|
||||
|
||||
/******************************************************************************
|
||||
|
||||
Copyright 1994, 1998 The Open Group
|
||||
|
||||
Permission to use, copy, modify, distribute, and sell this software and its
|
||||
documentation for any purpose is hereby granted without fee, provided that
|
||||
the above copyright notice appear in all copies and that both that
|
||||
copyright notice and this permission notice appear in supporting
|
||||
documentation.
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
|
||||
AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
Except as contained in this notice, the name of The Open Group shall not be
|
||||
used in advertising or otherwise to promote the sale, use or other dealings
|
||||
in this Software without prior written authorization from The Open Group.
|
||||
|
||||
******************************************************************************/
|
||||
/* $XFree86: xc/include/extensions/lbximage.h,v 1.4 2001/12/20 19:28:54 tsi Exp $ */
|
||||
|
||||
#ifndef _LBX_IMAGE_H_
|
||||
#define _LBX_IMAGE_H_
|
||||
|
||||
#include <X11/Xfuncproto.h>
|
||||
|
||||
_XFUNCPROTOBEGIN
|
||||
|
||||
typedef struct _LbxBitmapCompMethod {
|
||||
|
||||
char *methodName;
|
||||
int inited;
|
||||
int methodOpCode; /* to be filled on reply from server */
|
||||
|
||||
int (*compInit)(
|
||||
void
|
||||
);
|
||||
|
||||
int (*compFunc)(
|
||||
unsigned char * /* inbuf */,
|
||||
unsigned char * /* outbuf */,
|
||||
int /* outbufSize */,
|
||||
int /* image_bytes */,
|
||||
int /* pixels_per_line */,
|
||||
int /* padded_bytes_per_scanline */,
|
||||
int /* reverse_bits */,
|
||||
int * /* bytesCompressed */
|
||||
);
|
||||
|
||||
int (*decompFunc)(
|
||||
unsigned char * /* inbuf */,
|
||||
unsigned char * /* outbuf */,
|
||||
int /* image_bytes */,
|
||||
int /* pixels_per_line */,
|
||||
int /* padded_bytes_per_scanline */,
|
||||
int /* reverse_bits */
|
||||
);
|
||||
|
||||
} LbxBitmapCompMethod;
|
||||
|
||||
|
||||
#define LBX_MAX_DEPTHS 5
|
||||
|
||||
typedef struct _LbxPixmapCompMethod {
|
||||
|
||||
char *methodName;
|
||||
unsigned formatMask;
|
||||
int depthCount;
|
||||
int depths[LBX_MAX_DEPTHS];
|
||||
int inited;
|
||||
int methodOpCode; /* to be filled on reply from server */
|
||||
|
||||
int (*compInit)(
|
||||
void
|
||||
);
|
||||
|
||||
int (*compFunc)(
|
||||
char * /* inbuf */,
|
||||
char * /* outbuf */,
|
||||
int /* outbufSize */,
|
||||
int /* format */,
|
||||
int /* depth */,
|
||||
int /* num_scan_lines */,
|
||||
int /* scan_line_size */,
|
||||
int * /* bytesCompressed */
|
||||
);
|
||||
|
||||
int (*decompFunc)(
|
||||
char * /* inbuf */,
|
||||
char * /* outbuf */,
|
||||
int /* num_scan_lines */,
|
||||
int /* scan_line_size */
|
||||
);
|
||||
|
||||
} LbxPixmapCompMethod;
|
||||
|
||||
|
||||
extern int LbxImageEncodePackBits (
|
||||
char * /* inbuf */,
|
||||
char * /* outbuf */,
|
||||
int /* outbufSize */,
|
||||
int /* format */,
|
||||
int /* depth */,
|
||||
int /* num_scan_lines */,
|
||||
int /* scan_line_size */,
|
||||
int * /* bytesCompressed */
|
||||
);
|
||||
|
||||
extern int LbxImageEncodeFaxG42D (
|
||||
unsigned char * /* inbuf */,
|
||||
unsigned char * /* outbuf */,
|
||||
int /* outbufSize */,
|
||||
int /* image_bytes */,
|
||||
int /* pixels_per_line */,
|
||||
int /* padded_bytes_per_scanline */,
|
||||
int /* reverse_bits */,
|
||||
int * /* bytesCompressed */
|
||||
);
|
||||
|
||||
extern int LbxImageDecodePackBits (
|
||||
char * /* inbuf */,
|
||||
char * /* outbuf */,
|
||||
int /* num_scan_lines */,
|
||||
int /* scan_line_size */
|
||||
);
|
||||
|
||||
extern int LbxImageDecodeFaxG42D (
|
||||
unsigned char * /* inbuf */,
|
||||
unsigned char * /* outbuf */,
|
||||
int /* image_bytes */,
|
||||
int /* pixels_per_line */,
|
||||
int /* padded_bytes_per_scanline */,
|
||||
int /* reverse_bits */
|
||||
);
|
||||
|
||||
_XFUNCPROTOEND
|
||||
|
||||
#define LBX_IMAGE_COMPRESS_SUCCESS 0
|
||||
#define LBX_IMAGE_COMPRESS_NO_SUPPORT 1
|
||||
#define LBX_IMAGE_COMPRESS_BAD_MALLOC 2
|
||||
#define LBX_IMAGE_COMPRESS_NOT_WORTH_IT 3
|
||||
|
||||
#endif /* _LBX_IMAGE_H_ */
|
||||
133
lbxopts.h
133
lbxopts.h
|
|
@ -1,133 +0,0 @@
|
|||
/* $Xorg: lbxopts.h,v 1.3 2000/08/18 04:05:45 coskrey Exp $ */
|
||||
/*
|
||||
* Copyright 1994 Network Computing Devices, Inc.
|
||||
*
|
||||
* Permission to use, copy, modify, distribute, and sell this software and
|
||||
* its documentation for any purpose is hereby granted without fee, provided
|
||||
* that the above copyright notice appear in all copies and that both that
|
||||
* copyright notice and this permission notice appear in supporting
|
||||
* documentation, and that the name Network Computing Devices, Inc. not be
|
||||
* used in advertising or publicity pertaining to distribution of this
|
||||
* software without specific, written prior permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED `AS-IS'. NETWORK COMPUTING DEVICES, INC.,
|
||||
* DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING WITHOUT
|
||||
* LIMITATION ALL IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
|
||||
* PARTICULAR PURPOSE, OR NONINFRINGEMENT. IN NO EVENT SHALL NETWORK
|
||||
* COMPUTING DEVICES, INC., BE LIABLE FOR ANY DAMAGES WHATSOEVER, INCLUDING
|
||||
* SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES, INCLUDING LOSS OF USE, DATA,
|
||||
* OR PROFITS, EVEN IF ADVISED OF THE POSSIBILITY THEREOF, AND REGARDLESS OF
|
||||
* WHETHER IN AN ACTION IN CONTRACT, TORT OR NEGLIGENCE, ARISING OUT OF OR IN
|
||||
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*
|
||||
*/
|
||||
/* $XFree86: xc/include/extensions/lbxopts.h,v 1.5 2001/01/17 17:53:21 dawes Exp $ */
|
||||
|
||||
#ifndef _LBX_OPTS_H_
|
||||
#define _LBX_OPTS_H_
|
||||
|
||||
/*
|
||||
* Negotiable configuration options
|
||||
*/
|
||||
#define LBX_OPT_DELTA_PROXY 0
|
||||
#define LBX_OPT_DELTA_SERVER 1
|
||||
#define LBX_OPT_STREAM_COMP 2
|
||||
#define LBX_OPT_BITMAP_COMP 3
|
||||
#define LBX_OPT_PIXMAP_COMP 4
|
||||
#define LBX_OPT_MSG_COMP 5 /* aka "squishing" */
|
||||
#define LBX_OPT_USE_TAGS 6
|
||||
#define LBX_OPT_CMAP_ALL 7
|
||||
#define LBX_OPT_EXTENSION 255
|
||||
|
||||
/*
|
||||
* Length fields are encoded in 1 or 3 bytes
|
||||
*/
|
||||
#define LBX_OPT_SMALLLEN_SIZE 1
|
||||
#define LBX_OPT_BIGLEN_SIZE 3
|
||||
#define LBX_OPT_BIGLEN_MIN 256
|
||||
|
||||
#define LBX_OPT_DECODE_LEN(p, len, size) \
|
||||
if ((p)[0]) { \
|
||||
(len) = (p)[0]; \
|
||||
(size) = LBX_OPT_SMALLLEN_SIZE; \
|
||||
} \
|
||||
else { \
|
||||
(len) = ((LBX_OPT_BIGLEN_MIN + (p)[1]) << 8) | (p)[2]; \
|
||||
(size) = LBX_OPT_BIGLEN_SIZE; \
|
||||
}
|
||||
|
||||
/*
|
||||
* Option header lengths
|
||||
*/
|
||||
#define LBX_OPT_SMALLHDR_LEN (1 + LBX_OPT_SMALLLEN_SIZE)
|
||||
#define LBX_OPT_BIGHDR_LEN (1 + LBX_OPT_BIGLEN_SIZE)
|
||||
|
||||
/*
|
||||
* Delta compression parameters
|
||||
*/
|
||||
#define LBX_OPT_DELTA_REQLEN 6
|
||||
#define LBX_OPT_DELTA_REPLYLEN 2
|
||||
#define LBX_OPT_DELTA_NCACHE_DFLT 16
|
||||
#define LBX_OPT_DELTA_MSGLEN_MIN 32
|
||||
#define LBX_OPT_DELTA_MSGLEN_DFLT 64
|
||||
|
||||
|
||||
/*
|
||||
* Stream compression opts
|
||||
*/
|
||||
|
||||
#include <sys/types.h>
|
||||
|
||||
#if defined(WIN32) || (defined(USG) && !defined(CRAY) && !defined(umips) && !defined(MOTOROLA) && !defined(uniosu) && !defined(__sxg__))
|
||||
|
||||
struct iovec {
|
||||
caddr_t iov_base;
|
||||
int iov_len;
|
||||
};
|
||||
|
||||
#else
|
||||
#ifndef Lynx
|
||||
#include <sys/uio.h>
|
||||
#else
|
||||
#include <uio.h>
|
||||
#endif
|
||||
#endif
|
||||
|
||||
typedef void *LbxStreamCompHandle;
|
||||
|
||||
typedef struct _LbxStreamOpts {
|
||||
LbxStreamCompHandle (*streamCompInit)(int fd, pointer arg);
|
||||
pointer streamCompArg;
|
||||
int (*streamCompStuffInput)(
|
||||
int fd,
|
||||
unsigned char *buf,
|
||||
int buflen
|
||||
);
|
||||
int (*streamCompInputAvail)(
|
||||
int fd
|
||||
);
|
||||
int (*streamCompFlush)(
|
||||
int fd
|
||||
);
|
||||
int (*streamCompRead)(
|
||||
int fd,
|
||||
unsigned char *buf,
|
||||
int buflen
|
||||
);
|
||||
int (*streamCompWriteV)(
|
||||
int fd,
|
||||
struct iovec *iov,
|
||||
int iovcnt
|
||||
);
|
||||
void (*streamCompOn)(
|
||||
int fd
|
||||
);
|
||||
void (*streamCompOff)(
|
||||
int fd
|
||||
);
|
||||
void (*streamCompFreeHandle)(
|
||||
LbxStreamCompHandle handle
|
||||
);
|
||||
} LbxStreamOpts;
|
||||
|
||||
#endif /* _LBX_OPTS_H_ */
|
||||
64
lbxzlib.h
64
lbxzlib.h
|
|
@ -1,64 +0,0 @@
|
|||
/* $Xorg: lbxzlib.h,v 1.3 2000/08/18 04:05:45 coskrey Exp $ */
|
||||
/*
|
||||
* Copyright 1993 Network Computing Devices
|
||||
*
|
||||
* Permission to use, copy, modify, distribute, and sell this software and its
|
||||
* documentation for any purpose is hereby granted without fee, provided that
|
||||
* the above copyright notice appear in all copies and that both that
|
||||
* copyright notice and this permission notice appear in supporting
|
||||
* documentation, and that the name of NCD. not be used in advertising or
|
||||
* publicity pertaining to distribution of the software without specific,
|
||||
* written prior permission. NCD. makes no representations about the
|
||||
* suitability of this software for any purpose. It is provided "as is"
|
||||
* without express or implied warranty.
|
||||
*
|
||||
* NCD. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL NCD.
|
||||
* BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
|
||||
* OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
|
||||
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*
|
||||
* Author: Dale Tonogai, Network Computing Devices
|
||||
*/
|
||||
|
||||
#ifndef _ZLIB_H_
|
||||
#define _ZLIB_H_
|
||||
|
||||
#define ZLIB_STRCOMP_OPT "XC-ZLIB"
|
||||
#define ZLIB_STRCOMP_OPT_LEN 7
|
||||
|
||||
#define ZLIB_PACKET_HDRLEN 2
|
||||
#define ZLIB_MAX_DATALEN 0xfff
|
||||
#define ZLIB_MAX_PLAIN 270
|
||||
#define ZLIB_MAX_OUTLEN (ZLIB_MAX_PLAIN << 1)
|
||||
|
||||
#define ZLIB_COMPRESS_FLAG 0x80
|
||||
#define ZLIB_DATALEN_MASK 0x0f
|
||||
|
||||
#define ZLIB_PUT_PKTHDR(p, len, compflag) \
|
||||
{ \
|
||||
(p)[0] = ((unsigned)(len)) >> 8 | ((compflag) ? ZLIB_COMPRESS_FLAG : 0);\
|
||||
(p)[1] = (len) & 0xff; \
|
||||
}
|
||||
|
||||
#define ZLIB_GET_DATALEN(p) \
|
||||
((((unsigned)((p)[0] & ZLIB_DATALEN_MASK)) << 8) | (unsigned)(p)[1])
|
||||
|
||||
#define ZLIB_COMPRESSED(p) ((p)[0] & ZLIB_COMPRESS_FLAG)
|
||||
|
||||
struct ZlibInfo;
|
||||
|
||||
extern void * ZlibInit ( int fd, int level );
|
||||
extern void ZlibFree ( struct ZlibInfo *comp );
|
||||
extern int ZlibFlush ( int fd );
|
||||
extern int ZlibStuffInput ( int fd, unsigned char *buffer, int buflen );
|
||||
extern void ZlibCompressOn ( int fd );
|
||||
extern void ZlibCompressOff ( int fd );
|
||||
extern int ZlibWrite ( int fd, unsigned char *buffer, int buflen );
|
||||
extern int ZlibWriteV ( int fd, struct iovec *iov, int iovcnt );
|
||||
extern int ZlibRead ( int fd, unsigned char *buffer, int buflen );
|
||||
extern int ZlibInputAvail ( int fd );
|
||||
|
||||
|
||||
#endif /* _ZLIB_H_ */
|
||||
Loading…
Add table
Reference in a new issue