-
Notifications
You must be signed in to change notification settings - Fork 35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Possibility to mark image candidate as high compressed #273
Comments
Yeah, this ties into earlier ideas that the Can you just, for example, use a single 2x source or something? Can you provide an example of your |
I basically came up with two ideas: <picture>
<source
srcset="image-w1600-q10.jpg 1600w,
image-w1440-q10.jpg 1440w,
image-w1200-q10.jpg 1200w,
image-w800-q10.jpg 800w,
image-w600-q10.jpg 600w"
media="(min-resolution: 2dppx)" />
<source
srcset="image-w1440-q80.jpg 1440w,
image-w1200-q80.jpg 1200w,
image-w800-q80.jpg 800w,
image-w600-q80.jpg 600w,
image-w400-q80.jpg 400w" />
<img
alt="picture but without artdirection" />
</picture> And: <picture>
<source srcset="img-1500w-10q.jpg 1500w" sizes="100vw" media="(max-width: 800px)" />
<source srcset="img-3000w-10q.jpg 3000w" sizes="100vw" media="(max-width: 1600px)" />
<source srcset="img-4000w-10q.jpg 4000w" sizes="100vw" media="(max-width: 2500px)" />
<source srcset="img-6000w-10q.jpg 6000w" sizes="100vw" />
<img />
</picture> Filesize descriptor or a quality level descriptor sounds interesting. |
A few years later, I indeed have a few projects where I use It looks like @eeeps will convince me to even do it down to I'm not sure we can do it with something better than |
@nhoizey have you seen the discussion on whatwg/html#4421? |
@yoavweiss I didn't, thanks a lot! I guess this issue can be closed, then? |
I think the discussion here is looking to somehow annotate high DPR images as "compressive". While related, the discussion on whatwg/html#4421 does not do exactly that. |
You're right, not exactly the same indeed. |
It would be nice to have a descriptor that marks an image candidate as high compressed (following the compressive images pattern).
For brevity also an attribute, that marks all candidates inside of a
srcset
as high compressed would be nice.Use case:
Currently this technique can only be used in combination with the
picture
element, which doubles the amount of needed images and doesn't fit the pure art direction use case.The text was updated successfully, but these errors were encountered: