SlideShare a Scribd company logo
HTML Graphics

HTML Graphics
1

What are the commonly used image file formats on the Web? Describe them.
The three most widely accepted image file formats on the Web are: .GIF, .JPG, and .PNG. All of the
formats compress the images to create smaller files that download much more quickly than the
original image.
GIF - Graphics Interchange Format
GIF uses a compression technique that preserves all of the color information for the image.
The .GIF format has an 8-bit color depth that allows for the use of 256 colors (as 28 = 256).
The fewer the number of colors that are used in a .GIF file, the greater the compression and the
smaller the file size.
The .GIF file is ideal for line art and color graphics because it is excellent at compressing and
displaying flat color areas.
It uses a simple compression algorithm.
Because of the color depth limitation, however, the .GIF format is limiting and should not be
used for photographs or complex graphics that have gradation in colour.
GIF Transparency:
With GIF files we can choose one color in an image to appear as transparent in the browser
The background color or pattern will show through the areas that we marks as transparent.
Using transparent areas allows us to create graphics that appear to have an irregular shape instead
of a rectangle.
GIF Animation
The .GIF format allows a designer to store multiple images and timing information about the
images in a single file.
This allows the creation of animations consisting of multiple static images that rotate, creating
the illusion of motion.
When creating a GIF animation, a designer can adjust the amount of time between frames and the
number of times that the animation plays.
GIF animation does not require browser plug-ins and does not have large download times.
Some of the tools through which we can create GIF animation are: ULead GIF Animator, and
Microsoft Liquid Motion.
Disadvantages of animated GIF images:
They only support 256 color palette.
They can only animate in browsers that support animated gifs.
They cannot be edited once they are encoded as an animated gif. If we edit animated GIF, we
will lose the animation sequence when it is saved.
JPG - Joint Photographic Experts Group (JPG or JPEG) image file format.
JPGs support millions of colors since they are 24-bit, so they are ideal for photographs or
continuous tone images.
JPGs use a lossy file compression technique that discards some colors, so there may be a loss of
quality from the original image.
The compression algorithm is more complex for JPG files.
When saving an image in .JPG format, a slider lets the designer choose the quality of the image.
The higher the compression, the smaller the size of the image file and the quicker the download
time, but the lower the image quality.
Images can be converted into JPG format using tools such as Adobe PhotoShop.
This format is not suitable for images with text and large blocks of solid color, and simple shapes
with crisp edges. This is because when the image is compressed the text, color or lines may blur
resulting in image that is not as sharp.

Prof. Mukesh N. Tekwani

Page 1 of 4
HTML Graphics

PNG - Portable Network Graphics format
This was specifically designed for use on the Web.
It has better compression rates than GIF images and therefore images are smaller in size.
It uses a compression technique that retains all of the color information, so it is not as efficient at
compressing image files as .JPG.
PNG supports 8-bit indexed-color, 16-bit grayscale, and 24-bit true color images.
PNG supports transparency and interlacing but not animation.
Certain browsers do not support PNG format.

2

What is interlacing and progressive displays?
We can save images in an interlaced or progressive format.
A low resolution image is shown first, followed by one or more passes that refine the image until
the full-resolution image is displayed. This is known as interlacing.
Both interlacing and progressive display formats gradually display an image in a pre-specified
number of passes as the data arrives in the browser.
The only advantage to saving images in these formats is that the user will see a blurred image
that gradually clears, giving them something to look at as it downloads.
The biggest disadvantage to saving an image in this format is browser support. Older browsers
may not display the image properly.

3

Which image format is the best for the Web?
GIFs should be used for simple colored graphics and line art.
The .GIF format can also be used for animation and transparency.
The .JPG format is best for 24-bit full-color photographic images and complex graphics.
The .PNG format can be used instead of GIFs, but all browsers do not support this format. PNG
does not replace JPGs since PNGs do not compress 24-bit images as well as .JPG.

4

Computer Color Basics:
Color depth is the amount of data used to create color on a display.
Dithering occurs when a browser comes across a color it does not support. The browser then
attempts to mix its own colors to create a similar color.
Banding refers to the effort to match the closest colors from the GIFs palette to the original colors in
a photo.

5

Discuss the IMG element

The <IMG> markup element is used to place graphics or images on a Web page. The <IMG>
element is an empty element, so it does not require a closing tag. The <IMG> element only needs the
SRC attribute to display an image in a browser. There are other attributes that can be used to select
how and where the image appears in the browser.
Attribute
Use
ALIGN
Specifies the position of the image in relation to the surrounding text.
Displays an alternate string of text instead of an image if the user has a text-only
ALT
browser or has graphics turned off. The ALT value is displayed as a pop-up
window when a mouse points to the image.
Determines whether a border appears on the image. State the border value in
BORDER
pixels. We can use this attribute to turn off the hypertext border if the image is a
link.
HEIGHT
Specifies the height of the image in pixels.
Specifies the amount of horizontal white space on the left and right sides of the
HSPACE
image in pixels.
The only required attribute, SRC specifies the URL of the graphic file you want to
SRC
display. As with any URL, the path must be relative to the HTML file. Image
mukeshtekwani@hotmail.com
Page 2 of 4
HTML Graphics

VSPACE
WIDTH

filenames are case-sensitive!
Specifies the amount of vertical white space on the top and bottom sides of the
image in pixels.
Specifies the width of the image in pixels.

ALIGN, BORDER, VSPACE, and HSPACE have been deprecated in HTML 4.0 in favor of CSS.
The table below shows the replacement attributes:
Deprecated
Attribute
ALIGN

BORDER
HEIGHT
HSPACE and
VSPACE

6

Equivalent CSS Property
FLOAT allows you to flow text around an image or other object.
Example:
IMG {FLOAT: LEFT}
BORDER lets you set a border on an image, or remove the border from a
linked image.
Specifies the height of the image in pixels.
The PADDING or MARGIN properties set white space around an image.
You can control individual sides of the image, or apply white space
around the entire image.

Write a note on background images.
The BACKGROUND attribute is used to tile images across the background of a Web page.
Any image can be used as a background image, but design principles need to be kept in mind
when using images in the background.
Complex backgrounds can confuse and distract the user.
Dark or complex backgrounds should be avoided if a site contains a lot of text. Most text is
difficult to read against a background image unless the image is light enough to provide good
contrast for the text.
Instead of using a dark, busy image to tile a page background, instead choose a light, simple
image.
CSS allows more control over background image tiling that standard HTML. To apply a
background image with CSS, use the <BODY> element as the selector with the
BACKGROUND property (BODY {BACKGROUND: URL (texture4.jpg)}). Note the URL
syntax in the rule. The path and filename are contained within parentheses.
The default for CSS background graphics is the same as using the BACKGROUND attribute.
The image tiles across the page.
The CSS BACKGROUND-REPEAT property allows a designer to create a single column or row
of an image rather than tiling the image completely across the page. The BACKGROUNDPOSITION property can also be used to change the position of the background graphic.

7

What are transparent spacer GIFs?
We can set one color of a .GIF or .PNG to be transparent.
A single pixel graphic of one color set to be transparent can solve spacing problems that cannot
be solved with standard HTML code.
The WIDTH and HEIGHT attributes can be used to change the transparent spacer GIF to any
size desired.
The transparent spacer GIF is sometimes the only way to achieve a desired result.

8

How can we add white space around an image?
The designer should add white space around images to reduce clutter and improve readability.
To increase the white space around an image, the HSPACE and VSPACE attributes can be added

Prof. Mukesh N. Tekwani

Page 3 of 4
HTML Graphics
to the <IMG> element by specifying the pixel amount.
VSPACE affects both the top and bottom sides while HSPACE affects the left and right sides.
White space can also be added to a graphic by using graphic editing software.
CSS offers more control over image white space through the application of the margin properties
to individual sides of an image.

9

What is lossless file compression?
Lossless file compression is a technique (algorithm) that allows the exact original data to be
constructed from the compressed data.
This technique is used where it is important that the original and decomposed data must be
identical.
This technique is used in many applications e.g., in compressing application programs, in the ZIP
file utility, in compressing program files and text documents.
GIF and PNG image file formats use the lossless compression technique.
Huffman coding algorithm is used for lossless compression.
Lossless compression gives low compression ratios.

10 Explain Lossy Image Compression
Lossy image compression is a technique (algorithm) in which some data is lost when the image is
decompressed.
Lossy compression is used for multimedia files such as still images, audio and video, streaming
media and internet telephony.
The JPEG file format has lossy compression.
Lossy compression gives a very high compression ratio.
Lossy compression technique is necessary when large multimedia files have to be transferred
over a network; reducing the file size is important in this case.
A picture is converted to a digital file by considering it to be an array of dots, and specifying the
color and brightness of each dot. If the picture contains an area of the same color, it can be
compressed without loss by saying "200 red dots" instead of "red dot, red dot, ... red dot" 200
times.
Lossy compression works because in many cases files contain more information than is needed
for a particular purpose. For example, a picture may have more detail than the eye can distinguish
when reproduced.

Page 4 of 4

mukeshtekwani@hotmail.com
Ad

More Related Content

What's hot (20)

MYSQL - PHP Database Connectivity
MYSQL - PHP Database ConnectivityMYSQL - PHP Database Connectivity
MYSQL - PHP Database Connectivity
V.V.Vanniaperumal College for Women
 
Html and css presentation
Html and css presentationHtml and css presentation
Html and css presentation
umesh patil
 
MySQL and its basic commands
MySQL and its basic commandsMySQL and its basic commands
MySQL and its basic commands
Bwsrang Basumatary
 
Kernel security of Systems
Kernel security of SystemsKernel security of Systems
Kernel security of Systems
Jamal Jamali
 
Html Frames
Html FramesHtml Frames
Html Frames
Xainab Ishfaq
 
Unix File System
Unix File SystemUnix File System
Unix File System
student(MCA)
 
DHTML
DHTMLDHTML
DHTML
Ravinder Kamboj
 
OS file systems
OS file systemsOS file systems
OS file systems
anand hd
 
HTML Tables.ppt
HTML Tables.pptHTML Tables.ppt
HTML Tables.ppt
ShararehShojaei1
 
PHP-MySQL Database Connectivity Using XAMPP Server
PHP-MySQL Database Connectivity Using XAMPP ServerPHP-MySQL Database Connectivity Using XAMPP Server
PHP-MySQL Database Connectivity Using XAMPP Server
Rajiv Bhatia
 
CSS ppt
CSS pptCSS ppt
CSS ppt
Sanmuga Nathan
 
Multiprocessor Scheduling
Multiprocessor SchedulingMultiprocessor Scheduling
Multiprocessor Scheduling
Khadija Saleem
 
Chapter 11 - File System Implementation
Chapter 11 - File System ImplementationChapter 11 - File System Implementation
Chapter 11 - File System Implementation
Wayne Jones Jnr
 
php
phpphp
php
ajeetjhajharia
 
Http Protocol
Http ProtocolHttp Protocol
Http Protocol
N R Z Malik
 
HTML Tables
HTML TablesHTML Tables
HTML Tables
Nisa Soomro
 
Architecture of .net framework
Architecture of .net frameworkArchitecture of .net framework
Architecture of .net framework
Then Murugeshwari
 
1. introduction to html5
1. introduction to html51. introduction to html5
1. introduction to html5
JayjZens
 
Top 100 PHP Interview Questions and Answers
Top 100 PHP Interview Questions and AnswersTop 100 PHP Interview Questions and Answers
Top 100 PHP Interview Questions and Answers
Vineet Kumar Saini
 
