1 / 13

Computer Systems

Computer Systems. Nat 5 Computing Science Data Representation Lesson 4b: Storing Graphics EXTENSION. Lesson Aims. Pupils at National 5 level will be able to: Describe how a vector image is stored Calculate the storage requirements of a bitmap image with colours

latika
Télécharger la présentation

Computer Systems

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. Computer Systems Nat 5 Computing Science Data Representation Lesson 4b: Storing Graphics EXTENSION

  2. Lesson Aims • Pupils at National 5 levelwill be able to: • Describe how a vector image is stored • Calculate the storage requirements of a bitmap image with colours • Explain the difference between a vector and bitmap image • Explain the advantages and disadvantages of bitmap images compared to vector images

  3. Nat 5 Vector Graphics • This image is an example of a vector image. • A vector image is made up of lots of overlapping shapes • Each of the shapes can be edited separately from the other shapes.

  4. Nat 5 Vector Graphics • A vector image is stored using a different method than bitmapped images • The attributes (or qualities) of each shape are stored. • EG, the eyes(ellipses) may be stored as: • Centre X/Y-co-ordinates • Fill Colour • Border Style • Border Colour etc…

  5. National 5 Storing Colour Bitmaps • Storing a colour bitmap is exactly the same as for black and white with one difference - Each pixel is not just black and white but can represent a variety of colours. • This is done by allocating more than one bit for each pixel: • 2 bits/pixel = 4 colours • 4 bits/pixel = 16 colours • 6 bits/pixel = 64 colours

  6. National 5 Colour Bitmaps • The amount of bits allocated to each pixel is known as the bit depth. • So an image with 8 bit colour depth could have 256 colours [28 = 256] • True Colour is defined as an image with 24 bit colour depth. It has 16,777,216 colours! [224 = 16,777,216]

  7. National 5 True Colour • True Colour is defined as an image with 24 bit bit depth. • The colour code for each pixel is constructed of a single 8 bit number for each of the main 3 additive colours. • Red, GreenandBlue RGB Colour Codes

  8. National 5 Increasing Bit Depth

  9. National 5 Storage Space Example A true colour image is 800 pixels by 900 pixels. Calculate the storage requirements and express the answer in appropriate units • Step 1: (Length x Breadth) * bit depth • (800 * 900) * 24 bits = 17,280,000 bits • Step 2: Convert into appropriate units • 17,280,000/8 = 2,160,000 bytes • 2,160,000 bytes /1024 = 2,109.375 KB • 2,109.375 Kb/1024 = 2.06 MB

  10. National 5 Storage Space: Example 2 • A 16 bit colour image is 4 inches by 6 inches with a resolution of 300dpi. • Step 1: (Length x dpi) x (Breadth x dpi) • (4*300) * (6*300)= 2,160,000 pixels • Step 2: number of pixels * bit depth • 2,160,000 * 16 = 34,560,000 bits • Step 3: Convert into appropriate units • 34,560,000 /8 = 4,320,000 bytes • 4,320,000 bytes /1024 = 4,218.75KB • 4,218.75KB /1024 = 4.119 MB

  11. National 5 Bitmap Graphics – Pros and Cons Advantages Disadvantages Requires large storage space Image becomes jagged when scaled • Can be manipulated at pixel level • Can create a wide array of graphic effects • Can represent photo-realistic images

  12. National 5 Vector Graphics – Pros and Cons Advantages Disadvantages Cannot be edited at pixel level Cannot show photo realistic scenes Will usually require particular applications to open • Do not lose quality when scaled • Require less storage space • Objects are easily moved/manipulated • Resolution independent

  13. Tasks National 4 National 5 Worksheet 4A and 4B • Worksheet 4

More Related