From e69e8b1d09fb579316595b4e6a850e717358a8b1 Mon Sep 17 00:00:00 2001 From: tpearson Date: Sun, 19 Jun 2011 19:03:33 +0000 Subject: TQt4 port kdegraphics This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegraphics@1237557 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kviewshell/plugins/djvu/libdjvu/DjVuPalette.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'kviewshell/plugins/djvu/libdjvu/DjVuPalette.h') diff --git a/kviewshell/plugins/djvu/libdjvu/DjVuPalette.h b/kviewshell/plugins/djvu/libdjvu/DjVuPalette.h index 7f9884f1..e44aab6d 100644 --- a/kviewshell/plugins/djvu/libdjvu/DjVuPalette.h +++ b/kviewshell/plugins/djvu/libdjvu/DjVuPalette.h @@ -104,7 +104,7 @@ namespace DJVU { \Ref{index_to_color}. There are also functions for computing a palette and quantizing a complete pixmap. - {\bf Sequences of color indices} -- The DjVuPalette object also contains + {\bf Sequences of color indices} -- The DjVuPalette object also tqcontains an array \Ref{colordata} optionally containing a sequence of color indices. This array will be encoded and decoded by functions \Ref{encode} and \Ref{decode}. This feature simplifies the implementation of the ``one @@ -210,7 +210,7 @@ public: private: // Histogram - int mask; + int tqmask; GMap *hist; // Quantization data struct PColor { unsigned char p[4]; }; @@ -240,7 +240,7 @@ DjVuPalette::histogram_clear() { delete hist; hist = 0; - mask = 0; + tqmask = 0; } inline void @@ -250,7 +250,7 @@ DjVuPalette::histogram_add(const unsigned char *bgr, int weight) { if (!hist || hist->size()>=0x4000) allocate_hist(); - int key = (bgr[0]<<16)|(bgr[1]<<8)|(bgr[2])|(mask); + int key = (bgr[0]<<16)|(bgr[1]<<8)|(bgr[2])|(tqmask); (*hist)[key] += weight; } } @@ -271,7 +271,7 @@ DjVuPalette::histogram_norm_and_add(const int *bgr, int weight) int p2 = bgr[2]/weight; if (p2>255) p2=255; if (!hist || hist->size()>=0x4000) allocate_hist(); - int key = (p0<<16)|(p1<<8)|(p2)|(mask); + int key = (p0<<16)|(p1<<8)|(p2)|(tqmask); (*hist)[key] += weight; } } @@ -288,7 +288,7 @@ DjVuPalette::color_to_index(const unsigned char *bgr) if (! pmap) allocate_pmap(); int key = (bgr[0]<<16)|(bgr[1]<<8)|(bgr[2]); - GPosition p = pmap->contains(key); + GPosition p = pmap->tqcontains(key); if ( p) return (*pmap)[p]; return color_to_index_slow(bgr); -- cgit v1.2.1