openslide-java icon indicating copy to clipboard operation
openslide-java copied to clipboard

transparency rendered as black

Open rmcloughlin opened this issue 7 years ago • 0 comments

I'm using openslide-java to create thumbnail images of slides. It works correctly for most slides but if a slide contains a transparent section then that part is rendered as black. The get_thumbnail() method of the python API renders transparency as white (which is the behavior that I would like).

I'm using the API like this:

OpenSlide openSlide = new OpenSlide(inputFile);
BufferedImage image = openSlide.createThumbnailImage(300);
ImageIO.write(image, "jpg", outputFile);

I've attached an example image (tiled tiff with transparency).

input.zip

rmcloughlin avatar Jul 08 '17 03:07 rmcloughlin