Android Camera Intent - Out Of Memory Error and Rotation Error

梦想与她 提交于 2019-12-06 03:14:30

A way to fix your out of memory error would be to use Bitmap.Factory Options, this has an option that will allow you to decode the image as a scaled image so it won't use quite so much memory, the downside to this, is that the resulting image will be somewhat smaller. Its a setting that you could play with and potentially fine tune to get it to an acceptable loss. Also you will want to call p.dispose() on your first bitmap immediately after you have created your second bitmap. Follow this link for an example: http://tutorials-android.blogspot.co.il/2011/11/outofmemory-exception-when-decoding.html

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!