Graphics or Images.ppt

Embed Size (px)

Citation preview

  • 8/10/2019 Graphics or Images.ppt

    1/48

    Graphics & Images

  • 8/10/2019 Graphics or Images.ppt

    2/48

    Introduction

    Imageis a partial representation of an object or ascene. (image of a person, place, object)

    Graphicis a broader and general denition which

    includes: Pictures or Photographs

    Drawings or Line arts

    lip arts

    !uttons and !anner harts and graphs

    !ac"grounds

    #cons

  • 8/10/2019 Graphics or Images.ppt

    3/48

    Types of Graphic

    !itmap graphics

    $ector graphics

  • 8/10/2019 Graphics or Images.ppt

    4/48

    Bitmap graphics

    %he most common and comprehensi&e form of

    storage for images on computers is bitmapimage.

    !itmap use combination bloc"s of di'erent

    colours ("nown as pixels) to represent animage. ach piel is assigned a speciclocation and colour &alue.

    %here are also called pixelized or rastergraphics.

  • 8/10/2019 Graphics or Images.ppt

    5/48

    Bitmap graphics

    !itmaps * arra+ of dots or piels

    olor depth per piel

    igh -ualit+ pictures

    Photo realistic

    Larger than drawt+pe

    /ile si0e 1 piels color depth 2 3

    4oftware to edit bitmapped graphics are :

    5dobe Photoshop

    Paint 4hop Pro

  • 8/10/2019 Graphics or Images.ppt

    6/48

    Bitmap graphics

    Advantage

    an ha&e di'erenttetures on thedrawings6 detailed andcomprehensi&e.

    Disadvantage Large le si0e.

    7ot eas+ to ma"emodication toobjects2drawings.

    8raphics become9bloc"+9 when the si0eis increased.

  • 8/10/2019 Graphics or Images.ppt

    7/48

    Vector Graphics

    $ector images are based on drawing

    elements2objects to create an image.

    %he elements and objects are stored as a series ofcommand that dene the indi&idual objects.

    Pac"ages that allow to create &ector graphicsinclude :

    acromedia /reehand ;

    acromedia /lash ;

    5dobe #llustrator

    orel Draw

  • 8/10/2019 Graphics or Images.ppt

    8/48

    Vector Graphics

    Draw t+pe

    8eometric shape stored as set of instructions

    4maller than bitmap

  • 8/10/2019 Graphics or Images.ppt

    9/48

    Vector Graphics

    Advantage

    4mall le si0e. aintain -ualit+ as the

    si0e of the graphics isincreased.

    as+ to edit the

    drawings as each objectis independent of theother.

    Disadvantage

    =bjects2drawings cannotha&e teture6 it can onl+ha&e plain colours orgradients 6 limited le&elof detail that can bepresented in an image.

  • 8/10/2019 Graphics or Images.ppt

    10/48

    Resolution

    %here are three t+pes of resolution measuring di'erent aspects of the-ualit+, detail and si0e of an image:

    Colour resolution Image resolution Display resolution

    Image Resolution:%he term resolution often associated with an images degree ofdetail or quality.

    Display Resolution:

  • 8/10/2019 Graphics or Images.ppt

    11/48

    Image resolution

    #mage resolution measures the piel dimension

    of an o&erall image or how man+ piel theimage has.

    #mage resolution is measured in width and

    height.

    /or eample, >?? @ >??piel image has a totalof >?,??? piels.

  • 8/10/2019 Graphics or Images.ppt

    12/48

    Display resolution

    Displa+ resolution is also measured in piels in terms of

    height and width.

    #t simpl+ means how man+ piels can be displa+ed onthe computer screen.

    Displa+ resolution normall+ uses a setting ofAB?B3?($85), 3??A?? (4$85), >?CBA3, etc.

    Eou can change the displa+ resolution under Displa+Properties in ontrol panel.

    #f +our image resolution is bigger than the displa+resolution, the result would be part of the image will beout of the displa+ area.

  • 8/10/2019 Graphics or Images.ppt

    13/48

    Memory/Storage requirement

    /actors to consider:

    %he height of the graphics

    %he width of the graphics

    %he colour depth or bit depth

    %he le si0e of a bitmap image (in b+tes):

    %eight & 'idth & !Colour depth $ ("

  • 8/10/2019 Graphics or Images.ppt

    14/48

    olour Resolution/olour Depth

    ach piel can represent at least C possible

    colours or more. olour resolution or olour depth2channel depth

    is measured in bits.

    Colour Depth Calculation )umer of Colours

    > bitB bits3 bits (> b+te)>A bits (C

    b+tes)CB bits (F

    b+tes)

    C> 1 CCB1 >AC31 CGAC>A1 AG,GFACCB1 >A,,C>A

    C colours>A coloursCGA coloursAG,GFA colours>A,,C>A colours

  • 8/10/2019 Graphics or Images.ppt

    15/48

    Binary !Bitonal" Image

    %hese images ha&e two possible

    &alues of piel intensities: blac" andwhite.

    5lso called >bit monochrome image,since it contains onl+ blac" andwhite.

    %+pical applications of bitonalimages include oHce2businessdocuments, handwritten tet, linegraphics, engineering graphics etc.

    %he scanned output contains ase-uence of blac" or white piels.!inar+ > represents a blac" piel andbinar+ ? represents a white piel.

  • 8/10/2019 Graphics or Images.ppt

    16/48

    Grayscale Image

    %he+ contain se&eral shades of

    gre+.

    %+pical applications of gra+scaleimages include newspaperphotographs (noncolor), magneticresonance images and catscans.

    5n uncompressed gra+scale imagecan be represented b+ n bits perpiel, so the number of gra+ le&elssupported will be Cn.

    /or eample, 3bit 8ra+scale #mage.#t consists of CGA gra+ le&els. 5 dar"piel might ha&e a piel &alue of ?,a bright one might be CGG.

  • 8/10/2019 Graphics or Images.ppt

    17/48

    olour Image

    %he+ are characteri0ed b+ the

    intensit+ of three primar+colours (A,,C>A (CCB) possiblecolours. #n other words, 3 bitsfor Adi'erent colours.

  • 8/10/2019 Graphics or Images.ppt

    18/48

    RGB# / $%'it images

    5n important point: man+ CBbit colour images

    are actuall+ stored as FCbit images, with theetra b+te of data for each.

    5llows

  • 8/10/2019 Graphics or Images.ppt

    19/48

    Image olour Schemes

  • 8/10/2019 Graphics or Images.ppt

    20/48

    Various olour Schemes

    4e&eral colour schemes (also called colour space,

    models or formats) ha&e been de&eloped torepresent colour mathematicall+.

    %here are B commonl+ used colour schemes :

  • 8/10/2019 Graphics or Images.ppt

    21/48

    (" RGB olour Scheme

    olours are represented b+

    a numeric triplet specif+ing

  • 8/10/2019 Graphics or Images.ppt

    22/48

    %" M)/M)* olour Scheme

    CMYK(+an,agenta,Eellow,!lac") scheme is widel+ used

    for colour printing. %o print a particular colour on a whitepage, one must appl+ in"s that subtract (absorb) all coloursother than the one desired.

    +an, magenta, and +ellow are the subtracti&e primaries and

    are the complements of red, green and blue. olour isspecied b+ what is subtracted from white light (which is thesum of

  • 8/10/2019 Graphics or Images.ppt

    23/48

    M)/M)* olour Scheme

    %heoreticall+, if +an, agenta, and Eellow are

    mied, then all the

  • 8/10/2019 Graphics or Images.ppt

    24/48

    #dditi+e Mi,ing

    Mhite Light : #t consists of energ+ throughout the &isible

    light spectrum.

    Primar+ colours :

  • 8/10/2019 Graphics or Images.ppt

    25/48

    *econdary colours: +an, agenta and Eellow (CMY)are secondar+ colours or subtracti&e primar+ colours.

    *utractive +ixing: 4ubtracti&e colour miing is basedon reNecti&e colours rather than emissi&e colours.

    #t generates colour b+ miing secondar+ colours. /oreample, miing magenta and +ellow +ields red.

    #n subtracti&e miing, unwanted colours are selecti&el+absorbed and the re-uired colour is reNected. %he +ellowcolour absorbs the blue component, and the magenta

    absorbs the green component, resulting in red.

    4ubtracti&e miing is used primaril+ in the printingindustr+, b+ printing the three subtracti&e colours indi'ering proportions on white paper can generate all thecolours in the spectrum.

    Su'tracti+e Mi,ing

  • 8/10/2019 Graphics or Images.ppt

    26/48

    #dditi+e and Su'tracti+e Mi,ing

    Cyan

    Blue Magenta

    YellowGreen

    RedBlack

    White

    Additive Colour Mixing Subtractive Colour Mixing

    R

    GB

    M

    C

    Y

    W

  • 8/10/2019 Graphics or Images.ppt

    27/48

    $" -SB/-SI olour Scheme

    omputer monitors displa+ colours b+ emitting colour dots (red,

    green, blue).

    reation of colour is based on function of three characteristics:

    O hue, saturation rightness2 lightness. !%*, $ %*-"

    olours are represented b+ a triplet representing hue (hue isdominant colour of a sample and is represented b+ an angular&alue &ar+ing from red to green to blue at >C?Q inter&als),saturation (purit+ of the colour) and brightness (luminance, orintensit+ of the colour).

  • 8/10/2019 Graphics or Images.ppt

    28/48

    -SB/-SI olour Scheme

    %ue:#t is the colour sensation produced in an obser&er due to the presenceof certain wa&elengths of colour. ach wa&elength presents a di'erenthue. ue is based on a &ector &alue mo&ing from ? to FA? degrees ona colour wheel.

    *aturation:

    %his is a measure of colour intensit+, for eample, the di'erencebetween red and pin". 5lthough the two colours ha&e the samepredominant wa&elength, one ma+ ha&e more white colour mied inwith it and hence appear less saturated. (>??R 1 pure colour, ?R 1blac", white , gra+)

    Intensity $ -uminance or ,rightness :

    %his is a measure of the light emitted or reNected b+ an object.ertain colours appear brighter than others as the human e+e doesnot respond in the same wa+ to all colours. %he human e+es see nerdetails in image scene more because of brightness &ariations thanbecause of colour &ariations.

  • 8/10/2019 Graphics or Images.ppt

    29/48

    ." )V olour Scheme

    %his is the basic colour format used b+composite colour %$ standards (7%4, P5Land 45).

    . represents the luminance2brightness andcan be thought of as containing blac" andwhite or gra+scale information.

    / and 0carr+ the chrominance or colourinformation. %here are a &ariet+ of E$li"ecolour models.

    %he ad&antage of using E$ for broadcast

    is that the amount of data needed to denea tele&ision picture is greatl+ reduced.

    %he disad&antage is that man+ colours thatappear on a computer displa+ cannot berecreated on %$.

  • 8/10/2019 Graphics or Images.ppt

    30/48

    olour Dithering

    suall+, digitised images are CB bit, >Amillion colour depth.

    #f displa+ s+stem is limited to less than>A million colours, the image must betransformed for displa+ in the lessercolour en&ironment (colour dithering).

    Colour Dithering * the processthrough which colours are changed tomeet the closest a&ailable colourbased on the a&ailable palette.

    olours are substituted with closest

    a&ailable colours (output de&ice).

    %he -ualit+ of dithering will depend onthe algorithm used to select theclosest colour.

  • 8/10/2019 Graphics or Images.ppt

    31/48

    Image 0rocessing

  • 8/10/2019 Graphics or Images.ppt

    32/48

    Image 0rocessing

    5nal+0ing and manipulating images with a

    computer. #mage processing generallyinvolves three steps:

    >. #mport an image with an optical scanner or directl+

    through digital photograph+.

    C. anipulate or anal+0e the image in some wa+. %hisstage can include image enhancement and datacompression.

    F. =utput the result. %he result might be the imagealtered in some wa+.

  • 8/10/2019 Graphics or Images.ppt

    33/48

    Image 0rocessing Techniques

    #mage processing operations ma+ operate directl+ on piel

    data or on higher le&el features such as edges, surfaces,and &olumes.

    #mage processing operations ma+ be roughl+ di&ided intosi categories.

    1 2diting

    1 3oint operations

    1 4iltering

    1 Compositing

    1 Geometric transformations

    1 Conversions

    4upport for a &ariet+ of image operations is now becominga&ailable in page la+out and paint programs (such asPhotoshop).

  • 8/10/2019 Graphics or Images.ppt

    34/48

    (" 1diting

    %he most basic operation is changing

    individual pixels#

    #mage editors also support cutting, cop+ing, andpasting selected groups of piel. 5 selection

    might be a simple rectangular subimage or anarbitraril+ shaped region.

    4elections are either drawn b+ the user or

    calculated b+ software (for instance, b+eamining colour di'erences betweenneighboring piels).

  • 8/10/2019 Graphics or Images.ppt

    35/48

    %" 0oint 2perations

    5 point operation consists of appl+ing a functionto e&er+ pielin an image (or selection).

    %he function is such that in calculating a new piel &alue, the onl+image data used is the pixels current value and exclude theneighoring pixels#

    amples include:

    5hresholding:5 piel is set to > or ? depending uponwhether it is abo&e or below the threshold &alue. %his createsmonochrome (binar+) images which are often used as mas"swhen compositing6.

    @ Compositing: creating ne7 images or moving images ycomining images from di8erent sources 9 lie real1 7orlddigital video; 1D animations;painted acdrops; digital still photographs; and text#

    colour correction:5n image ma+ be modied to increase orreduce contrast, brightness, and to strengthen or wea"enparticular colours.

  • 8/10/2019 Graphics or Images.ppt

    36/48

    $" 3iltering

    /ilter operations, li"e point operation, in&ol&e

    appl+ing a function to e&er+ piel in an image orselection.

    %he function determines a pixels ne7 value

    ased on its current value and that ofneighoring pixels#

    Depending on the denition of the function,

    ltering is used to blur or sharpen the image,introduce distortions, and produce a &ariet+ ofspecial e'ects.

  • 8/10/2019 Graphics or Images.ppt

    37/48

    ." ompositing

    #mage compositing is the combination of two or

    more images to produce a new image.

    5lpha channels are fre-uentl+ used to controlblending and mas"ing.

    #n general, compositing is specied b+mathematical relationship between the &ariousimages. /or instance one image might be

    produced from the sum of two eisting images.

    5 &er+ large &ariet+ of e'ects are possible.

  • 8/10/2019 Graphics or Images.ppt

    38/48

    4" Geometric Transformations

    !asic geometric transformations include

    displacing, rotating, mirroring, and scaling animage.

    =ther geometric transformations include

    s"ewing (slanting) and warping (an eample ofwarping is mapping a rectangular selection toan arbitrar+ foursided pol+gon)

  • 8/10/2019 Graphics or Images.ppt

    39/48

    5" on+ersions

    Mith the &ariet+ of image formats a&ailable, there is

    a fre-uent need to con&ert from one format toanother.

    /ortunatel+, there are a number of public domainsoftware pac"ages which handle man+ format

    con&ersion tas"s. #n addition, image processingsoftware will usuall+ import and eport images in anumber of formats.

    !esides format conversion, there are other

    operations that can be considered forms ofcon&ersion. %hese include image compression ordecompression; changing colour schemes !ormodels" and changing image depth orresolution#

    G hi 3il f t

  • 8/10/2019 Graphics or Images.ppt

    40/48

    Due to the number of choices a&ailable in

    determining image representation, it is notsurprising that a number of image formatsha&e e&ol&ed. 4ome eamples of imagele formats used for storing images are

    GI4(8raphics #nterchange /ormat)

    ,itmap

    3ost*cript

    ?32G

    5I44(%agged #mage /ile /ormat)

    5GA (often called %arga)

    3)G, and etc.

    Graphic 3ile formats

  • 8/10/2019 Graphics or Images.ppt

    41/48

    Graphics Interchange 3ormat !GI3"

    3bit per piel, bitmap image format commonl+ used b+ the worldwide web

    ses lossless compression technique

    ompress line art well

    #mage can ha&e transparent portion

    #nterlaced images possible

    5nimation possible (Sasc 5nimation 4hop )

    an onl+ ha&e a maimum of CGA colours

    Does not compress photographs well

    op+righted format such that de&elopers must pa+ ro+alt+

  • 8/10/2019 Graphics or Images.ppt

    42/48

    6indo7s Bitmap !BM0"

    !itmapped 8raphics /ormat

    ost common format containing piel b+ piel &alue

    Platform independent

    4upport up to CBbit colour depth

    7o compression

    5 FCbit &ersion with integrated alpha channel has beenintroduced with Mindows ;P. (support transparenc+)

    7o animation

  • 8/10/2019 Graphics or Images.ppt

    43/48

    8oint 0hotographic 1,pert Group !801G"

    ommonl+ used standard method of compression forphotographic images

    4upport a maimum of >A. million colours

    ompresses photographs well

    Possible to select compression ratio &ersus -ualit+

    Progressi&e (interlaced) images possible

    -ossy compression technique:Losses some image information

    Degradation of image possible with repeated editing and sa&ing

    7o transparenc+

    7o animation

  • 8/10/2019 Graphics or Images.ppt

    44/48

    0orta'le 9et7or: Graphic !09G"

    7o colour information lost

    an use all colour depth supports more than >A.million colours

    ompresses well Lossless ompression %echni-ue

    #mage can ha&e transparent portion

    7o animation

  • 8/10/2019 Graphics or Images.ppt

    45/48

    2ther Graphic 3ile formats RA' Graphics 4ile 4ormat (.raw)

    5 Neible basic le format for transferring les between

    applications and computer platforms. %his format consists ofa stream of b+tes describing the colour information in the le.

    5agged Image 4ile 4ormat(.tif, .ti')%#// is mainl+ used for echanging documents betweendi'erent applications and di'erent computer platforms. #t

    supports the LTM method compression for image t+pes.

    5ruevision 5arga(.tga)De&eloped b+ %rue&ision #nc. %85 les is a le format that willsupport images suitable for displa+ on %arga hardware but issupported b+ man+ applications on a wide range of platforms.

    @ *oft 3aintrush (.pc)!itmap graphics le format, originall+ de&eloped b+ T4oft foruse with PPaintbrush. %his le format is now used andgenerated b+ man+ applications and scanners.

  • 8/10/2019 Graphics or Images.ppt

    46/48

    2MM29 V1T2R 32RM#TS

    5dobe #llustrator le (.ai) =

  • 8/10/2019 Graphics or Images.ppt

    47/48

    Summary

    >. %+pes of graphics

    bitmap graphic &ector graphic

    C.

  • 8/10/2019 Graphics or Images.ppt

    48/48

    Summary

    G. #mage colour schemes