BufferedImage drawing bug

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

BufferedImage drawing bug

Jan Maslik
Hello,
i would like to report bug of itext library.
iText has wrong interpretation of drawed image into pdf if image has transparent pixel (argb value = 0 ) . 
Image is correct only in case transparent pixels has values (argb =  0xFFFFFF ).
If i save "my" image into png by ImageIO /ImageMagick/PngEncoder , it shows correctly . 

Pasting my wrapped workarround which fixed the issue in case you dont understand because my english skill.

                               BufferedImage img = ...
  
                               RgbIterator pixIterator = FastRGB.getIterator(img);

for(int i = 0 ; i < pixIterator.size() ; i++ )
{
if( pixIterator.isTransparent(i) )
{
pixIterator.setARGB(i, 0xFFFFFF );
}
}

------------------------------------------------------------------------------

_______________________________________________
iText-questions mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/itext-questions

iText(R) is a registered trademark of 1T3XT BVBA.
Many questions posted to this list can (and will) be answered with a reference to the iText book: http://www.itextpdf.com/book/
Please check the keywords list before you ask for examples: http://itextpdf.com/themes/keywords.php
Loading...