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

[WEB] Large image sizes are missing top and right areas, with croppedBitmap #47

Open
ToddZeil opened this issue Mar 19, 2024 · 4 comments

Comments

@ToddZeil
Copy link

ToddZeil commented Mar 19, 2024

This image (7mb) which was selected from pick_image (gallery) on web.
Then cropped with croppedBitmap, has issues missing top left and right of image.
Smaller images in this case (1.1mb) and below didn't have any issues.

I could not repeat this with the example, any ideas on why this could be happening?
crop_image: ^1.0.6

Image of what is happening below.
image

[✓] Flutter (Channel stable, 3.19.3, on macOS 14.3.1 23D60 darwin-arm64, locale en-NZ)
• Flutter version 3.19.3 on channel stable
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision ba39319843 (11 days ago), 2024-03-07 15:22:21 -0600
• Engine revision 2e4ba9c6fb
• Dart version 3.3.1
• DevTools version 2.31.1

@ToddZeil
Copy link
Author

This is the result from package example (I had updated code to use croppedBitmap etc)
But no issue is found here for some reason?

image

@deakjahn
Copy link
Owner

My first port of call would be to check whether you use the modern CanvasKit or the old HTML engine.

@ToddZeil
Copy link
Author

Sorry for late reply we are using CanvasKit

@deakjahn
Copy link
Owner

Then I would create a small sample (or simply add a new function to your existing app while debugging) that would take the image and apply the same or a similar cropping logic to it with the same pixel values you finally got from this package and see whether it behaves any differently in your own code. If you see anything strange, I would experiment with various formats, JPG, PNG, transparent or opaque as well.

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

No branches or pull requests

2 participants