Delegateの設定を見直す

Vodafone Connect Card での接続時にパケット代の節約のため玄箱Delegate Proxyサーバによる画像圧縮をやっています。これを少し見直してみました。
今までは

#!cfi
Content-Type: image/jpeg
Output/Content-Type: image/jpeg
Body-Filter: convert -quality 10 - -

  • -

Content-Type: image/gif
#Output/Content-Type: image/jpeg
#Body-Filter: convert -quality 10 - jpeg:-

  • -

Content-Type: image/png
Output/Content-Type: image/jpeg
Body-Filter: convert -quality 10 - jpeg:-

という設定にしていました。これはgif、pngjpegに変換して圧縮していました。しかし、gifはWebのナビゲーション用の画像に使われていることが多く、今の設定では小さいボタンなどよく分からなくなってしまいます。そこで下記のようにgifはgifのままにして色数を減らして容量を小さくするように変えてみました。

#!cfi
Content-Type: image/jpeg
Output/Content-Type: image/jpeg
Body-Filter: convert -quality 10 - -

  • -

Content-Type: image/gif
Body-Filter: convert +adjoin gif:- gif:- | convert -colors 8 +dither -colorspace Transparent +profile "*" gif:- gif:-

  • -

Content-Type: image/png
Output/Content-Type: image/jpeg
Body-Filter: convert -quality 10 - jpeg:-