CSV Files-1.pdf
CSV Files-1.pdfCSV Files-1.pdf
CSV Files-1.pdf
AmitenduBikashDhusiy
 

Viewers also liked (19)

Java chapter 5
Java chapter 5Java chapter 5
Java chapter 5
Mukesh Tekwani
 
Java 1-contd
Java 1-contdJava 1-contd
Java 1-contd
Mukesh Tekwani
 
Python - Regular Expressions
Python - Regular ExpressionsPython - Regular Expressions
Python - Regular Expressions
Mukesh Tekwani
 
Java chapter 3 - OOPs concepts
Java chapter 3 - OOPs conceptsJava chapter 3 - OOPs concepts
Java chapter 3 - OOPs concepts
Mukesh Tekwani
 
Java chapter 6 - Arrays -syntax and use
Java chapter 6 - Arrays -syntax and useJava chapter 6 - Arrays -syntax and use
Java chapter 6 - Arrays -syntax and use
Mukesh Tekwani
 
Java swing 1
Java swing 1Java swing 1
Java swing 1
Mukesh Tekwani
 
Html tables examples
Html tables   examplesHtml tables   examples
Html tables examples
Mukesh Tekwani
 
Digital signal and image processing FAQ
Digital signal and image processing FAQDigital signal and image processing FAQ
Digital signal and image processing FAQ
Mukesh Tekwani
 
Phases of the Compiler - Systems Programming
Phases of the Compiler - Systems ProgrammingPhases of the Compiler - Systems Programming
Phases of the Compiler - Systems Programming
Mukesh Tekwani
 
Jdbc 1
Jdbc 1Jdbc 1
Jdbc 1
Mukesh Tekwani
 
Data Link Layer
Data Link Layer Data Link Layer
Data Link Layer
Mukesh Tekwani
 
Python reading and writing files
Python reading and writing filesPython reading and writing files
Python reading and writing files
Mukesh Tekwani
 
Java chapter 3
Java   chapter 3Java   chapter 3
Java chapter 3
Mukesh Tekwani
 
Java misc1
Java misc1Java misc1
Java misc1
Mukesh Tekwani
 
Java chapter 1
Java   chapter 1Java   chapter 1
Java chapter 1
Mukesh Tekwani
 
Data communications ch 1
Data communications   ch 1Data communications   ch 1
Data communications ch 1
Mukesh Tekwani
 
Chap 3 data and signals
Chap 3 data and signalsChap 3 data and signals
Chap 3 data and signals
Mukesh Tekwani
 
Chapter 26 - Remote Logging, Electronic Mail & File Transfer
Chapter 26 - Remote Logging, Electronic Mail & File TransferChapter 26 - Remote Logging, Electronic Mail & File Transfer
Chapter 26 - Remote Logging, Electronic Mail & File Transfer
Wayne Jones Jnr
 
Introduction to systems programming
Introduction to systems programmingIntroduction to systems programming
Introduction to systems programming
Mukesh Tekwani
 
Python - Regular Expressions
Python - Regular ExpressionsPython - Regular Expressions
Python - Regular Expressions
Mukesh Tekwani
 
Java chapter 3 - OOPs concepts
Java chapter 3 - OOPs conceptsJava chapter 3 - OOPs concepts
Java chapter 3 - OOPs concepts
Mukesh Tekwani
 
Java chapter 6 - Arrays -syntax and use
Java chapter 6 - Arrays -syntax and useJava chapter 6 - Arrays -syntax and use
Java chapter 6 - Arrays -syntax and use
Mukesh Tekwani
 
Digital signal and image processing FAQ
Digital signal and image processing FAQDigital signal and image processing FAQ
Digital signal and image processing FAQ
Mukesh Tekwani
 
Phases of the Compiler - Systems Programming
Phases of the Compiler - Systems ProgrammingPhases of the Compiler - Systems Programming
Phases of the Compiler - Systems Programming
Mukesh Tekwani
 
Python reading and writing files
Python reading and writing filesPython reading and writing files
Python reading and writing files
Mukesh Tekwani
 
Data communications ch 1
Data communications   ch 1Data communications   ch 1
Data communications ch 1
Mukesh Tekwani
 
Chap 3 data and signals
Chap 3 data and signalsChap 3 data and signals
Chap 3 data and signals
Mukesh Tekwani
 
Chapter 26 - Remote Logging, Electronic Mail & File Transfer
Chapter 26 - Remote Logging, Electronic Mail & File TransferChapter 26 - Remote Logging, Electronic Mail & File Transfer
Chapter 26 - Remote Logging, Electronic Mail & File Transfer
Wayne Jones Jnr
 
Introduction to systems programming
Introduction to systems programmingIntroduction to systems programming
Introduction to systems programming
Mukesh Tekwani
 
Ad

Similar to Html graphics (20)

Inserting imagesin html
Inserting imagesin htmlInserting imagesin html
Inserting imagesin html
nobel mujuji
 
Animation in the web
Animation in the webAnimation in the web
Animation in the web
Vishal Polley
 
Image Files Formats
Image Files FormatsImage Files Formats
Image Files Formats
Sarah Fernetich
 
Webquest
WebquestWebquest
Webquest
webquest
 
JPG vs. GIF vs. PNG
JPG vs. GIF vs. PNGJPG vs. GIF vs. PNG
JPG vs. GIF vs. PNG
kay2
 
Week 6 Task File Formats
Week 6 Task   File FormatsWeek 6 Task   File Formats
Week 6 Task File Formats
guest2cf876
 
All About Graphics
All About GraphicsAll About Graphics
All About Graphics
megweb
 
Power Point Presentation
Power Point PresentationPower Point Presentation
Power Point Presentation
CharlCooper
 
File types
File typesFile types
File types
Kate Carlyle
 
