Crop a set number of pixels from all sides of an image | Scene7
Last updated on Apr 27, 2021 06:58:07 AM GMT
How can I crop a set number of pixels from an image if the dimensions are unknown? The crop parameter wants to know the width and height, but these measurements differ between images.
Use the extend parameter instead of crop. For example, to crop 20 pixels from all four sides, supply negative values for left, right, top, and bottom:
For more information, see extend in the Dynamic Media Image Serving and Rendering API.