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

On Flutter 3.7.9 this package returns only empty image on web #24

Open
NZhlebinkov opened this issue Apr 28, 2023 · 4 comments
Open

On Flutter 3.7.9 this package returns only empty image on web #24

NZhlebinkov opened this issue Apr 28, 2023 · 4 comments
Labels
question Further information is requested

Comments

@NZhlebinkov
Copy link

I used the example code from here: https://pub.dev/packages/crop_image/example and changed the photo to a local jpg asset that I have.

I run the code with CanvasKit and profile mode as outlined here and here

And I have all the nice buttons, I can rotate and select aspect ratios and all, and when I click done I see the correct Rect has been calculated. However the cropped image is not displayed.

I've spent hours debugging and what I've found is that the image contains only 0s. What does that mean?

final bitmap =  controller.croppedBitmap();
final bytes = (await bitmap.toByteData())?.buffer.asUint8List();

here, the bytes are all 0 when I print them.

I haven't found a way to use this package on web on Flutter 3.7.9, has anyone else been able to get it to work?

@deakjahn
Copy link
Owner

Does this mean from 3.7.9 onwards or specifically on that version? We're on .12 stable now and I couldn't reproduce the issue there.

@deakjahn deakjahn added the question Further information is requested label Apr 30, 2023
@JimRoid
Copy link

JimRoid commented May 3, 2023

me too just empty in app browser( ios , android) . desktop web can run

1 similar comment
@dev-devarsh4
Copy link

me too just empty in app browser( ios , android) . desktop web can run

@deakjahn
Copy link
Owner

Which Flutter version did you try it on?

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

No branches or pull requests

4 participants