About graphics-on-web
About graphics-on-webAbout graphics-on-web
About graphics-on-web
Tayyab Ahmed
 
Chap16
Chap16Chap16
Chap16
dkd_woohoo
 
File Formats Re-Submission
File Formats Re-SubmissionFile Formats Re-Submission
File Formats Re-Submission
tomwaumsley
 
Graphic File Formats
Graphic File FormatsGraphic File Formats
Graphic File Formats
bs07sjh
 
Graphics
GraphicsGraphics
Graphics
Christian Technical Training Centre
 
Bmsc1103
Bmsc1103Bmsc1103
Bmsc1103
cool_beans
 
BMSC1103 presentation
BMSC1103 presentationBMSC1103 presentation
BMSC1103 presentation
gueste8bf88
 
Graphic File Formats
Graphic  File  FormatsGraphic  File  Formats
Graphic File Formats
aidanbd
 
Image & Graphic Files
Image & Graphic FilesImage & Graphic Files
Image & Graphic Files
bs07d3p
 
File Types Pro Forma
File Types Pro FormaFile Types Pro Forma
File Types Pro Forma
Emily-F
 
Chapter 23: Web Images
Chapter 23: Web ImagesChapter 23: Web Images
Chapter 23: Web Images
Steve Guinan
 
Inserting imagesin html
Inserting imagesin htmlInserting imagesin html
Inserting imagesin html
nobel mujuji
 
Animation in the web
Animation in the webAnimation in the web
Animation in the web
Vishal Polley
 
JPG vs. GIF vs. PNG
JPG vs. GIF vs. PNGJPG vs. GIF vs. PNG
JPG vs. GIF vs. PNG
kay2
 
Week 6 Task File Formats
Week 6 Task   File FormatsWeek 6 Task   File Formats
Week 6 Task File Formats
guest2cf876
 
All About Graphics
All About GraphicsAll About Graphics
All About Graphics
megweb
 
Power Point Presentation
Power Point PresentationPower Point Presentation
Power Point Presentation
CharlCooper
 
About graphics-on-web
About graphics-on-webAbout graphics-on-web
About graphics-on-web
Tayyab Ahmed
 
File Formats Re-Submission
File Formats Re-SubmissionFile Formats Re-Submission
File Formats Re-Submission
tomwaumsley
 
Graphic File Formats
Graphic File FormatsGraphic File Formats
Graphic File Formats
bs07sjh
 
BMSC1103 presentation
BMSC1103 presentationBMSC1103 presentation
BMSC1103 presentation
gueste8bf88
 
Graphic File Formats
Graphic  File  FormatsGraphic  File  Formats
Graphic File Formats
aidanbd
 
Image & Graphic Files
Image & Graphic FilesImage & Graphic Files
Image & Graphic Files
bs07d3p
 
File Types Pro Forma
File Types Pro FormaFile Types Pro Forma
File Types Pro Forma
Emily-F
 
Chapter 23: Web Images
Chapter 23: Web ImagesChapter 23: Web Images
Chapter 23: Web Images
Steve Guinan
 
Ad

More from Mukesh Tekwani (20)

The Elphinstonian 1988-College Building Centenary Number (2).pdf
The Elphinstonian 1988-College Building Centenary Number (2).pdfThe Elphinstonian 1988-College Building Centenary Number (2).pdf
The Elphinstonian 1988-College Building Centenary Number (2).pdf
Mukesh Tekwani
 
Circular motion
Circular motionCircular motion
Circular motion
Mukesh Tekwani
 
Gravitation
GravitationGravitation
Gravitation
Mukesh Tekwani
 
ISCE-Class 12-Question Bank - Electrostatics - Physics
ISCE-Class 12-Question Bank - Electrostatics  -  PhysicsISCE-Class 12-Question Bank - Electrostatics  -  Physics
ISCE-Class 12-Question Bank - Electrostatics - Physics
Mukesh Tekwani
 
Hexadecimal to binary conversion
Hexadecimal to binary conversion Hexadecimal to binary conversion
Hexadecimal to binary conversion
Mukesh Tekwani
 
Hexadecimal to decimal conversion
Hexadecimal to decimal conversion Hexadecimal to decimal conversion
Hexadecimal to decimal conversion
Mukesh Tekwani
 
Hexadecimal to octal conversion
Hexadecimal to octal conversionHexadecimal to octal conversion
Hexadecimal to octal conversion
Mukesh Tekwani
 
Gray code to binary conversion
Gray code to binary conversion Gray code to binary conversion
Gray code to binary conversion
Mukesh Tekwani
 
What is Gray Code?
What is Gray Code? What is Gray Code?
What is Gray Code?
Mukesh Tekwani
 
Decimal to Binary conversion
Decimal to Binary conversionDecimal to Binary conversion
Decimal to Binary conversion
Mukesh Tekwani
 
Video Lectures for IGCSE Physics 2020-21
Video Lectures for IGCSE Physics 2020-21Video Lectures for IGCSE Physics 2020-21
Video Lectures for IGCSE Physics 2020-21
Mukesh Tekwani
 
Refraction and dispersion of light through a prism
Refraction and dispersion of light through a prismRefraction and dispersion of light through a prism
Refraction and dispersion of light through a prism
Mukesh Tekwani
 
Refraction of light at a plane surface
Refraction of light at a plane surfaceRefraction of light at a plane surface
Refraction of light at a plane surface
Mukesh Tekwani
 
Spherical mirrors
Spherical mirrorsSpherical mirrors
Spherical mirrors
Mukesh Tekwani
 
Atom, origin of spectra Bohr's theory of hydrogen atom
Atom, origin of spectra Bohr's theory of hydrogen atomAtom, origin of spectra Bohr's theory of hydrogen atom
Atom, origin of spectra Bohr's theory of hydrogen atom
Mukesh Tekwani
 
