Skip to content

Commit aa22724

Browse files
committed
add info about dpi
1 parent 9b8ae73 commit aa22724

File tree

3 files changed

+15
-0
lines changed

3 files changed

+15
-0
lines changed

changelog.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,15 @@ Always improving. Updates to HTML/CSS to Image are posted here.
1616

1717
If you have feature requests, please send them to us: [email protected].
1818

19+
## DPI query param
20+
December 18, 2024
21+
{: .text-delta}
22+
23+
We've added a new query param `dpi` which allows you to set the DPI metadata tag on your generated image. For example `hcti.io/v1/image/123abc?dpi=300`.
24+
This only sets the metadata tag, you must still create an image large enough for the needed DPI.
25+
26+
<hr>
27+
1928
## Learn how to make a downloadable image
2029
December 20, 2023
2130
{: .text-delta}

getting-started/height-and-width.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,4 +129,9 @@ For a 300 DPI business card \(3.5 x 2 inches\).
129129

130130
Once you have determined your height and width in pixels, you can then set your HTML to render the exact size you need. We recommend doing this by adding `height` and `width` style parameters to the outermost HTML element in your code.
131131

132+
### DPI metadata tag
133+
134+
If you need the DPI metadata tag set on your image, you can do this by adding the query param to your image url. For example `hcti.io/v1/image/123abc?dpi=300`.
135+
Please note, you will still need to use the calculations above to create an image large enough to have the correct DPI when printed.
136+
132137
{% include code_footer.md version=3 %}

getting-started/using-the-api.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,7 @@ Query parameters can be added to the URL to adjust your image.
139139
|:-------------|:------------------|:------|
140140
| **height** | `Integer` | The height of the image. Maximum `5000`. |
141141
| **width** | `Integer` | The width of the image. Maximum `5000`. |
142+
| **dpi** | `Integer` | Sets the DPI metadata tag on the image. Maximum `600`. |
142143
| **dl** | `Integer` | Set `dl=1` and the image will be served as a downloadable attachment. |
143144

144145
<hr>

0 commit comments

Comments
 (0)