Presentation is loading. Please wait.

Presentation is loading. Please wait.

LECTURE 5: DIGITAL IMAGE TECHNOLOGY EVI INDRIASARI MANSOR Tel ext: 1741 1.

Similar presentations


Presentation on theme: "LECTURE 5: DIGITAL IMAGE TECHNOLOGY EVI INDRIASARI MANSOR Tel ext: 1741 1."— Presentation transcript:

1 LECTURE 5: DIGITAL IMAGE TECHNOLOGY EVI INDRIASARI MANSOR Email: evi@fsktm.upm.edu.my Tel ext: 1741 1

2 Outline  Representing Image  Reproducing Colour on Computer  Storing Image  Digitizing Image  Information Delivery 2

3 Learning Outcomes  Able to relate the various factors that apply to the use of images in multimedia  Able to explain the capabilities and limitations of bitmap and vector images 3

4 Representing Image  All digital images are represented digitally by pixels  An image is defined by image width, height and pixel depth  Hence… e.g. 400 X 150 X 24-bits … and you get the image size  The number of bits used per pixel in an image depends on the colour space representation (grey or colour) and is typically segregated into channels  Refer Lecture 2b (pg 4 - 17) 4

5 Representing Image (cont)  The total number of bits per pixel = the sum of the number of bits used in each channel  E.g. in grayscale image – the gray-level value is encoded on 8 bits for each pixel (i.e. 256 choices)  E.g. in colour images, each R, G, B channel may be represented by 8 bits each, or 24 bits for a pixel (for 24-bit… 16,777,216 choices )  Sometimes uses fourth channel called the alpha channel  Alpha channel represent an additional 8 bits – bringing the total bit depth of each pixel to 32 bits 5

6 Representing Image (cont)  Very important role in multimedia products  photograph-like bitmaps  vector-based drawings  3D renderings  Still images created depends on the display resolution, and hardware and software capabilities.  Right tools and right hardware for image development is important!  e.g., graphic designers like to have large, high- resolution monitors or multiple monitors 6

7 Actual correspondence with a multimedia director… when asked about monitor size for development Salam, Kau tgk studio aku (yang selekeh macam director dia jugak) standard 22inch - 24inch monitor. Modeler memang request nak dua. Senang nak view and work. Animator kalau ada dua best la. Satu pun OK. Tapi aku punya Graphic Card sini biasa datang dah ada dua tempat cucuk monitor tu. Tapi editing kalau, satu monitor memang semak. Biasa editor pakai dua. Timeline panjang. Lepas tu ada TV 30inch lagi. Baru orang boleh preview. 7

8 8

9 9

10 10 http://upload.wikimedia.org/wikipedia/commons/thumb/f/f0/Vector_Video_Standards4.svg/749px- Vector_Video_Standards4.svg.png

11 Representing Image (cont)  Elements of graphics  To create a remarkable graphics, developer must understand graphics and its elements: Lines Shapes Space Texture Colour 11

12 Representing Image (cont)  Lines A mark with length and directions Continuous mark made on some surface by a moving point Types of line include: vertical, horizontal, diagonal, straight or ruled, curved, bent, angular, etc 12

13 13

14 Representing Image (cont)  Shapes Enclosed space defined and determined by other art elements such as line, color, value, and texture Can appear as 2 dimensional (2D) or 3 dimensional (3D) 14

15 Representing Image (cont)  Space Refers to the distance or area between, around, above, below, or within things Two-dimensional or three-dimensional; as flat, shallow or as positive or negative space etc 15

16 Representing Image (cont)  Texture Surface quality or "feel" of an object, its smoothness, roughness, softness, etc Actual or Simulated 16

17 Representing Image (cont)  Texture (cont) Actual textures - can be felt with fingers Simulated textures - suggested by an artist in the painting of different areas of a picture 17

18 Representing Image (cont)  Still images  Two types: Bitmaps (or raster-based) Vector-drawn 18

19 Representing Image (cont)  Bitmaps  Derived from the words bit Only two digits are used (on/off, black/white, true/false)  Map – two-dimensional matrix of these bits  Hence  BITMAP – data matrix describing the individual dots of an image the smallest elements (pixels) of resolution on a computer screen or printer 19

20 Representing Image (cont)  Bitmaps (cont) 20

21 Representing Image (cont)  Bitmaps (cont)  Suited for creation of: Photo-realistic images (photographer) Complex drawings that require fine detail  Known as paint graphics  Can have varying bit and color depths 21

22 Representing Image (cont)  Bitmaps (cont)  More bits provide more color depth more photo-realism  Require more memory and processing power 22

23 Representing Image (cont)  Bitmaps (cont) – Bits per pixel 23 1 bit1 - Monochrome 8 bits – 256 colors 16 bits – 65K colors 24 bits per pixel allows millions of colors (i.e. 2 24 = 16,777,216) 32 bits per pixel – trillions of colors (i.e. 2 32 = 4,294,967,296)

24 Representing Image (cont)  Bitmaps (cont) – Bits per pixel 24 1 bit = 2 colors2 bits = 4 colors4bits = 16 colors 8 bit = 256 colors24 bits = (16,777,216 colors, "True color")

25 Representing Image (cont)  Bitmaps (cont) – Pseudocolour palettes  1-bit – monochrome, often black and white, compact Macintoshes  2-bit – CGA, gray-scale early NeXTstation, color Macintoshes  3-bit – early home computers with TV displays  4-bit – used by EGA and by the least common denominator VGA standard at higher resolution, color Macintoshes  5-bit – original Amiga chipset  6-bit – original Amiga chipset  8-bit – most early color Unix workstations, VGA at low resolution, Super VGA, AGA, color Macintoshes  12-bit – some Silicon Graphics systems, Neo Geo, Color NeXTstation systems, and Amiga systems in HAM mode  16-bit – some color Macintoshes 25

26 Representing Image (cont)  Bitmaps (cont) – Bitmaps usage  Bitmaps and their suitability of use:- Native Microsoft bmp format as a raw image Faster to process (files can be colossal however…) JPEG (Joint Photographic Experts Group) photo sharing on the web because of its size and quality GIF used for diagrams, buttons, etc., that have a small number of colors also suitable for simple animation because it supports interlaced images PNG (Portable Network Graphics) equal to gif except that it didn‘t support the animation format 26

27 Representing Image (cont)  Bitmaps (cont) – Memory cost of images  Large images consume large memory and make our computers struggle.  Memory cost – computed from the image size  E.g., 6 x 4 inch image at 150 dpi (dots per inch) (6 inches × 150 dpi) × (4 inches × 150 dpi) = 900 × 600 pixels 900 × 600 pixels = 540,000 pixels The memory cost for this RGB color (3 bytes) image is: 900 × 600 × 3 = 1.6 million bytes  3 bytes of RGB color information per pixel for 24 bit color (3 RGB values per pixel, one 8-bit byte for each RGB value, which totals 24 bit color) 27

28 Representing Image (cont)  Bitmaps (cont) – Memory cost of images 28

29 Representing Image (cont)  Bitmaps (cont) – Scanning an image 29

30 30 A bit about resolution…A bit about resolution… Consider an image  200 X 200 pixelsConsider an image  200 X 200 pixels Consider these…Consider these… 1.How big (physical dimension) will an image be if displayed on 72 dpi monitor? 2.On a 300 dpi monitor? Make use of this formula… PHYSICAL DIMENSION = PIXEL DIMENSION / DEVICE RESOLUTION

31 31 Calculations 1.72 dpi From the previous formula…From the previous formula… 200 / 72 = 2.78 inches (same for the height as well since it’s a square image)200 / 72 = 2.78 inches (same for the height as well since it’s a square image) This is about 6.95 cm²This is about 6.95 cm² 2. The image is displayed on a monitor that is 300 dpi? From the previous formula…From the previous formula… 200 / 300 = 0.67 inches (same for the height as well since it’s a square image)200 / 300 = 0.67 inches (same for the height as well since it’s a square image) This is about cm² 1.68 cm²This is about cm² 1.68 cm²  Pixel-wise… still 200 X 200  The first monitor has less pixels compared to the second, so the image appears bigger

32 32 That’s why this happens Monitor Resolution 1024 X 768 Size = 600 pixels

33 33 Size = 600 pixels Monitor Resolution 800 X 600 That’s why this happens (cont)

34 Calculating image size  Now let’s see how to calculate an image’s size and convert between bytes, kilobytes, megabytes etc…  Say the SMURF house has a 500 X 400 pixel resolution  Say that each pixel is 24-bits (i.e. 24-bits per pixel or 3-bytes per pixel)  Therefore, the size would be: (500 X 400)-pixels X 24-bits/pixel = 4,800,000-bits … which is equivalent to 4,800,000/8 = 600,000-bytes … which is equivalent to 600,000/1,024 = 585.94-kilobytes (since 1KB = 1,024-bytes) … which is equivalent to 585.94/1,024 = 0.572-megabytes … which is equivalent to 0.572/1,024 = 0.00056-gigabytes … and so on and so forth 34 http://www.computerhope.com/issues/chspace.htm - for more info you can go here

35 Representing Image (cont)  Vector-drawn  created from geometric objects such as lines, rectangles, ovals, polygons using mathematical formulas  Used in: Computer-aided design (CAD) programs Graphic artists designing for the print media 3-D animation programs Applications requiring drawing of graphic shapes 35

36 36

37 Representing Image (cont)  Vector-drawn  A vector – a line that is described by the location of its two endpoints  Vector drawing – use of Cartesian co-ordinates  Cartesian coordinates are numbers that describe a point in two or three-dimensional space as the intersection of X, Y, and Z axis 37 X Y Z

38 Representing Image (cont)  Vector-drawn (cont)  Example: RECT 0,0,200,300,RED,BLUE says draw a rectangle starting at 0,0 (upper left corner of screen) going 200 pixels horizontally right and 300 pixels downward with a RED boundary and filled with BLUE 38 300 pixel 200 pixel

39 39 Representing Image (cont)  Vector-drawn (another exmaple)  A Postscript page description language might have the following: 0 1 0 setrgbcolor 0 0 128 128 rectfill 1 0 1 setrgbcolor 32 32 64 64 rectfill

40 Representing Image (cont)  Vector-drawn (cont)  Vector images – use less memory space and have a smaller file size as compared to bitmaps  http://msauer.mvps.org/vector%20bitmap.htm  For the Web pages that use vector graphics in plug-ins download faster, when used for animation, draw faster than bitmaps 40

41 Representing Image (cont)  Vector-drawn (cont)  Not suitable for photorealistic images  Require a plug-in for Web-based display  Are scalable and resizable  Bitmaps can be converted to vector images using autotracing 41

42 A bitmap being scaled up 42 Vector graphics have the ability to preserve its shape without losing image quality when resized (scaled up)Vector graphics have the ability to preserve its shape without losing image quality when resized (scaled up) Because vector images do not store information about the image in pixels values… instead described using the mathematical formula that builds itBecause vector images do not store information about the image in pixels values… instead described using the mathematical formula that builds it

43 43 A vector being scaled up

44 Reproducing Colour on Computer  Natural Light and Colour  Light comes from an atom where an electron passes from a higher to a lower energy level Each atom produces uniquely specific colors  Color – frequency of a light wave within the narrow band of the electromagnetic spectrum, to which the human eye responds Produced by light of various wavelengths - when light strikes an object and reflects back to the eyes 44

45 Reproducing Colour on Computer (cont)  Colour  An element of art with three properties: hue or tint (the color name) intensity (purity and strength of a color) value (the lightness or darkness of a color)  Photographers measure color temperature in degrees Kelvin (K) 45 DescriptionDegrees Kelvin Clear Blue Sky8000 to 27,000 Rainy, Misty Daylight7200 to 8500

46 Reproducing Colour on Computer (cont)  Colour (cont)  Tools used to describe colour are different when the colour is printed than from when it is projected (monitor) Additive colour (projected colour) Subtractive colour (printed colour) Monitor-specific colour Colour models 46

47 Reproducing Colour on Computer (cont)  Additive Colour  Simply put… coloring by mixing lights!  Created by combining colored light sources in three primary colors - red, green, and blue (RGB)  TV and computer monitors 47

48 Reproducing Colour on Computer (cont)  Subtractive Colour  Colour is created by combining colored media such as paints or ink  The colored media absorb (or subtract) some parts of the color spectrum of light and reflect the others back to the eye 48

49 Reproducing Colour on Computer (cont)  Subtractive Colour (cont)  Subtractive color is the process used to create color in printing  The printed page consists of tiny halftone dots of three primary colors- cyan, magenta, and yellow (CMY) 49

50 50 Reproducing Colour on Computer (cont)

51  Monitor-specific colours  Colors should be used according to the target audience's monitor specifications  E.g. The preferred monitor resolution is 800x600 pixels This is however conservative based on today’s hardware capabilities  E.g. The preferred color depth is 32 bits 51

52 52

53 Reproducing Colour on Computer (cont)  Colour Models  Different ways of representing information about colour  Models used to specify colour in computer terms are: RGB 24-bit methodology where colour is specified in terms of Red, Green, and Blue Values ranging from 0 to 255 HSB and HSL Colour is specified as an angle from 0 to 360 degrees on a colour wheel Other models include CMYK, CIE, YIQ, YUV, and YCC 53

54 Reproducing Colour on Computer (cont)  Colour Models (cont) 54

55 55

56 Reproducing Colour on Computer (cont)  RGB  Add red, green and blue to create colors  Additive model  Assigns an intensity value to each pixel ranging from 0 (black) to 255 (white)  bright red color might have R 246, G 20, B 50 56

57 Reproducing Colour on Computer (cont)  RGB (cont) 57 Color RedGreenBlueHexadecimal Black 000#000000 White 255 #FFFFFF Red 25500#FF0000 Green 01920#00C000 Blue 00255#0000FF Yellow 255 0#FFFF00 http://kb.iu.edu/data/aetf.html

58 Reproducing Colour on Computer (cont)  HSB  Based on human perception of color,  3 fundamental properties of color: Hue Saturation (or chroma) Brightness - relative lightness or darkness of color, also measured as %  No HSB mode for creating or editing images 58

59 Reproducing Colour on Computer (cont)  HSB (cont)  Hue (H) – the color type (such as red, green)  Ranges from 0 to 360 degree red at 0 degree green at 120 degree blue at 240 degree and so on 59

60 Reproducing Colour on Computer (cont)  HSB (cont)  Saturation (S) – ranges from 0 to 100%  Called the "purity”  The lower the saturation of a color, the more "grayness" is present and the more faded the color will appear 60

61 Reproducing Colour on Computer (cont)  HSB (cont)  Brightness (B) – ranges from 0 to 100%  A nonlinear transformation of the RGB color space  Note that HSV and HSB are the same 61 Blackwhite 0%50%100%

62 Reproducing Colour on Computer (cont)  HSB (cont) 62

63 63

64 64

65 Reproducing Colour on Computer (cont)  CMYK  Based on light-absorbing quality of ink printed on paper  As light is absorbed, part of the spectrum is absorbed and part is reflected back to eyes  Associated with printing subtractive model  Four channels cyan (C) magenta (M) yellow (Y) black (K) [also called KEY] 65

66 Reproducing Colour on Computer (cont)  CMYK (cont) In theory, pure colors should produce black, but printing inks contain impurities, so this combination produces muddy brown K is needed to produce pure black, hence CMYK is four-color process printing http://www.december.com/html/spec/colorcmyk.html http://www.customtattoos.net/cmyk.pdf 66

67 When C-M-Y-K 67 Notice the non-black muddy brown in the middle http://math2033.uark.edu/wiki/images/8/88/Color2.jpg

68 Reproducing Colour on Computer (cont)  CMYK (cont) 68

69 Reproducing Colour on Computer (cont) 69 CMYK The four printing plates in actionThe four printing plates in action saturation of the CYAN platesaturation of the YELLOW platesaturation of the MAGENTA platesaturation of the BLACK plate +++ Reference: CSE5900 Introduction To Multimedia Computing by Daniel Thayer Eaves at Monash University, Caulfield, Australia

70 70 Reproducing Colour on Computer (cont) Printed result (approximately…)Printed result (approximately…) Reference: CSE5900 Introduction To Multimedia Computing by Daniel Thayer Eaves at Monash University, Caulfield, Australia

71 Reproducing Colour on Computer (cont)  Colour Palettes  Mathematical tables – define the colour of pixels displayed on the screen  Called ‘colour lookup tables’ or CLUTs on Macintosh  The most common palettes are 1, 4, 8, 16, and 24-bit deep 71

72 Reproducing Colour on Computer (cont)  Colour Palettes (cont)  Dithering Process whereby the colour value of each pixel is changed to the closest matching colour value in the target palette Done using a mathematical algorithm 72

73 73

74 74

75 Reproducing Colour on Computer (cont)  Colour Palettes (cont)  Dithering 75

76 Reproducing Colour on Computer (cont)  Image file used in Multimedia  Macintosh formats  Windows formats  Cross-platform formats 76

77 Reproducing Colour on Computer (cont)  Macintosh formats Most commonly used format is PICT PICT complicated and versatile format developed by Apple image application on the Macintosh can import or export PICT files In PICT file, both vector-drawn objects and bitmaps can reside side-by-side Operate in several color spaces (RGB, CMYK, Bitmap, Grayscale, Indexed Color) 77

78 Reproducing Colour on Computer (cont)  Windows format Commonly used image file format – DIB DIB – Device-Independent Bitmaps Default filename extension of a Windows DIB file is.BMP The preferred file type for multimedia developers in Windows is Resource Interchange File Format (RIFF) 78

79 Reproducing Colour on Computer (cont)  Windows format (cont) BMP A Windows bitmap file Native bitmap file format of the Microsoft Windows environment TIFF (Tagged Image File Format ) Used to exchange documents between different applications and platforms PCX - Used by MS-DOS paint software One of the oldest bitmapped formats popularized by MS-DOS paint programs that first appeared in the early 1980' s 79

80 Reproducing Colour on Computer (cont)  Cross-platform The image file formats that are compatible across platforms are: DXF - Used by CAD applications Initial Graphics Exchange Standard (IGS or IGES) - Standard for transferring CAD drawings JPEG and GIF – used formats on the Web 80

81 Storing Image  Graphics image can be saved in many file format  File formats – Codecs (compression and decompression)  File compression – allow to store the image data in smaller disk file 81

82 Storing Image 82  Popular image file formats  JPEG (Joint-Photographic Experts Group)  GIF (Graphical Interchange Format)  PNG (Portable Network Graphic)  Other formats: BMP, PSD, TIFF/TIF, TGA, EPS, PCX, ICO

83 Storing Image  JPEG (Joint Photographic Experts Group)  For continuous tone images, such as full-color photographs  Supports more than 16 million colors (24-bit)  Uses lossy compression (averaging may lose information) Lossy in a sense that you can lose data every time you save the image 83

84 84 Storing Image An example in Photoshop – Quality selection of JPEG when saving a JPEG file

85 85 A JPEG file saved at HIGH QUALITY (8-12) Storing Image

86 86 Storing Image A JPEG file saved at LOW QUALITY (0-4) – see the quality difference  This quality would be worse for higher color imagesThis quality would be worse for higher color images

87 Storing Image  GIF  Indexed color – not in your notes…  For large areas of the same color and a moderate level of detail.  Supports up to 256 colors  Allows transparency and interlacing  Also allows animation  Uses lossless compression Lossless in a sense that no matter how many times you save, no data loss will occur (unless you change the settings of course…) 87

88 Storing Image 88 1 of the color-values is used for transparency (as seen in the CLUT below)

89 Storing Images  A high quality JPEG (zoomed in) 89

90 90 Storing Images  Converted to GIF (zoomed in)

91 91 Storing Images  Side by side comparison (zoomed in some more)  Image quality degraded, since only 256 possible colors available in the palette JPEGGIF

92 92 An image of a Macaw and its color lookup table (http://en.wikipedia.org/wiki/Indexed_color)

93 Drawbacks of indexed color images 93 http://en.wikipedia.org/wiki/Indexed_color

94 Storing Images 94 Animated GIF (Won’t work if you’re reading this on paper) An animated GIF is a sequence of GIF files all bonded together and displayed one after the other

95 Storing Image  PNG  lossless, portable, well-compressed storage of raster images  patent-free replacement for GIF  Support indexed-color, grayscale, and true color images + an optional alpha channel for transparency  also replace many common uses of TIFF… and GIF 95

96 A webpage to look at for lossy vs lossless compression  http://newsgroup.xnview.com/viewtopic.php?t=2081 96

97 Digitizing Image  Image source  People learn and retain more information from pictures  Pictures or images can be retained in many sources: Photos Available on CD-Rom – Photo CDs Photo CDs is classified by topics and can be used as background or icons Photo taken from digital still cameras and still video 97

98 Digitizing Image (cont) Clip Art Includes clip photos, video clips, and animation clips Free or payable Good sources Corel’s Professional Photos CD-ROM series Scanners Quite popular for capturing images from hardcopy resources Operate in similar fashion to photocopy machine – image is electronically captured with an array of light sensors 98

99 Digitizing Image (cont) Digital Cameras Capture image in digital format and able to generate graphic Quick and easy method – can transfer image into a computer using a special cable Video Image Pictures from video source such as video tape video camera or digital video camera can be transferred into a computer Some companies are expert in selling video footage 99

100 Digitizing Image (cont) The Web provides a vast source of images and content simply right-click it and save (Windows) hold down the mouse key for a second, select the Save Image option (Macintosh) BUT! Don’t simply save… make sure the images are not copyright protected… or get permission from the image owner first Your mobile phone’s camera Normally sub-par to dedicated digital cameras High megapixel cameras however produce good quality images Memory card extensions also make it easier to store more images 100

101 Information Delivery  Images or Graphics  used to convey information in multimedia products  example, a picture of an automobile engine is much more effective than text that merely describes it 101

102 Information Delivery (cont)  Images or Graphics for information delivery  Drawn images  Charts and graphs  Maps  Scenery  People 102

103 Information Delivery (cont)  Image must be relevant to the overall product  Image size, color in respect to the application and other images, and positioning must all be considered when using images 103

104 Information Delivery (cont) 104

105 Summary  Bitmaps and vector-drawn are still images  Images incorporated in multimedia using clip arts, bitmap software, capturing, editing or scanning  Colour is one of the most vital components of multimedia 105


Download ppt "LECTURE 5: DIGITAL IMAGE TECHNOLOGY EVI INDRIASARI MANSOR Tel ext: 1741 1."

Similar presentations


Ads by Google