From d4cbaa0c17c512c9bd1de429779a9ee0ed927aed Mon Sep 17 00:00:00 2001 From: Christian Beier Date: Mon, 30 Apr 2012 21:26:58 +0200 Subject: Only try to build TightPNG stuff when libjpeg is available. TightPNG replaces the ZLIB stuff int Tight encoding with PNG. It still uses JPEG rects as well. Theoretically, we could build TightPNG with only libpng and libjpeg - without zlib - but libpng depends on zlib, so this is kinda moot. --- rfb/rfb.h | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'rfb') diff --git a/rfb/rfb.h b/rfb/rfb.h index a265746..041b668 100644 --- a/rfb/rfb.h +++ b/rfb/rfb.h @@ -603,8 +603,6 @@ typedef struct _rfbClientRec { z_stream zsStruct[4]; rfbBool zsActive[4]; int zsLevel[4]; -#endif -#if defined(LIBVNCSERVER_HAVE_LIBJPEG) || defined(LIBVNCSERVER_HAVE_LIBPNG) int tightCompressLevel; #endif #endif @@ -880,22 +878,18 @@ extern rfbBool rfbSendRectEncodingUltra(rfbClientPtr cl, int x,int y,int w,int h extern rfbBool rfbSendRectEncodingZlib(rfbClientPtr cl, int x, int y, int w, int h); -#if defined(LIBVNCSERVER_HAVE_LIBJPEG) || defined(LIBVNCSERVER_HAVE_LIBPNG) +#ifdef LIBVNCSERVER_HAVE_LIBJPEG /* tight.c */ #define TIGHT_DEFAULT_COMPRESSION 6 - -#ifdef LIBVNCSERVER_HAVE_LIBJPEG #define TURBO_DEFAULT_SUBSAMP 0 -#endif extern rfbBool rfbTightDisableGradient; extern int rfbNumCodedRectsTight(rfbClientPtr cl, int x,int y,int w,int h); -#if defined(LIBVNCSERVER_HAVE_LIBJPEG) extern rfbBool rfbSendRectEncodingTight(rfbClientPtr cl, int x,int y,int w,int h); -#endif + #if defined(LIBVNCSERVER_HAVE_LIBPNG) extern rfbBool rfbSendRectEncodingTightPng(rfbClientPtr cl, int x,int y,int w,int h); #endif -- cgit v1.2.3