diff options
author | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2014-10-24 14:20:54 +0200 |
---|---|---|
committer | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2014-10-24 14:20:54 +0200 |
commit | d1a9624a16d8ba5e6ef393c4a984790e44797c59 (patch) | |
tree | 08c0a1313e7cf4cfb36e55b6ec8261be5f4d0b7e /pdf-as-pdfbox/src/main/java/at | |
parent | 394f409032f5af13a34faac251d9929ef64729d1 (diff) | |
download | pdf-as-4-d1a9624a16d8ba5e6ef393c4a984790e44797c59.tar.gz pdf-as-4-d1a9624a16d8ba5e6ef393c4a984790e44797c59.tar.bz2 pdf-as-4-d1a9624a16d8ba5e6ef393c4a984790e44797c59.zip |
enable Alpha Channel images
Diffstat (limited to 'pdf-as-pdfbox/src/main/java/at')
-rw-r--r-- | pdf-as-pdfbox/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/pdfbox/PDFAsVisualSignatureBuilder.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pdf-as-pdfbox/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/pdfbox/PDFAsVisualSignatureBuilder.java b/pdf-as-pdfbox/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/pdfbox/PDFAsVisualSignatureBuilder.java index 2b587d72..927469b1 100644 --- a/pdf-as-pdfbox/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/pdfbox/PDFAsVisualSignatureBuilder.java +++ b/pdf-as-pdfbox/src/main/java/at/gv/egiz/pdfas/lib/impl/stamping/pdfbox/PDFAsVisualSignatureBuilder.java @@ -596,7 +596,8 @@ public class PDFAsVisualSignatureBuilder extends PDVisibleSigBuilder { logger.debug("Scaling image to: " + iwidth + " x " + iheight); - if (img.getColorModel().hasAlpha()) { + if (img.getAlphaRaster() == null && + img.getColorModel().hasAlpha()) { img = ImageUtils.removeAlphaChannel(img); } //img = ImageUtils.convertRGBAToIndexed(img); |