toy/image_optim — pull request #65 by wjordan (2014-10-05 18:22:33+00:00)
Title: Add support for jpeg-recompress from danielgtaylor/jpeg-archive

Adds support for the `jpeg-recompress` utility from [danielgtaylor/jpeg-archive](https://github.com/danielgtaylor/jpeg-archive#jpeg-recompress):
>jpeg-recompress

>Compress JPEGs by re-encoding to the smallest JPEG quality while keeping perceived visual quality the same and by making sure huffman tables are optimized.

I've set the program to be disabled by default. It is enabled by using the `--jpegoptim-max-quality N` option to set a JPEG quality preset other than `lossless`.

Other configuration options are available aside from the quality preset, but I haven't added them to the `image_optim` options:
```
-t, --target [arg] Set target quality [0.9999]
-n, --min [arg] Minimum JPEG quality [40]
-x, --max [arg] Maximum JPEG quality [95]
-l, --loops [arg] Set the number of runs to attempt [6]
-a, --accurate Favor accuracy over speed
-m, --method [arg] Set comparison method to one of 'mpe', 'ssim', 'ms-ssim', 'smallfry' [ssim]
-s, --strip Strip metadata
-d, --defish [arg] Set defish strength [0.0]
-z, --zoom [arg] Set defish zoom [1.0]

```