-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Crash when editing some normal-sized pictures: RuntimeException Canvas trying to draw too large bitmap #5387
Comments
Thanks for reporting! Strangely it works for me on Android 14 / Pixel 7: screen-20231117-222158.mp4 |
It actually seems to work fine for me too. I tried using Simple Gallery app and the Google Photos app on a OnePlus Nord running Android 12. @mnalis could you elaborate a bit on what app you use in order to share the image? |
It was the stock EMUI12 Gallery app. But I can reproduce it by sharing from other apps, like CameraRoll too. What is notable is that in step However, I see now that it works with some pictures ( Here is the video of app both working and not working depending on the picture: small_SVID_20231128_161345_1.mp4And links to pictures (Too big to attach in issue directly):
|
Interesting, the edit feature might be failing due to some memory issue. |
Oh, so may I assume that the same picture which is failing to edit for me is working for you normally then?
Sure, here it goes (after I shared the image and clicked on
|
Also, there is a mistake in original report, sorry about that, I've sticken-out incorrect part now. I.e. bug happens even when I open the picture via |
It gets more and more interesting:
|
Another idea was that maybe landscape pictures fail, but portrait ones work, but that also seems not to be the case: e.g. this https://mnalis.com/tmp/IMG_20231123_151953.jpg is in portrait mode, but fails to show in While this one in landscape https://mnalis.com/tmp/IMG_20231030_210533.jpg works. |
To summarize:
Pictures that fail always fail, and those which work always work, even when tried several times in random orders. Can someone confirm if they can reproduce the problem with those which fail? |
Sorry I had not actually tried when I wrote my last comment. Now I tried to upload some of the various pictures you kindly provided, and can indeed see crashes (using the standard picker, I have not tried other methods such as share), for instance this one with https://mnalis.com/tmp/IMG_20231116_161908.jpg : java.lang.RuntimeException: Canvas: trying to draw too large(159694848bytes) bitmap. The message |
Thanks for verifying! As a side note, it is interesting that those error messages didn't appear to show in my |
Yes if there is none yet, thanks! |
This is an interesting bug, i will try finding a fix! |
Did you perhaps have a chance to take a look at it, @shankarpriyank ? |
Hi @mnalis I was able to reproduce the bug, i have still not had the chance to spend some time fixing it, but it's on my todo list and should be done by this weekend |
@mnalis The issue seems fixed, please try on more examples and let us know if the issue is still present. :-) |
Summary
When image is shared to Commons app via Android built-in share functionality, the
Edit
button does not show image (and thus is useless) for many (but not all) of them. It is reproducible, i.e. pictures that fail always fail, and those which work always work.However, the image is normally shown inEdit
(and can be rotated) if it has been opened from app (via+
icon and the picture icon)Steps to reproduce
share
icon and chooseUpload to Commons
Step 1/4: Media details
opens normally with picture correctly shown in the backgroundEdit image
buttonExpected behaviour
picture should be shown, along with
rotate
/save
buttonsActual behaviour
only
rotate
/save
buttons are shown, with rest of the screen being whiteDevice name
Huawei P30Pro
Android version
Android 10 (EMUI 12)
Commons app version
4.2.1 ~14b6c455b (latest f-droid)
Device logs
No response
Screen-shots
Would you like to work on the issue?
None
The text was updated successfully, but these errors were encountered: