1 pixels & images

10
An image is a 2D array of pixels. An image is an array, or a matrix, of square pixels (picture elements) arranged in columns and rows. What Is An Image? and rows.

Upload: bhakti

Post on 14-Jul-2016

225 views

Category:

Documents


0 download

DESCRIPTION

lpk

TRANSCRIPT

Page 1: 1 Pixels & Images

• An image is a 2D array of pixels.

• An image is an array, or a matrix, of square

pixels (picture elements) arranged in columns

and rows.

What Is An Image?

and rows.

Page 2: 1 Pixels & Images

Pixel?

• A pixel is the smallest visual element on a

video display screen.

• PIX (for picture) + “EL" (for element).

Pixel's Of Image.

Page 3: 1 Pixels & Images

More On Pixels

• This example shows an image with a portion

greatly enlarged, in which the individual pixels

are rendered as little squares and can easily

be seen.be seen.

Page 4: 1 Pixels & Images

How is a pixel stored?

• Pixels are stored as Integers.

• The integers can be 8-bit, 24-bit or 32-bit

depending on the image type.

• Most popular are 24 bit color images where 8 • Most popular are 24 bit color images where 8

bits each for Red, Green And Blue color values

are used to represent a 24-bit pixel value.

• 8 bit images are grayscale images where as 32

bit images have an additional transparency

channel.

Page 5: 1 Pixels & Images

RGB Color Model

• The RGB color model is an additive color

model in which red, green, and blue color is

added together in various ways to reproduce a

broad array of colors.broad array of colors.

• In computing, the component values are often

stored as integer numbers in the range 0 to

255. These may be represented as either

decimal or hexadecimal numbers.

Page 6: 1 Pixels & Images

RGB Color Images

• Color images are composed

of three different channels

viz. Red, Green and Blue.

• One can also imagine three • One can also imagine three

overlapped 8-bit images to

compose a final 24-bit color

image.

Page 7: 1 Pixels & Images

RGB Color Example

• Sample PIXEL value in HEX = 0EDEB5

• In programming the hex numbers are

represented as 0x0EDEB5. 0x prefix is for hex

notation.notation.

• Then individual color channels:

• 0E (red) - DE (green)- B5 (blue)

• 00001110 – 11011110 – 10110101

• Actual Color Composed Will Be :

Page 8: 1 Pixels & Images

A Little Experiment

• Using Microsoft Paint try creating new color

compositions. See how individual values of R,

G and B can be used to form different colors.

Page 9: 1 Pixels & Images

Grayscale Image

• In a (8-bit) grayscale image each picture

element has an assigned intensity that ranges

from 0 to 255.

• A grey scale image is different from black and • A grey scale image is different from black and

white image since a grayscale image also

includes shades of grey apart from pure black

and pure white color.

• Grayscale images are usually required for

image processing.

Page 10: 1 Pixels & Images

Different Image Types

• COLOR – GRAYSCALE - BLACK & WHITE