# Attachment\_fu file sizes

**URL:** <https://www.ruby-forum.com/t/attachment-fu-file-sizes/111031>\
**Category:** Rails\
**Created:** [August 2, 2007, 1:35am UTC](https://www.ruby-forum.com/t/attachment-fu-file-sizes/111031 "2007-08-02T01:35:12Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![dcgrigsby](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/b5e925/32.png) [@dcgrigsby](https://www.ruby-forum.com/u/dcgrigsby)\
**Post date:** [August 2, 2007, 1:35am UTC](https://www.ruby-forum.com/t/attachment-fu-file-sizes/111031/1 "2007-08-02T01:35:12Z")

</div>

Hi, I’ve been using minimagick with attachment\_fu and have noticed the  
resized jpeg files are huge, over 100kb for a 640\*480 pic. Does anyone  
know a way to compress these files upon conversion?  
-Thanks

---

<div class="post-metadata">

**Author:** ![dcgrigsby](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/b5e925/32.png) [@dcgrigsby](https://www.ruby-forum.com/u/dcgrigsby)\
**Post date:** [August 2, 2007, 1:45am UTC](https://www.ruby-forum.com/t/attachment-fu-file-sizes/111031/2 "2007-08-02T01:45:39Z")

</div>

On 02 Aug 2007, at 01:35, Dan G. wrote:

> Hi, I’ve been using minimagick with attachment\_fu and have noticed the  
> resized jpeg files are huge, over 100kb for a 640\*480 pic. Does anyone  
> know a way to compress these files upon conversion?

As minimagick probably uses the ImageMagick command line utility  
“convert” in the plugin code somewhere to scale the images, you  
should be able to bring the size down by adding the -quality  
parameter to the command. Possible values are described at http://

> **[ImageMagick](http://www.imagemagick.org/script/command-line-options.php#quality)**
>
> Create, Edit, Compose, or Convert Digital Images

Best regards

Peter De Berdt

---

<div class="post-metadata">

**Author:** ![dcgrigsby](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/b5e925/32.png) [@dcgrigsby](https://www.ruby-forum.com/u/dcgrigsby)\
**Post date:** [August 3, 2007, 1:33pm UTC](https://www.ruby-forum.com/t/attachment-fu-file-sizes/111031/3 "2007-08-03T13:33:52Z")

</div>

On 2 Aug 2007, at 00:35, Dan G. wrote:

> Hi, I’ve been using minimagick with attachment\_fu and have noticed the  
> resized jpeg files are huge, over 100kb for a 640\*480 pic. Does anyone  
> know a way to compress these files upon conversion?

It could be related to embedded metadata:

[http://blog.airbladesoftware.com/2007/6/27/compressing-images-with-](http://blog.airbladesoftware.com/2007/6/27/compressing-images-with-)  
attachment\_fu-and-rmagick

Regards,  
Andy S.
