java - Scalr image resize changes background color on output -


i using scalr resize images. have problem images. scalr changing color of resized image. in short, outline of code. read file byte array:

bufferedimage image = imageio.read(bis); 

then resize image using scalr:

scalr.resize(image,       scalr.method.ultra_quality, scalr.mode.automatic, targetwidth, targetheight); 

then, write output file:

bytearrayoutputstream baos = new bytearrayoutputstream(); imageio.write(bufferedimage, extension, baos); 

the type of image before , after resizing same , equals type_4byte_abgr.

original image:

original image

image after resize:

image after resizing


Comments

Popular posts from this blog

account - Script error login visual studio DefaultLogin_PCore.js -

xcode - CocoaPod Storyboard error: -