splash/SplashTypes.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-)
New commits: commit 1750c0155762e75d0a80ab55b50d1bfd172c2430 Author: Stefan Brüns <[email protected]> Date: Tue May 29 23:49:05 2018 +0200 splash: Correctly manipulate spot colors if SPOT_NCOMPS != 4 The default number of spot colors is 4, in this case the change is without effect, otherwise only the last 4 colors where handled. diff --git a/splash/SplashTypes.h b/splash/SplashTypes.h index ca0e3bc0..1bede11c 100644 --- a/splash/SplashTypes.h +++ b/splash/SplashTypes.h @@ -17,6 +17,7 @@ // Copyright (C) 2009 Stefan Thomas <[email protected]> // Copyright (C) 2010 William Bader <[email protected]> // Copyright (C) 2017 Adrian Johnson <[email protected]> +// Copyright (C) 2018 Stefan Brüns <[email protected]> // // To see a description of the changes please see the Changelog file that // came with your tarball or type make ChangeLog if you are building from git @@ -126,7 +127,7 @@ static inline void splashClearColor(SplashColorPtr dest) { dest[2] = 0; #ifdef SPLASH_CMYK dest[3] = 0; - for (int i = SPOT_NCOMPS; i < SPOT_NCOMPS + 4; i++) + for (int i = 4; i < SPOT_NCOMPS + 4; i++) dest[i] = 0; #endif } @@ -137,7 +138,7 @@ static inline void splashColorCopy(SplashColorPtr dest, SplashColorPtr src) { dest[2] = src[2]; #ifdef SPLASH_CMYK dest[3] = src[3]; - for (int i = SPOT_NCOMPS; i < SPOT_NCOMPS + 4; i++) + for (int i = 4; i < SPOT_NCOMPS + 4; i++) dest[i] = src[i]; #endif } @@ -148,7 +149,7 @@ static inline void splashColorXor(SplashColorPtr dest, SplashColorPtr src) { dest[2] ^= src[2]; #ifdef SPLASH_CMYK dest[3] ^= src[3]; - for (int i = SPOT_NCOMPS; i < SPOT_NCOMPS + 4; i++) + for (int i = 4; i < SPOT_NCOMPS + 4; i++) dest[i] ^= src[i]; #endif } _______________________________________________ poppler mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/poppler
