Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request for video support #42

Closed
joachimbulow opened this issue May 11, 2024 · 6 comments
Closed

Request for video support #42

joachimbulow opened this issue May 11, 2024 · 6 comments
Labels
enhancement New feature or request

Comments

@joachimbulow
Copy link

Are there any plans on releasing support for video?

Would be insanely helpful, also since the wechat_assets_picker library supports it

@joachimbulow
Copy link
Author

@LeGoffMael
I would be willing to work on this.
Would you be willing to guide me in the right direction?

@rezam92
Copy link

rezam92 commented Jun 11, 2024

@LeGoffMael
Copy link
Owner

I discussed about this feature in another issue :

Video crop support would be indeed a really nice feature to this package, but requires a lot of work and time that i unfortunately won't have soon. My plan is to adapt my other package video_editor, to use a similar UI than the one used in this package. I also have to think about the exportation process, if on the device or not. If you're motivated and want to help build this feature, you could check how to adapt the video_editor crop UI (LeGoffMael/video_editor#114), if you could open a PR with this feature i would love to review it.

If you just want to display videos & images, you can look into the example i made in flutter_wechat_assets_picker. There is no crop action, but you can select either images, videos or both. Although it seems that there is some issue with the video player (fluttercandies/flutter_wechat_assets_picker#416), it might help you to achieve your goal.

The goal of this package is to be able to pick (one or more) assets of the same crop ratio value.

To support video assets, my current idea is to :

  • update the picker to allow video assets (similar to @rezam92 work in Add support Video #44)
  • update the current crop view to support a video thumbnail or a video player
  • save the crop values for each videos and return them in onCompleted
  • create a new widget to allow user to preview the selected videos with the returned crop values (maybe something similar to CropTransform widget from video_editor).
  • then it would be up to the user to actually perform the video crop encoding (by using FFmpeg, their own video server, ...)

Other features might be requested (trim, maxDuration, minDuration, ...) so this is just a basic implementation of what could be needed.

@LeGoffMael LeGoffMael mentioned this issue Jul 14, 2024
9 tasks
@LeGoffMael
Copy link
Owner

LeGoffMael commented Jul 14, 2024

New prerelease v3.0.0-dev.1 is out. It now supports video 🎉

The video processing must be handle on your side.

Please check the readme, changelog and migration_guide to see what changed.
You can also check the example app to see how to use it.

I made a prerelease to be sure everything is fine before the major release. I am leaving this issue open for now so people can add comment in case of issues

@joachimbulow
Copy link
Author

Wow nuts!
Unfortunately we had to implement out own solution from scratch.
Well done though, congrats 🎉 🎉

@joachimbulow
Copy link
Author

CLosing this i suppose ^^

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants