Add focal point to images #3876
Unanswered
PaulKiddle
asked this question in
Ideas
Replies: 1 comment
-
|
Focal point support has been added in v12. You can now store a focal point per media item and use it during conversions: $media->setFocalPoint(70, 30)->save();
$media->getFocalPoint(); // ["x" => 70, "y" => 30]
$media->hasFocalPoint(); // trueConversions can opt in to use the focal point: $this->addMediaConversion("thumb")
->width(400)
->height(300)
->useFocalPoint();This uses percentage-based coordinates (0-100) and leverages |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
We do automatic image cropping in our frontend framework. Sometimes important features of these images are cut off because we don't know where the focal point of the image is.
It would be great to be able to specify an image's focal point that we can serve in our API to the frontend along with the image URL & alt text.
It could also be used as a default value when creating a new curation in the CMS UI.
Beta Was this translation helpful? Give feedback.
All reactions