1 / 47

Lecture # 17 Image Representation

Lecture # 17 Image Representation. "Be wary, therefore, when some demand public tolerance for whatever their private indulgences are!". "Be wary, therefore, when some demand public tolerance for whatever their private indulgences are!" - Neal A. Maxwell. Image Representation.

iden
Télécharger la présentation

Lecture # 17 Image Representation

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Lecture # 17 Image Representation

  2. "Be wary, therefore, when some demand public tolerance for whatever their private indulgences are!"

  3. "Be wary, therefore, when some demand public tolerance for whatever their private indulgences are!" - Neal A. Maxwell

  4. Image Representation

  5. Digital Image Sources • Digital Cameras • Scanned Film & Photographs • Digitized TV Signals • Computer Graphics • Radar & Sonar • Medical Imaging Devices (X-Ray, CT) • The Internet

  6. Images - 2D array of values = pixels • Pixel = “Picture Element” • Image [x,y] = pixel value (number)

  7. Pixels and Pixel Values • Pixel – an element of the 2-D image array • Pixel Value = brightness • - black = 0 • - gray = 128 • - white = 255 • - many shades over the 0-255 range

  8. Digitizing Images Images are digitized using a two step process: • sampling the continuous tone image • quantizing pixels

  9. Sampling

  10. Quantization pixel’s samples are averaged

  11. Quantization Example

  12. Image Resolution 68 x 104 136 x 208 272 x 416 less detail more detail less storage more storage

  13. Digital Cameras • Very LowRes 640x480 (TV grade) • Medium-Low Res 1024x768 • MediumRes 2048x1536 • Medium-HiRes 3072x2048 • Hi-Res 3264x2448

  14. Dynamic Range • The number of quantized pixel values: 256 levels 16 levels 4 levels 2 levels

  15. Images - 2D array of values • Binary Images (pixel values = 0,1) • Grayscale Images (pixel values = 0-255) • Color Images • Each pixel has three color components • For example, (red, green, blue) or RGB • Each color component is 0-255

  16. Color Images 3 Images Overlayed Blue Green Red

  17. 1 3 21 31 21 4 2 1 2 Histograms: What’s in the image? • What is a histogram? • Simple numeric example 1 2 3 4 Image Histogram

  18. Color Image Histograms • Histogram for each color

  19. RGB Additive Color Model RED GREEN BLUE bright values => high amounts of that color dark values => low amounts of that color

  20. CMYK Subtractive Color Model Bright => use less of that ink color Dark => use lots of that ink color CYAN MAGENTA YELLOW BLACK

  21. HSB Visual Color Model HSB: how artists perceive color properties

  22. o 0 HSB Visual Color Model HSB: how artists perceive color properties o 360 Hue Select Hue

  23. o 0 HSB Visual Color Model HSB: how artists perceive color properties o 360 Saturation Hue Select Hue - then click in box for saturation, brightness

  24. o 0 HSB Visual Color Model HSB: how artists perceive color properties o 360 Saturation Brightness Hue Select Hue - then click in box for saturation, brightness

  25. Storing Digital Images • Digital images are converted to files for storage and transfer • The file type is a special format for ordering and storing the bytes that make up the image • File types or formats are not necessarily compatible • You must often match the file type with the application

  26. Storing Digital Images • GIF (Graphic Interchange Format) • indexed color (up to 256 colors) • compressed • used in Web applications • JPEG (Joint Photographic Experts Group) • lossy compression with variable controls • also used in Web applications

  27. Storing Digital Images • PNG (Portable Network Graphics) • designed for online viewing (e.g., Web) • patent-free replacement for GIF • lossless compression • BMP • MS Windows image format

  28. How Many Bytes to Store an Image? • Suppose we a have an image that is 500x500 pixels in size • That’s a total of 250,000 pixels • Binary image (1 bit/pixel) = 31,250 bytes • Grayscale image (8 bits/pixel) = 250,000 bytes • Color image (24 bits/pixel) = 750,000 bytes

  29. Indexed Color • “Indexed Color” can be used to reduce the size of a color image file = 27 bytes = 18 bytes 0 1 2

  30. Indexed Color Images • are derived from full color images • are smaller or more compact in storage • are composed of pixels selected from a limited palette of colors or shades Demo: GIMP Posterize

  31. Image Processing II

  32. 2 Classes of Digital Filters • Global filters transform each pixel uniformly according to the function regardless of its location in the image • Local filters transform a pixel depending upon its relation to surrounding ones

  33. Global Filters: REVIEW • Brightness and Contrast control • Histogram thresholding • Histogram stretching or equalization • Color corrections • Inversions

  34. ImageEditing

  35. Image Editing • Selection Tools • Painting Tools • Cut & Paste • Cloning • Layers and Blending

  36. Selection Tools Tool Bar • Rectangular Selection • Oval Selection • Lasso Tool • Magic Wand • Color Select Tool • Intelligent Scissors • Foreground Select Tool DEMOS

  37. Image Editing • Selection Tools • Painting Tools • Cut & Paste • Cloning • Layers and Blending

  38. Painting Tools • Paint Bucket Tool • Gradient Shade • Pencil Tool • Paintbrush Tool • Eraser • Airbrush Tool • Ink Tool DEMOS

  39. Image Editing • Selection Tools • Painting Tools • Cut & Paste • Cloning • Layers and Blending

  40. Cut & Paste • Word Processors - cut & paste strings of characters (1D arrays) • Image Editing - cut & paste pixels (2D arrays) - replace old pixels with new pixels

  41. Image Editing • Selection Tools • Painting Tools • Cut & Paste • Cloning • Layers and Blending

  42. Cloning • Copy pixels from one part of an image - to another part of an image ... Interactively DEMO

  43. Image Editing • Selection Tools • Painting Tools • Cut & Paste • Cloning • Layers and Blending

  44. Layers and Blending Can create arbitrary number of layers for - animation - special effects in movies - morphing Layer n Layer 2 Layer 1

  45. Blending • The idea: Blended image = .3 x + .7 x is a weighted combination (sum) of two or more other images.

  46. Example Blend .3 x +.7 x = Bearastronaut

  47. Masking • The idea: Create another image where the value of pixels is the weighting term for a blend operation:

More Related