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

DPI support #115

Closed
hongkongkiwi opened this Issue Dec 4, 2017 · 2 comments

Comments

3 participants
@hongkongkiwi

hongkongkiwi commented Dec 4, 2017

Is it possible to support DPI?

I'm trying to resize some icons to a specific DPI (144 output, 72 input) and it seems this option is missing.

kleisauke added a commit that referenced this issue Dec 4, 2017

@kleisauke kleisauke self-assigned this Dec 4, 2017

@kleisauke kleisauke added this to the v3.0.0 milestone Dec 4, 2017

@kleisauke

This comment has been minimized.

Show comment
Hide comment
@kleisauke

kleisauke Dec 4, 2017

Member

Hello Andy,

This option was indeed missing, so I just added a new device pixel ratio parameter (&dpr=) in commit 5335a0c and PR #113.

The new parameter makes it possible to display images at the correct pixel density on a variety of devices such as Apple devices with Retina Displays and Android devices. You must specify either a width, a height, or both for this parameter to work.

If you want, you can test it on our test environment:
https://t0.nl/?url=ory.weserv.nl/lichtenstein.jpg&h=72&dpr=2

It will be implemented on the production server when libvips 8.6 is out (due this week). Thanks for reporting!

Member

kleisauke commented Dec 4, 2017

Hello Andy,

This option was indeed missing, so I just added a new device pixel ratio parameter (&dpr=) in commit 5335a0c and PR #113.

The new parameter makes it possible to display images at the correct pixel density on a variety of devices such as Apple devices with Retina Displays and Android devices. You must specify either a width, a height, or both for this parameter to work.

If you want, you can test it on our test environment:
https://t0.nl/?url=ory.weserv.nl/lichtenstein.jpg&h=72&dpr=2

It will be implemented on the production server when libvips 8.6 is out (due this week). Thanks for reporting!

@kleisauke

This comment has been minimized.

Show comment
Hide comment
@kleisauke
Member

kleisauke commented Dec 10, 2017

@andrieslouw andrieslouw added completed and removed started labels Aug 3, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment