Imgix APIsVideo APIShort-Form VideoSizeVideo Source Rectangle Region

Video Source Rectangle Region

rect

By default, the entire video is used as the area for processing. The rect parameter selects a sub-region of the source video to use for processing before applying other resize operations.

The value for rect is four integers or relative values representing the starting coordinates of x and y and the width and height, all separated by commas.

x can take either an integer, float, or left, center, and right options. left is equivalent to 0, center is equivalent to half of the difference of the video width minus the rect width, and right is the difference between the video width minus the rect width.

Similarly, y can take either an integer, float, or top, middle, and bottom options. top is equivalent to 0, middle is equivalent to the half the difference of the video height minus the rect height, and bottom is equivalent to the difference of the video height minus the rect height.