summaryrefslogtreecommitdiffstats
path: root/kviewshell/plugins/djvu/libdjvu/DjVuPalette.h
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-19 19:03:33 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-19 19:03:33 +0000
commite69e8b1d09fb579316595b4e6a850e717358a8b1 (patch)
treea24fc20865f65772f530d16177520190594ffdd2 /kviewshell/plugins/djvu/libdjvu/DjVuPalette.h
parenteecec9afb81fdebb0f22e9da22635874c403f854 (diff)
downloadtdegraphics-e69e8b1d09fb579316595b4e6a850e717358a8b1.tar.gz
tdegraphics-e69e8b1d09fb579316595b4e6a850e717358a8b1.zip
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
Diffstat (limited to 'kviewshell/plugins/djvu/libdjvu/DjVuPalette.h')
-rw-r--r--kviewshell/plugins/djvu/libdjvu/DjVuPalette.h12
1 files changed, 6 insertions, 6 deletions
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<int,int> *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);