1
0
Эх сурвалжийг харах

Update changelog and docs

DarthSim 1 жил өмнө
parent
commit
ac87eea317

+ 4 - 0
CHANGELOG.md

@@ -3,6 +3,10 @@
 ## [Unreleased]
 ### Add
 - Add `IMGPROXY_URL_REPLACEMENTS` config.
+- (pro) Add `IMGPROXY_STRIP_METADATA_DPI` config.
+- (pro) Add [dpi](https://docs.imgproxy.net/latest/configuration?id=dpi) processing option.
+- (pro) Add WebP EXIF and XMP to the `/info` response.
+- (pro) Add Photoshop resolution data to the `/info` response.
 
 ### Change
 - Preserve GIF's bit-per-sample.

+ 1 - 0
docs/configuration.md

@@ -541,6 +541,7 @@ imgproxy can send logs to syslog, but this feature is disabled by default. To en
 * `IMGPROXY_DISABLE_SHRINK_ON_LOAD`: when `true`, disables shrink-on-load for JPEGs and WebP files. Allows processing the entire image in linear colorspace but dramatically slows down resizing and increases memory usage when working with large images.
 * `IMGPROXY_STRIP_METADATA`: when `true`, imgproxy will strip all metadata (EXIF, IPTC, etc.) from JPEG and WebP output images. Default: `true`
 * `IMGPROXY_KEEP_COPYRIGHT`: when `true`, imgproxy will not remove copyright info while stripping metadata. Default: `true`
+* `IMGPROXY_STRIP_METADATA_DPI`: ![pro](./assets/pro.svg) the DPI metadata value that should be set for the image when its metadata is stripped. Default: `72.0`
 * `IMGPROXY_STRIP_COLOR_PROFILE`: when `true`, imgproxy will transform the embedded color profile (ICC) to sRGB and remove it from the image. Otherwise, imgproxy will try to keep it as is. Default: `true`
 * `IMGPROXY_AUTO_ROTATE`: when `true`, imgproxy will automatically rotate images based on the EXIF Orientation parameter (if available in the image meta data). The orientation tag will be removed from the image in all cases. Default: `true`
 * `IMGPROXY_ENFORCE_THUMBNAIL`: when `true` and the source image has an embedded thumbnail, imgproxy will always use the embedded thumbnail instead of the main image. Currently, only thumbnails embedded in `heic` and `avif` are supported. Default: `false`

+ 12 - 0
docs/generating_the_url.md

@@ -552,6 +552,18 @@ kcr:%keep_copyright
 
 When set to `1`, `t` or `true`, imgproxy will not remove copyright info while stripping metadata. This is normally controlled by the [IMGPROXY_KEEP_COPYRIGHT](configuration.md#miscellaneous) configuration but this procesing option allows the configuration to be set for each request.
 
+### DPI![pro](./assets/pro.svg) :id=dpi
+
+```
+dpi:%dpi
+```
+
+When set, imgproxy will replace the image's DPI metadata with the provided value. When set to `0`, imgproxy won't change the image's DPI or will reset it to the default value if the image's metadata should be stripped.
+
+**📝 Note:** This processing option takes effect whether imgproxy should strip the image's metadata or not.
+
+Default: `0`
+
 ### Strip color profile
 
 ```

+ 11 - 0
docs/getting_the_image_info.md

@@ -55,6 +55,7 @@ imgproxy responses with a JSON body and returns the following info:
 * `exif`: Exif data
 * `iptc`: IPTC data
 * `xmp`: XMP data
+* `photoshop`: Photoshop metadata (currently, only the resolution data)
 * `video_meta`: metadata from the video
 
 **📝 Note:** There are lots of IPTC tags in the spec, but imgproxy supports only a few of them. If you need some tags to be supported, just contact us.
@@ -98,6 +99,16 @@ imgproxy responses with a JSON body and returns the following info:
     "photoshop": {
       "DateCreated": "2016-09-11T18:44:50.003"
     }
+  },
+  "photoshop": {
+    "resolution": {
+      "XResolution": 240,
+      "XResolutionUnit": "inches",
+      "WidthUnit": "inches",
+      "YResolution": 240,
+      "YResolutionUnit": "inches",
+      "HeightUnit": "inches"
+    }
   }
 }
 ```