Refraction of light at spherical surfaces of lenses
Refraction of light at spherical surfaces of lensesRefraction of light at spherical surfaces of lenses
Refraction of light at spherical surfaces of lenses
Mukesh Tekwani
 
ISCE (XII) - PHYSICS BOARD EXAM FEB 2020 - WEIGHTAGE
ISCE (XII) - PHYSICS BOARD EXAM FEB 2020 - WEIGHTAGEISCE (XII) - PHYSICS BOARD EXAM FEB 2020 - WEIGHTAGE
ISCE (XII) - PHYSICS BOARD EXAM FEB 2020 - WEIGHTAGE
Mukesh Tekwani
 
Cyber Laws
Cyber LawsCyber Laws
Cyber Laws
Mukesh Tekwani
 
XML
XMLXML
XML
Mukesh Tekwani
 
Social media
Social mediaSocial media
Social media
Mukesh Tekwani
 
The Elphinstonian 1988-College Building Centenary Number (2).pdf
The Elphinstonian 1988-College Building Centenary Number (2).pdfThe Elphinstonian 1988-College Building Centenary Number (2).pdf
The Elphinstonian 1988-College Building Centenary Number (2).pdf
Mukesh Tekwani
 
ISCE-Class 12-Question Bank - Electrostatics - Physics
ISCE-Class 12-Question Bank - Electrostatics  -  PhysicsISCE-Class 12-Question Bank - Electrostatics  -  Physics
ISCE-Class 12-Question Bank - Electrostatics - Physics
Mukesh Tekwani
 
Hexadecimal to binary conversion
Hexadecimal to binary conversion Hexadecimal to binary conversion
Hexadecimal to binary conversion
Mukesh Tekwani
 
Hexadecimal to decimal conversion
Hexadecimal to decimal conversion Hexadecimal to decimal conversion
Hexadecimal to decimal conversion
Mukesh Tekwani
 
Hexadecimal to octal conversion
Hexadecimal to octal conversionHexadecimal to octal conversion
Hexadecimal to octal conversion
Mukesh Tekwani
 
Gray code to binary conversion
Gray code to binary conversion Gray code to binary conversion
Gray code to binary conversion
Mukesh Tekwani
 
Decimal to Binary conversion
Decimal to Binary conversionDecimal to Binary conversion
Decimal to Binary conversion
Mukesh Tekwani
 
Video Lectures for IGCSE Physics 2020-21
Video Lectures for IGCSE Physics 2020-21Video Lectures for IGCSE Physics 2020-21
Video Lectures for IGCSE Physics 2020-21
Mukesh Tekwani
 
Refraction and dispersion of light through a prism
Refraction and dispersion of light through a prismRefraction and dispersion of light through a prism
Refraction and dispersion of light through a prism
Mukesh Tekwani
 
Refraction of light at a plane surface
Refraction of light at a plane surfaceRefraction of light at a plane surface
Refraction of light at a plane surface
Mukesh Tekwani
 
Atom, origin of spectra Bohr's theory of hydrogen atom
Atom, origin of spectra Bohr's theory of hydrogen atomAtom, origin of spectra Bohr's theory of hydrogen atom
Atom, origin of spectra Bohr's theory of hydrogen atom
Mukesh Tekwani
 
Refraction of light at spherical surfaces of lenses
Refraction of light at spherical surfaces of lensesRefraction of light at spherical surfaces of lenses
Refraction of light at spherical surfaces of lenses
Mukesh Tekwani
 
ISCE (XII) - PHYSICS BOARD EXAM FEB 2020 - WEIGHTAGE
ISCE (XII) - PHYSICS BOARD EXAM FEB 2020 - WEIGHTAGEISCE (XII) - PHYSICS BOARD EXAM FEB 2020 - WEIGHTAGE
ISCE (XII) - PHYSICS BOARD EXAM FEB 2020 - WEIGHTAGE
Mukesh Tekwani
 

Recently uploaded (20)

Geography Sem II Unit 1C Correlation of Geography with other school subjects
Geography Sem II Unit 1C Correlation of Geography with other school subjectsGeography Sem II Unit 1C Correlation of Geography with other school subjects
Geography Sem II Unit 1C Correlation of Geography with other school subjects
ProfDrShaikhImran
 
UNIT 3 NATIONAL HEALTH PROGRAMMEE. SOCIAL AND PREVENTIVE PHARMACY
UNIT 3 NATIONAL HEALTH PROGRAMMEE. SOCIAL AND PREVENTIVE PHARMACYUNIT 3 NATIONAL HEALTH PROGRAMMEE. SOCIAL AND PREVENTIVE PHARMACY
UNIT 3 NATIONAL HEALTH PROGRAMMEE. SOCIAL AND PREVENTIVE PHARMACY
DR.PRISCILLA MARY J
 
Niamh Lucey, Mary Dunne. Health Sciences Libraries Group (LAI). Lighting the ...
Niamh Lucey, Mary Dunne. Health Sciences Libraries Group (LAI). Lighting the ...Niamh Lucey, Mary Dunne. Health Sciences Libraries Group (LAI). Lighting the ...
Niamh Lucey, Mary Dunne. Health Sciences Libraries Group (LAI). Lighting the ...
Library Association of Ireland
 
Handling Multiple Choice Responses: Fortune Effiong.pptx
Handling Multiple Choice Responses: Fortune Effiong.pptxHandling Multiple Choice Responses: Fortune Effiong.pptx
Handling Multiple Choice Responses: Fortune Effiong.pptx
AuthorAIDNationalRes
 
pulse ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
pulse  ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulsepulse  ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
pulse ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
sushreesangita003
 
Odoo Inventory Rules and Routes v17 - Odoo Slides
Odoo Inventory Rules and Routes v17 - Odoo SlidesOdoo Inventory Rules and Routes v17 - Odoo Slides
Odoo Inventory Rules and Routes v17 - Odoo Slides
Celine George
 
