GoogleForCreators / web-stories-wp

Web Stories for WordPress
https://wp.stories.google
Apache License 2.0
768 stars 178 forks source link

Media: Actually crop images when using zoom/masks #8715

Closed spacedmonkey closed 1 year ago

spacedmonkey commented 3 years ago

Feature Description

Currently in the stories editor, there is functionality to "crop" images. This doesn't not create new file, but uses masks to zoom in to image. Meaning that, a user could zoom into a section of an image they wish displayed. However, it does mean that the full image is downloaded on the story / in the editor. For a large image, this could be wasteful.

In WordPress 5.5, functionality to edit inline image was added. To enable this functionality, a new REST API for editing images was added. This api includes functionality to crop and rotate images.

Alternatives Considered

Additional Context


Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance Criteria

Implementation Brief

swissspidy commented 3 years ago

Related: #5985

spacedmonkey commented 2 years ago

I wonder if we should revisit this, as the WP min version has been increased. This should be simple as they is an existing endpoint for this.

swissspidy commented 2 years ago

I want to explore this as part of the video cropping epic, using FFmpeg to do this task client-side so it works for both images and videos.

swissspidy commented 1 year ago

Closing in favor of #5985