How does Cloudflare Images gravity parameter work?
Hi! I'm passing coordinates a Cloudflare Images transform via URL into the gravity parameter. It is working, but not quite how I'd expect.
From the docs: "...will crop each side to preserve as much as possible around a point at 20% of the height of the source image."
This leads me to believe that it'd center the crop around the coordinates as much as possible, which is what I want.
Also from the docs: "...this parameter defines the side or point that should not be cropped."
This leads me to believe that it'd crop to the center of the image as much as possible while still preserving the coordinates. This is actually what's happening. So in my specific case, the focal point coordinates are preserved, but they are at the very top of the image even though there's more image beyond that so it could get the coordinates closer to the center of the crop.
Just trying to understand how it's supposed to be working and then if there's a way to pass the focal point so that it compensates against this behavior to better center the coordinates.
From the docs: "...will crop each side to preserve as much as possible around a point at 20% of the height of the source image."
This leads me to believe that it'd center the crop around the coordinates as much as possible, which is what I want.
Also from the docs: "...this parameter defines the side or point that should not be cropped."
This leads me to believe that it'd crop to the center of the image as much as possible while still preserving the coordinates. This is actually what's happening. So in my specific case, the focal point coordinates are preserved, but they are at the very top of the image even though there's more image beyond that so it could get the coordinates closer to the center of the crop.
Just trying to understand how it's supposed to be working and then if there's a way to pass the focal point so that it compensates against this behavior to better center the coordinates.