Multi-currency in odoo accounting and Update exchange rates automatically in ...
Multi-currency in odoo accounting and Update exchange rates automatically in ...Multi-currency in odoo accounting and Update exchange rates automatically in ...
Multi-currency in odoo accounting and Update exchange rates automatically in ...
Celine George
 
To study the nervous system of insect.pptx
To study the nervous system of insect.pptxTo study the nervous system of insect.pptx
To study the nervous system of insect.pptx
Arshad Shaikh
 
Understanding P–N Junction Semiconductors: A Beginner’s Guide
Understanding P–N Junction Semiconductors: A Beginner’s GuideUnderstanding P–N Junction Semiconductors: A Beginner’s Guide
Understanding P–N Junction Semiconductors: A Beginner’s Guide
GS Virdi
 
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Library Association of Ireland
 
How to manage Multiple Warehouses for multiple floors in odoo point of sale
How to manage Multiple Warehouses for multiple floors in odoo point of saleHow to manage Multiple Warehouses for multiple floors in odoo point of sale
How to manage Multiple Warehouses for multiple floors in odoo point of sale
Celine George
 
Phoenix – A Collaborative Renewal of Children’s and Young People’s Services C...
Phoenix – A Collaborative Renewal of Children’s and Young People’s Services C...Phoenix – A Collaborative Renewal of Children’s and Young People’s Services C...
Phoenix – A Collaborative Renewal of Children’s and Young People’s Services C...
Library Association of Ireland
 
Political History of Pala dynasty Pala Rulers NEP.pptx
Political History of Pala dynasty Pala Rulers NEP.pptxPolitical History of Pala dynasty Pala Rulers NEP.pptx
Political History of Pala dynasty Pala Rulers NEP.pptx
Arya Mahila P. G. College, Banaras Hindu University, Varanasi, India.
 
Michelle Rumley & Mairéad Mooney, Boole Library, University College Cork. Tra...
Michelle Rumley & Mairéad Mooney, Boole Library, University College Cork. Tra...Michelle Rumley & Mairéad Mooney, Boole Library, University College Cork. Tra...
Michelle Rumley & Mairéad Mooney, Boole Library, University College Cork. Tra...
Library Association of Ireland
 
Introduction to Vibe Coding and Vibe Engineering
Introduction to Vibe Coding and Vibe EngineeringIntroduction to Vibe Coding and Vibe Engineering
Introduction to Vibe Coding and Vibe Engineering
Damian T. Gordon
 
Metamorphosis: Life's Transformative Journey
Metamorphosis: Life's Transformative JourneyMetamorphosis: Life's Transformative Journey
Metamorphosis: Life's Transformative Journey
Arshad Shaikh
 
One Hot encoding a revolution in Machine learning
One Hot encoding a revolution in Machine learningOne Hot encoding a revolution in Machine learning
One Hot encoding a revolution in Machine learning
momer9505
 
GDGLSPGCOER - Git and GitHub Workshop.pptx
GDGLSPGCOER - Git and GitHub Workshop.pptxGDGLSPGCOER - Git and GitHub Workshop.pptx
GDGLSPGCOER - Git and GitHub Workshop.pptx
azeenhodekar
 
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptxSCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
Ronisha Das
 
Quality Contril Analysis of Containers.pdf
Quality Contril Analysis of Containers.pdfQuality Contril Analysis of Containers.pdf
Quality Contril Analysis of Containers.pdf
Dr. Bindiya Chauhan
 
Geography Sem II Unit 1C Correlation of Geography with other school subjects
Geography Sem II Unit 1C Correlation of Geography with other school subjectsGeography Sem II Unit 1C Correlation of Geography with other school subjects
Geography Sem II Unit 1C Correlation of Geography with other school subjects
ProfDrShaikhImran
 
UNIT 3 NATIONAL HEALTH PROGRAMMEE. SOCIAL AND PREVENTIVE PHARMACY
UNIT 3 NATIONAL HEALTH PROGRAMMEE. SOCIAL AND PREVENTIVE PHARMACYUNIT 3 NATIONAL HEALTH PROGRAMMEE. SOCIAL AND PREVENTIVE PHARMACY
UNIT 3 NATIONAL HEALTH PROGRAMMEE. SOCIAL AND PREVENTIVE PHARMACY
DR.PRISCILLA MARY J
 
Niamh Lucey, Mary Dunne. Health Sciences Libraries Group (LAI). Lighting the ...
Niamh Lucey, Mary Dunne. Health Sciences Libraries Group (LAI). Lighting the ...Niamh Lucey, Mary Dunne. Health Sciences Libraries Group (LAI). Lighting the ...
Niamh Lucey, Mary Dunne. Health Sciences Libraries Group (LAI). Lighting the ...
Library Association of Ireland
 
Handling Multiple Choice Responses: Fortune Effiong.pptx
Handling Multiple Choice Responses: Fortune Effiong.pptxHandling Multiple Choice Responses: Fortune Effiong.pptx
Handling Multiple Choice Responses: Fortune Effiong.pptx
AuthorAIDNationalRes
 
pulse ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
pulse  ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulsepulse  ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
pulse ppt.pptx Types of pulse , characteristics of pulse , Alteration of pulse
sushreesangita003
 
Odoo Inventory Rules and Routes v17 - Odoo Slides
Odoo Inventory Rules and Routes v17 - Odoo SlidesOdoo Inventory Rules and Routes v17 - Odoo Slides
Odoo Inventory Rules and Routes v17 - Odoo Slides
Celine George
 
Multi-currency in odoo accounting and Update exchange rates automatically in ...
Multi-currency in odoo accounting and Update exchange rates automatically in ...Multi-currency in odoo accounting and Update exchange rates automatically in ...
Multi-currency in odoo accounting and Update exchange rates automatically in ...
Celine George
 
