mikera / imagez

Image processing library for Clojure
302 stars 38 forks source link

Access to imgscalr options #29

Open vvvvalvalval opened 8 years ago

vvvvalvalval commented 8 years ago

I've been using imagez to scale down JPEG images but I was dissatisfied with the output quality.

Turns out that you can improve it significantly by using the ULTRA_QUALITY method of imgscalr.

would be interesting to make those options accessible.

mikera commented 8 years ago

Sounds like a good idea. Perhaps ULTRA_QUALITY should even be the default?

vvvvalvalval commented 8 years ago

@mikera I agree, I cannot see any reason not to use it by default (except performance requirements).

vvvvalvalval commented 8 years ago

@mikera On second thought, having dived a little bit in the documentation, I believe the best course of action is to leave AUTOMATIC by default (which by definition is meant to let the library try and be smart about the algorithm to be used), while exposing tuning options to the user and providing her a link to the documentation.

rcanepa commented 8 years ago

Hi. I am facing the same issue. I can't get a good quality output after scaling (resizing) down an image. @vvvvalvalval, how did you solve the problem?

vvvvalvalval commented 8 years ago

@rcanepa I ended up going down to ImgScalr via Java interop. Shoud be fairly easy for you to do by looking at the source code of imagez.

rcanepa commented 8 years ago

@vvvvalvalval, excellent. I'll do that too.

mikera commented 8 years ago

Happy to have a PR that exposes the options to Clojure (as an additional options map)

brianium commented 6 years ago

@mikera just started using this library - it's fantastic. I have a need for this too, are you still open to PRs?

mikera commented 6 years ago

Glad you like it! PRs very welcome!