jonom / jquery-focuspoint

jQuery plugin for 'responsive cropping'. Dynamically crop images to fill available space without cutting out the image's subject. Great for full-screen images.
Other
3.15k stars 211 forks source link

[Info] Works perfectly with picturefill.js #51

Open akroii opened 8 years ago

akroii commented 8 years ago

Try

<div class="full focuspoint" data-focus-x="-0.02" data-focus-y="-0.1" data-image-w="2250" data-image-h="1992">
<picture>
<!--[if IE 9]><video style="display: none;"><![endif]-->
<source srcset="img/yyy1.jpg" media="(min-width: 1000px)">
<source srcset="img/yyy2.jpg" media="(min-width: 600px)">
<source srcset="img/yyy3.jpg" media="(min-width: 320px)">
<!--[if IE 9]></video><![endif]-->
<img src="img/picture.jpg" alt="">
</picture>
</div>

Nice ;)

akroii commented 8 years ago

... but it not work with <img srcset="..."

yeldiRium commented 5 years ago

... but it not work with <img srcset="..."

This is actually a problem, since using src can lead to double downloads with picturefill. Although this isn't really an issue with focus point, it would be nice to have the compatibility.