multimedia contents multimedia graphics / pictures audio / sound video

44
Multimedia Contents Multimedia Graphics / Pictures Audio / Sound Video

Upload: loraine-carson

Post on 23-Dec-2015

226 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Multimedia

ContentsMultimediaGraphics / PicturesAudio / SoundVideo

Page 2: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Multimedia

Multimedia is: SoundGraphicsVideos

Multimedia applicationsOffice documentsWebpage contentMoviesMusicPictures

Page 3: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Multimedia

Multimedia files are quite large Use compression to reduce file sizes

Lossless Compression – algorithms reduce size of files○ No information is lost

Lossy Compression – algorithm reduces size of files○ Some information is lost

Page 4: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Multimedia

Trade offs between lossless and lossy compressionLossy can reduce file sizes much more

Example: File compression like 7-zipUses lossless compressionIf some data is lost, then file becomes

corruptedLossy compression is used in multimedia

Page 5: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Multimedia

Example: 38.56666666

Lossless compression38.56(7)

Lossy compression38.6

Page 6: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

GraphicsBitmap (BMP) - windowsGraphics Interchange Format (GIF)Joint Photographic Experts Group (JPEG)Tagged Image File Format (TIFF)Portable Network Graphics (PNG)

Note – the abbreviations are the file extensions

Page 7: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

Digitizing Images Bit Map – each image is laid out in a grid pattern Pixel - each cell in the image

Pixel could be black or whiteGrey scale valueColor

The more pixels, the better the image quality Digital cameras – megapixels

My camera is 14.1 megapixelsEach picture has 14.1 million cells that compose the

pictures

Page 8: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

Bitmap of a snowman

Grey Scale Bit Map Image The snowman face is a 7x7

bitmap Composed of 15, 15,  0, 0, 0,

15, 15, 15, 15,  0, 0, 0, 15, 15, 15, 0, 0, 0, 0, 0, 15, 7, 15, 3, 15, 3, 15, 7, 7, 15, 15, 7, 15, 15, 7, 7, 15, 3, 3, 3, 15, 7, 15, 7, 7, 7, 7, 7, 15

The file also contains a header containing the size of the bitmap which is 7 x 7

Page 9: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics Color Bit Map Image The top photograph is a

picture with birds flying in the sky

The bottom picture is one bird blown up to show pixels

Page 10: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / GraphicsRGB (Red-Green-Blue) All digital images are composed of red, green and

blue Usually represented by hexadecimal numbers

24 = 16; Numbers – 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, and F

Example: HTML commandbgcolor =“#0F69F3”bgcolor is background colorRed = 0F, Green = 69, and Blue = F3

Page 11: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

RBG can make the other colors

Each color has two hexademical digits or 00 – FF, which ranges from 0 to 255

Each color is 28 and three colors 28 28 28 =224

24-bit true color We also have 32-bit color

Page 12: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

Windows BitMap Bitmaps do not use compression Bitmaps have very large file sizes

Easy to calculate the file size

Image is 800 x 600 with 8 bit (1 byte) color256 color values

Page 13: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics Calculating Image File Size (BitMap) Number of pixels = 800 x 600 = 480,000

pixels Image size = number of pixels  x number

of bitsImage size = 480,000 pixels x 1 byte =

480,000 bytesImage size = 480,000 / 1024 = 468.75

KBytes

Page 14: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

Graphics Interchange Format (GIF) Moderately compresses images

Lossless compression (simple pictures) Good for simple pictures and graphics

Displays 256 colours or 8 bit Palette – it chooses the best 256 colors out of 24-

bit color

Common for websites Animated GIFs – images can display simple

animation, especially for websites

Page 15: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

The animated GIF shows a four cycle gasoline engine

Requires special software to create animated GIFs

File size 369 kb

Page 16: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

Joint Picture Experts Group (JPEG) JPEG uses complex mathematical compression

Reduces file size up to ten times that of GIF Causes lossy compression Supports True Color - 24 bit color

JPEG is great for photographs Used on websites

Page 17: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics Note

If the same JPEG image is re-edited, then the image can degrade

If you have photos that are never edited, then leave them in JPEG

If you re-edit the same photographs, then keep photo in another format ○ PNG is good; file compression○ BMP is okay if you have the space; no compression

Page 18: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

Tuzla, Bosnia

Picture is 858x643 True color, 32 bit or 4

bytes Bitmap = 2.2 MB

I converted this to BMP and it was 2.1 MB

Page 19: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

JPEG (20%) – very small file size; 34 k

JPEG (95%) – medium size; 212 k

Page 20: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics Portable Network Graphics (PNG)

Uses loseless data compressionUses 24-bit or 32-bit colorCan be used for webpages

Note: 32-bit color is RBGA○ A is for alpha○ Alpha allows translucent pictures○ 50% alpha – can see images behind the picture

Windows Aero effects

Page 21: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

Creating digital picturesScanning – digitizing an image using a

scannerDigital camerasPaint programsScreen capture – use prtsc to capture a

screen

Page 22: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics

Software Create pictures by hand

Microsoft Paint – comes with WindowsPaint,net - free

Enhance photographsMicrosoft Picture EditorGoogle PicassoPaint.net

