How to resize jpg image to fit certain bytesize?
I am implementing a client app which should send images not exeding 200KB. However some images sometimes exceed 200KB(JPG).
I tried ImageMagick, "extent" command, however it seems that it deals with compression rather than image dimensions, whereas I need to preserve compression rate(Edit 1: quality) and resize only dimensions.
I am using java's ImageIO through Clojure and there also seems to be no exact solution.