To study the nervous system of insect.pptx
To study the nervous system of insect.pptxTo study the nervous system of insect.pptx
To study the nervous system of insect.pptx
Arshad Shaikh
 
Understanding P–N Junction Semiconductors: A Beginner’s Guide
Understanding P–N Junction Semiconductors: A Beginner’s GuideUnderstanding P–N Junction Semiconductors: A Beginner’s Guide
Understanding P–N Junction Semiconductors: A Beginner’s Guide
GS Virdi
 
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Marie Boran Special Collections Librarian Hardiman Library, University of Gal...
Library Association of Ireland
 
How to manage Multiple Warehouses for multiple floors in odoo point of sale
How to manage Multiple Warehouses for multiple floors in odoo point of saleHow to manage Multiple Warehouses for multiple floors in odoo point of sale
How to manage Multiple Warehouses for multiple floors in odoo point of sale
Celine George
 
Phoenix – A Collaborative Renewal of Children’s and Young People’s Services C...
Phoenix – A Collaborative Renewal of Children’s and Young People’s Services C...Phoenix – A Collaborative Renewal of Children’s and Young People’s Services C...
Phoenix – A Collaborative Renewal of Children’s and Young People’s Services C...
Library Association of Ireland
 
Michelle Rumley & Mairéad Mooney, Boole Library, University College Cork. Tra...
Michelle Rumley & Mairéad Mooney, Boole Library, University College Cork. Tra...Michelle Rumley & Mairéad Mooney, Boole Library, University College Cork. Tra...
Michelle Rumley & Mairéad Mooney, Boole Library, University College Cork. Tra...
Library Association of Ireland
 
Introduction to Vibe Coding and Vibe Engineering
Introduction to Vibe Coding and Vibe EngineeringIntroduction to Vibe Coding and Vibe Engineering
Introduction to Vibe Coding and Vibe Engineering
Damian T. Gordon
 
Metamorphosis: Life's Transformative Journey
Metamorphosis: Life's Transformative JourneyMetamorphosis: Life's Transformative Journey
Metamorphosis: Life's Transformative Journey
Arshad Shaikh
 
One Hot encoding a revolution in Machine learning
One Hot encoding a revolution in Machine learningOne Hot encoding a revolution in Machine learning
One Hot encoding a revolution in Machine learning
momer9505
 
GDGLSPGCOER - Git and GitHub Workshop.pptx
GDGLSPGCOER - Git and GitHub Workshop.pptxGDGLSPGCOER - Git and GitHub Workshop.pptx
GDGLSPGCOER - Git and GitHub Workshop.pptx
azeenhodekar
 
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptxSCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
Ronisha Das
 
Quality Contril Analysis of Containers.pdf
Quality Contril Analysis of Containers.pdfQuality Contril Analysis of Containers.pdf
Quality Contril Analysis of Containers.pdf
Dr. Bindiya Chauhan
 

