Preparing Graphics for Web Use
After you decide which graphics format to use for a particular image, your next decision is how large the graphic should be—that is, how many pixels should comprise it. This is called the image’s resolution, and it is expressed in width and height. For example, an image that is 800x600 is 800 pixels wide and 600 pixels tall.
A graphic’s file size—how many bytes the file will take up on disk—has a direct relationship to its resolution. The more pixels in a graphic, the larger the file. You must strike a balance between making a graphic’s resolution high enough to display optimally and low enough to download quickly when users load your page.
There are two ways of controlling the size (in pixels) of a graphic on a Web ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access