37. Compressing images

Write an extension method for the Image class named SaveCompressed that saves a JPG image with a specified level of compression. (Hint: Use an ImageCodecInfo object)

To test your method, write a program that lets the user open an image and then use a scrollbar to view the image at different compression levels. When the user changes the compression level, the program should display the compressed image, the compression level, and the compressed file's size. Let the user save the image into a new file at the currently selected compression level.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.17.62.34