How to: Simulate jpeg generation loss

edited September 2015 in How To...

Hi,

I am wanting to simulate jpeg generation loss.

That is, open a jpeg image, save with slightly more compression and repeat with the last saved image. Eventually, after many iterations image quality is visibly reduced.

Please refer to this video (code included below video) to see this being done successfully. However, even though the code for this is provided, I am unable to replicate :(.

I am not wanting a video of gradual degradation but individual images at various interations i.e. 100, 200, 400, 800 etc

I have a feeling the import com.sun..... library is the issue.

Thanks for any advice

Tagged:

Answers

  • It looks like these classes are no longer available in Java. You need to use ImageIO instead.

  • Ok great. Thanks for the reply.

    Still haven't got it to work if there are any kind souls willing to rework the code to suit the newer classes?

Sign In or Register to comment.