Professional SoftwareAdobe PhotoshopAdobe IllustratorAdobe Pagemaker

Page 23: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics Conclusion

For websites○ JPEG○ GIF○ PNG○ Cannot use BMP or TIFF; too large

Page 24: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Pictures / Graphics Conclusion

No compression○ BMP○ TIFF

Lossless compression○ GIF○ PNG

Lossy compression○ JPEG

Page 25: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Audio / Sound Data is processed in two ways: analog or

digital

People generally process analog data that is continuous wave patterns.

Everything we see and hear is transmitted to our eyes and ears as light and sound waves. We are equipped with analog receptors

A computer is digitalTwo discrete states: on (or 1) and off (or 0).

Page 26: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Audio / Sound

Analog and digital signals

Computers: Analog to digital

converters Convert analog to digital

○ Microphone

Digital to analog converters Convert digital to analog

○ CD, MP3, etc.

Page 27: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Audio / Sound

Sound cards and Modems are digital- to-analog and analog-to-digital signal converters

The Wave file (.wav) – used in PCs. Windows systems sounds

○ Start up sound○ Many game sounds

Wave files do not use compressionFiles are quite large

Page 28: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Audio / Sound Wave file is created by

Sampling sound – convertor samples the sound so many times per second

CD quality is 44,100 samples per second Less sampling is lower quality

Sound information is stored as bits Commonly 8, 16, or 32 bit sound file

Sampling – how often a sound file is read

Bitrate – how much information is stored per second Includes magnitude Includes how often sound is sampled

Page 29: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Audio / Sound

Page 30: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Audio / Sound MP3 (MPEG-1 Audio Layer 3) MP3 compresses sound information

Uses lossy compressionSome information is lost

Example: 128 kbits per secondReduces the file size of CD sound quality by 11 timesGood for webpages, because file sizes are

small Note – many audio sound formats exist;

usually for movie files

Page 31: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Audio / Sound

Audio Software Audio Editing Software lets users modify

audio clips and produce studio quality sound tracks.Contains equalizers, controls, etc to modify clips

Rippers – converts audio to different formats

Windows 7 contains a music CD to MP3 ripper

Page 32: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos

More complex Has RGB color and sound RGB is Red-Green-Blue

Video has three colors and a sound

Stream – picture and sound change over time

Requires much more information

Page 33: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos

Frame – the dimensions of a video in pixelsWidth x heightExample: 320x120

Each picture has color24-bit color

Picture changes each secondCalled bit rateBit rate 25 frames per second

Page 34: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos

Our video is one hour (or 3600 seconds) File size = (frame)(color)(bit rate)(time)

= 320*120*24*25*3600 = 82 Giga bits= 10.4 GB

Video files are always compressedMost use lossy compression

○ Use compression to reduce size of the image of a frame

○ Use compression to reduce the bit rate

Page 35: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos

Frame – dimensions of the videoSmall videos can be blown up

Bit rate Important for video qualityThe higher the bit rate, the higher the qualityVideos – fast motion requires a higher bit

rate Example – vastly simplified

Page 36: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos

An example of a video compression Uses three frames

I-frame: The true pictureP-frame: predict which pixels changeB-frame: uses difference between the next

frame and previous frame

Page 37: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos

Compressor-decompressor (CODEC) – a program that encodes or decodes a streaming fileStreaming file is video and/or audio

Companies hold patents or copyrights for their codecsRestrictions apply

Page 38: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos

Video filesmp4 Matroska (mkv) Windows (avi)Windows (wmv)Flash video (flv)

Files are containers (not codec)A variety of codecs are used which are in

the fileMPEG2 is a codec

○ Used for DVDs

Page 39: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos Some codecs are open source Windows pays for the rights

Some codecs play in MediaPlayer

Users either useK-lite – a windows program that contains most

codecsVLC Player – media player that contains most

codecs

Software may be illegal in the United States

Page 40: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos

Linux is freeThey do not pay for rights to use codecsInstallers have to manually install codecs

Most distributions want to be legal, especially for businessesDistribution is a particular Linux operating

systemMost do not come with codecsForums teach people how to install codecs

Page 41: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos Ubuntu – install codes as software update

Manually install DVD codec via terminalBusinesses and companies can get into trouble

installing codecs without paying for themEngland

Linux Mint – comes with all codecs including DVDFrance

Page 42: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos

Video editing software - users can modify a segment of a video, called a clip.

Users canReorder sequence of clipsReduce length of clipAdd special effects to clipsAdd extra tracks to clip (eg. Sound, text captions)

Video Editing Software usually includes audio editing capabilities.

Page 43: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos

Video editing – requires a very fast computerExpensive programVirtualDub.org – free video editing

○ Powerful filters to clean video○ Had trouble encoding videos○ Files were much bigger

Page 44: Multimedia  Contents Multimedia Graphics / Pictures Audio / Sound Video

Videos

DVD ripping – the process of converting a DVD into a regular video fileConverting may or may not be illegal in the

U.S.Software may or not be illegal in the U.S.Windows – most programs were terribleLinux – AcidRip

○ Free simple program○ Majority of the time produced good quality

videos with good file sizes○ Linux tends to be faster than Windows