08_CM0340_Graphics_Reps

08_CM0340_Graphics_Reps - 297 JJ II J I Back Close...

Info iconThis preview shows pages 1–8. Sign up to view the full content.

View Full Document Right Arrow Icon

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

View Full DocumentRight Arrow Icon

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

View Full DocumentRight Arrow Icon

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

View Full DocumentRight Arrow Icon

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

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: 297 JJ II J I Back Close Graphic/Image File Formats Common graphics and image file formats: http://www.dcs.ed.ac.uk/home/mxr/gfx/ comprehensive listing of various formats. See Encyclopedia of Graphics File Formats book in library Most formats incorporate compression , including lossless or lossy Graphics, video and audio compression techniques in next Chapter. 298 JJ II J I Back Close Graphic/Image Data Structures A picture is worth a thousand words, but it uses up three thousand times the memory. A digital image consists of many picture elements, termed pixels . The number of pixels determine the quality of the image ( resolution ). Higher resolution always yields better quality. A bit-map representation stores the graphic/image data in the same manner that the computer monitor contents are stored in video memory. 299 JJ II J I Back Close Monochrome/Bit-Map Images Figure 5: Sample Monochrome Bit-Map Image Each pixel is stored as a single bit (0 or 1) A 640 x 480 monochrome image requires 37.5 KB of storage. Dithering is often used for displaying monochrome images 300 JJ II J I Back Close Gray-scale Images Figure 6: Example of a Gray-scale Bit-map Image Each pixel is usually stored as a byte (value between 0 to 255) A dark pixel may have a value of 10 ; a bright one may be 240 A 640 x 480 greyscale image requires over 300 KB of storage. 301 JJ II J I Back Close Dithering Dithering is often used when converting greyscale images to monochrome ones e.g. for printing The main strategy is to replace a pixel value (from 0 to 255) by a larger pattern (e.g. 4 4 ) such that the number of printed dots approximates the greyscale level of the original image If a pixel is replaced by a 4 4 array of dots, the intensities it can approximate from 0 (no dots) to 16 (full dots). Given a 4 4 dither matrix e.g. 8 2 10 12 4 14 6 3 11 1 9 15 7 13 5 we can re-map pixel values from 0255 to a new range 016 by dividing the value by (256/17) (and rounding down to integer). 302 JJ II J I Back Close Dithering (cont.) A simple approach: replace each pixel by a 4 4 dots (monochrome pixels). If the remapped intensity is > the dither matrix entry, put a dot at the position (set to 1) otherwise set to 0. Note that the size of the dithered image may be much larger. Since each pixel is replaced by 4 4 array of dots, the image becomes 16 times as large. To keep the image size: an ordered dither produces an output pixel with value 1 iff the remapped intensity level just at the pixel position is greater than the corresponding matrix entry. 303 JJ II J I Back Close 24-bit Colour Images Figure 7: Example of 24-Bit Colour Image Each pixel is represented by three bytes (e.g., RGB) Supports 256 x 256 x 256 possible combined colours (16,777,216) A 640 x 480 24-bit colour image would require 921.6 KB of storage Some colour images are 32-bit images,...
View Full Document

This note was uploaded on 01/26/2012 for the course CM 0340 taught by Professor Davidmarshall during the Fall '09 term at Cardiff University.

Page1 / 56

08_CM0340_Graphics_Reps - 297 JJ II J I Back Close...

This preview shows document pages 1 - 8. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online