Android Image Handling
<p>I am implementing one application in which I am attaching images to issues. These attachments are of two types,</p>

<ol>
<li>attachment by using camera</li>
<li>attachment of photo from gallery (already existing photo in gallery)</li>
</ol>

<p>I getting thee Images as follows</p>

<pre><code>//Camera Request
Intent captureImage = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE);

captureImage.putExtra(android.provider.MediaStore.EXTRA_OUTPUT, imageFileUri);
startActivityForResult(captureImage, CAMERA_PIC_REQUEST);

// Gallery Pic request
Intent intent = new Intent(Intent.ACTION_PICK,
        android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI);
        startActivityForResult(intent, GALLERY_PIC_REQUEST);
</code></pre>

<p>The result of above is URI. And I am saving this uri.getPath() in my database.</p>

<p>Now problem is when I want to show these images I am fetching it with the help of uri 
I am having. But I am getting following exception after loading first image
java.lang.OutOfMemoryError: bitmap size exceeds VM budget</p>

<p>I read some blogs and I came to know that memory is insufficient for loading it.</p>

<p>Is anybody having working solution on compressing images while showing them in a list.
And recycle memory used after work is done.</p>
