{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

CS101.Lect18.Images.Compression

# CS101.Lect18.Images.Compression - CS101 Lecture 18 Image...

This preview shows pages 1–6. Sign up to view the full content.

1 1 Aaron Stevens 21 October 2010 Some material form Wikimedia Commons Special thanks to John Magee and his dog CS101 Lecture 18: Image Compression 2 What You’ll Learn Today – Review: how big are image files? – How can we make image files smaller? – What are the main image file formats, and how are they different from each other? – What are the main techniques for compressing images?

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
2 3 Image File Size: HUGE! Raster/Bitmap Graphics Storage of data on a pixel-by-pixel basis Bitmap (BMP), GIF, JPEG, and PNG, for example How much data is required to represent a picture? Typical size might be 1024 by 768 pixels (~ 800,000) At 3 bytes per pixel, about 2,400,000 bytes for one picture. A 10Mpixel picture would be 30,000,000 bytes per picture. 4 Consider download times… Example: A 10Mpixel picture would be 30,000,000 bytes This is 240,000,000 bits. Typical home cable modem downloads at 5 Mbits per second (5,000,000 bits per second). How long to download this picture? – 240,000,000 / 5,000,000 = 48 seconds What factors make the image so big?
3 5 Describe this picture… This image was a homework assignment by a CS108 student, Spring 2008. Vector Graphics describes an image by coordinates, lines, geometric shapes and colors. 6 Vector Graphics Example Instructions written in Python by CS108 student (Spring 2010). File size: 29743 bytes.

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
4 7 Vector Graphics Advantages: – Small file sizes (instructions take much less space than sampling pixels) – Easy to resize mathematically without loss of detail Disadvantages: – Image shapes are not lifelike – Color contrast and texturing are rigid, not lifelike – Requires software to interpret the drawing instructions 8 Raster vs. Vector Graphics When would you use each? Drawings, Diagrams, Games, etc. Photography, video, etc.
5 9 Storing an image in fewer bytes What are our choices? What are reasonable tradeoffs? –Raster Graphics vs. Vector Graphics? –Decrease sampling rate (fewer pixels) –Decrease quantization (fewer colors) –Compression 10 Lower Image Resolution?

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern