3.2: data representation Flashcards
how is text represented
represented by using a character set
ASCII
an example of a character set
can represent most letters, numbers and symbols by using only 1 byte
extended ASCII
first 128 values same as ASCII
ASCII but with more characters
unicode
limited to 256 characters
only useful in countries that have adopted the latin alphabet
includes technical symbols, punctuation and other characters
how many characters in unicode limited to
256
how are images represented
binary code is used to represent photographs and other images using bitmap
bitmap image
consists of a grid of squares called pixels
each pixel has its own position in the grid
each pixel is a single colour
what is used to represent the colour of a pixel
binary code
colour depth
the number of bits used to store each pixel’s colour
the greater the colour depth the more colours can be represented
3 colour depths
8-bit gradient
8-bit gradient, dithered
24-bit gradient
colours
combinations of: red, green and blue
any colour can be encoded as a set of 3 numbers
true colour
allocates 1 byte for red 1 byte for green and 1 byte for blue
this has a 24-bit colour depth( 3*8 = 24)
image resolution
clarity of an image
when you zoom into a bitmap image the pixels are streched so the quality is poor when you zoom in too much
how is image resolution expressed
the number of pixels that an image contains per inch
example: 300 ppi (pixels per inch)
image resolution (size of bitmapped graphic )
the size in pixels
width(in pixels) * height(in pixels)