From the course: HTML: Images and Figures

Unlock the full course today

Join today to access over 24,900 courses taught by industry experts.

Art direction: The picture element

Art direction: The picture element - HTML Tutorial

From the course: HTML: Images and Figures

Art direction: The picture element

- [Instructor] In the proceeding videos, you've used source set to tell the browser which of a set of pictures to choose, but all the pictures have looked alike. You may have noticed when doing the challenge, that the header image looks great on a large screen, like an iPad, but on a smaller phone, like a Galaxy S5, not so much. The face, which is the centerpiece of the image, is too small to make out the detail. This is the art direction problem. That's direction as in directing a film and choosing the correct shot not which direction is the person holding the phone or tablet. Look at this set of images. Unlike the ones in the preceding videos, these are not the same image but different sizes. Instead, they've been edited so that the relief work, the important part of the image, stays front and center in each one. In order to help the browser select which of the images is the correct one to display, you use the picture element. Here's the general form of the element. It contains a…

Contents