From: Adriana Mikolaskova Date: 2012-11-30T18:56:53+09:00 Subject: compressing files Hello, i want to show the jpeg-compression data loss on different images... for this purpose I'm trying to save an image several times with a ruby (rmagick) script. The problem is: the image is compressed once and there is no data loss after the first saving... Here is the code I'm trying to work with. What could be wrong? How can I change the code, that there is a difference in saving 7 times or 18 times...f.e. $i = 1 $num = 700 while $i < $num do puts $i img = Image.read("mypath/line1.jpeg").first img.rotate!(90) img.write("mypath/line1.jpeg"){ self.quality = 50 } img.destroy! img = nil GC.start $i +=1 end Thanks Adriana -- Posted via http://www.ruby-forum.com/.