Html graphics

  • 1. HTML Graphics HTML Graphics 1 What are the commonly used image file formats on the Web? Describe them. The three most widely accepted image file formats on the Web are: .GIF, .JPG, and .PNG. All of the formats compress the images to create smaller files that download much more quickly than the original image. GIF - Graphics Interchange Format GIF uses a compression technique that preserves all of the color information for the image. The .GIF format has an 8-bit color depth that allows for the use of 256 colors (as 28 = 256). The fewer the number of colors that are used in a .GIF file, the greater the compression and the smaller the file size. The .GIF file is ideal for line art and color graphics because it is excellent at compressing and displaying flat color areas. It uses a simple compression algorithm. Because of the color depth limitation, however, the .GIF format is limiting and should not be used for photographs or complex graphics that have gradation in colour. GIF Transparency: With GIF files we can choose one color in an image to appear as transparent in the browser The background color or pattern will show through the areas that we marks as transparent. Using transparent areas allows us to create graphics that appear to have an irregular shape instead of a rectangle. GIF Animation The .GIF format allows a designer to store multiple images and timing information about the images in a single file. This allows the creation of animations consisting of multiple static images that rotate, creating the illusion of motion. When creating a GIF animation, a designer can adjust the amount of time between frames and the number of times that the animation plays. GIF animation does not require browser plug-ins and does not have large download times. Some of the tools through which we can create GIF animation are: ULead GIF Animator, and Microsoft Liquid Motion. Disadvantages of animated GIF images: They only support 256 color palette. They can only animate in browsers that support animated gifs. They cannot be edited once they are encoded as an animated gif. If we edit animated GIF, we will lose the animation sequence when it is saved. JPG - Joint Photographic Experts Group (JPG or JPEG) image file format. JPGs support millions of colors since they are 24-bit, so they are ideal for photographs or continuous tone images. JPGs use a lossy file compression technique that discards some colors, so there may be a loss of quality from the original image. The compression algorithm is more complex for JPG files. When saving an image in .JPG format, a slider lets the designer choose the quality of the image. The higher the compression, the smaller the size of the image file and the quicker the download time, but the lower the image quality. Images can be converted into JPG format using tools such as Adobe PhotoShop. This format is not suitable for images with text and large blocks of solid color, and simple shapes with crisp edges. This is because when the image is compressed the text, color or lines may blur resulting in image that is not as sharp. Prof. Mukesh N. Tekwani Page 1 of 4
  • 2. HTML Graphics PNG - Portable Network Graphics format This was specifically designed for use on the Web. It has better compression rates than GIF images and therefore images are smaller in size. It uses a compression technique that retains all of the color information, so it is not as efficient at compressing image files as .JPG. PNG supports 8-bit indexed-color, 16-bit grayscale, and 24-bit true color images. PNG supports transparency and interlacing but not animation. Certain browsers do not support PNG format. 2 What is interlacing and progressive displays? We can save images in an interlaced or progressive format. A low resolution image is shown first, followed by one or more passes that refine the image until the full-resolution image is displayed. This is known as interlacing. Both interlacing and progressive display formats gradually display an image in a pre-specified number of passes as the data arrives in the browser. The only advantage to saving images in these formats is that the user will see a blurred image that gradually clears, giving them something to look at as it downloads. The biggest disadvantage to saving an image in this format is browser support. Older browsers may not display the image properly. 3 Which image format is the best for the Web? GIFs should be used for simple colored graphics and line art. The .GIF format can also be used for animation and transparency. The .JPG format is best for 24-bit full-color photographic images and complex graphics. The .PNG format can be used instead of GIFs, but all browsers do not support this format. PNG does not replace JPGs since PNGs do not compress 24-bit images as well as .JPG. 4 Computer Color Basics: Color depth is the amount of data used to create color on a display. Dithering occurs when a browser comes across a color it does not support. The browser then attempts to mix its own colors to create a similar color. Banding refers to the effort to match the closest colors from the GIFs palette to the original colors in a photo. 5 Discuss the IMG element The <IMG> markup element is used to place graphics or images on a Web page. The <IMG> element is an empty element, so it does not require a closing tag. The <IMG> element only needs the SRC attribute to display an image in a browser. There are other attributes that can be used to select how and where the image appears in the browser. Attribute Use ALIGN Specifies the position of the image in relation to the surrounding text. Displays an alternate string of text instead of an image if the user has a text-only ALT browser or has graphics turned off. The ALT value is displayed as a pop-up window when a mouse points to the image. Determines whether a border appears on the image. State the border value in BORDER pixels. We can use this attribute to turn off the hypertext border if the image is a link. HEIGHT Specifies the height of the image in pixels. Specifies the amount of horizontal white space on the left and right sides of the HSPACE image in pixels. The only required attribute, SRC specifies the URL of the graphic file you want to SRC display. As with any URL, the path must be relative to the HTML file. Image [email protected] Page 2 of 4
  • 3. HTML Graphics VSPACE WIDTH filenames are case-sensitive! Specifies the amount of vertical white space on the top and bottom sides of the image in pixels. Specifies the width of the image in pixels. ALIGN, BORDER, VSPACE, and HSPACE have been deprecated in HTML 4.0 in favor of CSS. The table below shows the replacement attributes: Deprecated Attribute ALIGN BORDER HEIGHT HSPACE and VSPACE 6 Equivalent CSS Property FLOAT allows you to flow text around an image or other object. Example: IMG {FLOAT: LEFT} BORDER lets you set a border on an image, or remove the border from a linked image. Specifies the height of the image in pixels. The PADDING or MARGIN properties set white space around an image. You can control individual sides of the image, or apply white space around the entire image. Write a note on background images. The BACKGROUND attribute is used to tile images across the background of a Web page. Any image can be used as a background image, but design principles need to be kept in mind when using images in the background. Complex backgrounds can confuse and distract the user. Dark or complex backgrounds should be avoided if a site contains a lot of text. Most text is difficult to read against a background image unless the image is light enough to provide good contrast for the text. Instead of using a dark, busy image to tile a page background, instead choose a light, simple image. CSS allows more control over background image tiling that standard HTML. To apply a background image with CSS, use the <BODY> element as the selector with the BACKGROUND property (BODY {BACKGROUND: URL (texture4.jpg)}). Note the URL syntax in the rule. The path and filename are contained within parentheses. The default for CSS background graphics is the same as using the BACKGROUND attribute. The image tiles across the page. The CSS BACKGROUND-REPEAT property allows a designer to create a single column or row of an image rather than tiling the image completely across the page. The BACKGROUNDPOSITION property can also be used to change the position of the background graphic. 7 What are transparent spacer GIFs? We can set one color of a .GIF or .PNG to be transparent. A single pixel graphic of one color set to be transparent can solve spacing problems that cannot be solved with standard HTML code. The WIDTH and HEIGHT attributes can be used to change the transparent spacer GIF to any size desired. The transparent spacer GIF is sometimes the only way to achieve a desired result. 8 How can we add white space around an image? The designer should add white space around images to reduce clutter and improve readability. To increase the white space around an image, the HSPACE and VSPACE attributes can be added Prof. Mukesh N. Tekwani Page 3 of 4
  • 4. HTML Graphics to the <IMG> element by specifying the pixel amount. VSPACE affects both the top and bottom sides while HSPACE affects the left and right sides. White space can also be added to a graphic by using graphic editing software. CSS offers more control over image white space through the application of the margin properties to individual sides of an image. 9 What is lossless file compression? Lossless file compression is a technique (algorithm) that allows the exact original data to be constructed from the compressed data. This technique is used where it is important that the original and decomposed data must be identical. This technique is used in many applications e.g., in compressing application programs, in the ZIP file utility, in compressing program files and text documents. GIF and PNG image file formats use the lossless compression technique. Huffman coding algorithm is used for lossless compression. Lossless compression gives low compression ratios. 10 Explain Lossy Image Compression Lossy image compression is a technique (algorithm) in which some data is lost when the image is decompressed. Lossy compression is used for multimedia files such as still images, audio and video, streaming media and internet telephony. The JPEG file format has lossy compression. Lossy compression gives a very high compression ratio. Lossy compression technique is necessary when large multimedia files have to be transferred over a network; reducing the file size is important in this case. A picture is converted to a digital file by considering it to be an array of dots, and specifying the color and brightness of each dot. If the picture contains an area of the same color, it can be compressed without loss by saying "200 red dots" instead of "red dot, red dot, ... red dot" 200 times. Lossy compression works because in many cases files contain more information than is needed for a particular purpose. For example, a picture may have more detail than the eye can distinguish when reproduced. Page 4 of 4 [email protected]