1

OutOfMemory decoding image with inJustDecodeBounds=true

view story
linux-howto

http://stackoverflow.com – I continuously get OutOfMemory exceptions trying to decode an image from camera in my Android app. There are many questions dealing with the problem, but my case is especially weird because I get the exception even when just trying to get the bounds with options.inJustDecodeBounds=true. Here's the code that starts the camera: protected void takePicture() { Intent takePictureIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE); File image = new File(IMAGE_PATH, "camera.jpg"); takePictureIntent.putExtra(MediaStore.EXTRA_OUTPUT, Uri.fromFile(image)); startActivityForResult(takeP (HowTos)