开发者

My App crashes if image size is larger than heap size

开发者 https://www.devze.com 2023-03-10 11:45 出处:网络
I am coding for audio, video, images streaming using JSON and doing image editing. In image editing there are two options - either use camera or pick image from gallery. The camera works fine.

I am coding for audio, video, images streaming using JSON and doing image editing.

In image editing there are two options - either use camera or pick image from gallery. The camera works fine.

But when I pick image from gallery and when I choose image which is being snap开发者_运维百科ped by camera and been stored in phone gallery, app crashes and if I choose default images app works fine.

But it works fine I use higher version android phone or costlier phone may they would have high heap size

So the question is how can I increase heap memory?

Presently testing on HTC Wildfire


You can not increase the heap on android devices, so you will need to hunt down memory leaks in your app to make sure you got as much heap free as possible.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号