summaryrefslogtreecommitdiff
path: root/poppler
diff options
context:
space:
mode:
authorAlbert Astals Cid <aacid@kde.org>2006-05-23 20:49:16 +0000
committerAlbert Astals Cid <aacid@kde.org>2006-05-23 20:49:16 +0000
commit6f5a89a0a2cf17d45d1c31ce105829be8c7ac456 (patch)
tree660ebe54d1976344b590e82c84175543797c3ce8 /poppler
parent495d592c3ba7fe81e03774f5b2ed677e5aa560c7 (diff)
* poppler/SplashOutputDev.cc:
* qt4/src/poppler-private.h: * splash/Splash.cc: * splash/SplashBitmap.cc: * splash/SplashTypes.h: bring splashModeRGB8 back to the old code (before Frank's patch), create splashModeRGB8Qt that has Frank's codepath and is used by Qt frontends. Fixes corruption on other programs expecting the old behaviour. Remember dude we are now a lib! you can not change behaviour from one day to another! /me hits himself
Diffstat (limited to 'poppler')
-rw-r--r--poppler/SplashOutputDev.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/poppler/SplashOutputDev.cc b/poppler/SplashOutputDev.cc
index 5cd69a10..14876169 100644
--- a/poppler/SplashOutputDev.cc
+++ b/poppler/SplashOutputDev.cc
@@ -626,6 +626,7 @@ void SplashOutputDev::startPage(int pageNum, GfxState *state) {
break;
case splashModeRGB8:
case splashModeBGR8:
+ case splashModeRGB8Qt:
color[0] = color[1] = color[2] = 0;
break;
case splashModeAMono8:
@@ -877,6 +878,7 @@ SplashPattern *SplashOutputDev::getColor(GfxGray gray, GfxRGB *rgb) {
pattern = new SplashSolidColor(color1);
break;
case splashModeRGB8:
+ case splashModeRGB8Qt:
color1[0] = colToByte(r);
color1[1] = colToByte(g);
color1[2] = colToByte(b);
@@ -1670,6 +1672,7 @@ GBool SplashOutputDev::imageSrc(void *data, SplashColorPtr line) {
break;
case splashModeRGB8:
case splashModeBGR8:
+ case splashModeRGB8Qt:
for (x = 0, p = imgData->imgStr->getLine(), q = line;
x < imgData->width;
++x, ++p) {
@@ -1713,6 +1716,7 @@ GBool SplashOutputDev::imageSrc(void *data, SplashColorPtr line) {
}
break;
case splashModeRGB8:
+ case splashModeRGB8Qt:
for (x = 0, p = imgData->imgStr->getLine(), q = line;
x < imgData->width;
++x, p += nComps) {
@@ -1797,6 +1801,7 @@ GBool SplashOutputDev::alphaImageSrc(void *data, SplashColorPtr line) {
*q++ = imgData->lookup[*p];
break;
case splashModeRGB8:
+ case splashModeRGB8Qt:
*q++ = alpha;
col = &imgData->lookup[3 * *p];
*q++ = col[0];
@@ -1838,6 +1843,7 @@ GBool SplashOutputDev::alphaImageSrc(void *data, SplashColorPtr line) {
*q++ = colToByte(gray);
break;
case splashModeRGB8:
+ case splashModeRGB8Qt:
imgData->colorMap->getRGB(p, &rgb);
*q++ = alpha;
*q++ = colToByte(rgb.r);
@@ -2043,6 +2049,7 @@ GBool SplashOutputDev::maskedImageSrc(void *data, SplashColorPtr line) {
*q++ = imgData->lookup[*p];
break;
case splashModeRGB8:
+ case splashModeRGB8Qt:
*q++ = alpha;
col = &imgData->lookup[3 * *p];
*q++ = col[0];
@@ -2084,6 +2091,7 @@ GBool SplashOutputDev::maskedImageSrc(void *data, SplashColorPtr line) {
*q++ = colToByte(gray);
break;
case splashModeRGB8:
+ case splashModeRGB8Qt:
imgData->colorMap->getRGB(p, &rgb);
*q++ = alpha;
*q++ = colToByte(rgb.r);