Source Image Region region
Specify a rectangular region of the source image to extract before applying any other resizing parameters.
Values
The parameter expects four integer values, separated by commas without spaces, in the format x,y,width,height:
-
x: the horizontal offset (in pixels) from the left edge of the image, starting at 0.
-
y: the vertical offset (in pixels) from the top edge of the image, starting at 0.
-
width: the width (in pixels) of the region to extract, with a minimun value of 1.
-
height: the height (in pixels) of the region to extract, with a minimum value of 1.
If no region parameter is provided, the entire source image region is used by default.
Examples
With the following example we are not specifying a region value, so the entire source image is used:
GET
https://assets.imglab-cdn.net/beach.jpeg
The next example will demonstrate how to extract a specific area of the image using the value region=1250,800,1000,500:
GET
https://assets.imglab-cdn.net/beach.jpeg?region=1250%2C800%2C1000%2C500