imwrite() always increases the size of the PNG image.

asked 2020-06-29 04:53:33 -0500

snsinha gravatar image

I am trying to do operations on the image. 1. Resizing and decreasing its dimensions 2. Converting a JPEG image to PNG. In both the cases the final image is larger than the original imgae.How can I fix it?I m using java

edit retag flag offensive close merge delete

Comments

2

there are compression options (default level for png is 3)

berak gravatar imageberak ( 2020-06-29 05:15:59 -0500 )edit
1

and please clarify, that you mean disk size

berak gravatar imageberak ( 2020-06-29 05:17:41 -0500 )edit

I tried that with the value 9 .It did not help

snsinha gravatar imagesnsinha ( 2020-06-29 05:19:34 -0500 )edit
1

I mean the file size

snsinha gravatar imagesnsinha ( 2020-06-29 05:21:29 -0500 )edit