-
Notifications
You must be signed in to change notification settings - Fork 40
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
Too slow cropping and result is too big #51
Comments
I also encountered this issue. The first one to use this library was the original file size of 451.41kb, but after completing the task, it was 1.3mb, which is obviously unreasonable. By the way, its size is also larger than the original file |
Our focus currently is on the customisability and getting images the same size. Feel free to look into speeding it up and creating a PR 🙂. I myself have no experience in optimising/compessing images 😬. |
怎么解决的这个问题呢? |
我现在并没有解决。。。。 |
@ikbendewilliam maybe this one should not be closed but kept open and requesting help from the community. This is probably because the crop is done on the canvas. not on the image itself. And taking a snapshot of the canvas. I think in the future it would be better to not use the canvas for cropping. Although it has not been updated at least 4 people are having this issue and could maybe use some love. Having the ticket open allows other people to contribute 🤷 just a suggestion. |
@vanlooverenkoen The main reason I closed this is time, i'd love to give this package more love as it is being actively used, but that is not in my control atm. If anybody has the time, feel free to investigate. There are probably better/faster ways than using a canvas. |
Trying to crop a 5Mb jpeg image leads to 10 secs. cropping process and the resulting file size if about 50Mb.
If I crom a small jpeg image (about 80Kb) then the process is fast but still have large output (about 1.7Mb).
It seems like the the library firs makes a raw bitmap then crops it and again returns an uncompressed bitmap.
Would be great if output file is compessed with the same format and quality as the input image.
And for sure cropping process itself should be speed up.
The text was updated successfully, but these errors were encountered: