I'm trying to save a bitmap to the sd card and by using the string returned in Media.insertImage, create an instance of the bitmap later on. But recreating it is not working. It is saving the bitmap correctly as i can see it in the gallery app but i just can't get the bitmap path correct or something. Any help i would really appreciate. Here is what I'm doing.
Bitmap image = Bitmap.createBitmap(this.getWidth(), this.getHeight(), Bitmap.Config.RGB_565);
this.draw(new Canvas(image));
String s = Images.Media.insertImage(Mycontext.getContentResolver(), image, "mytitle", null);
and I'm trying to recreate it later on in the application where loc = s from above:
Bitmap bmp = BitmapFactory.decodeFile(loc);
Use:
Images.Media.getBitmap(Mycontext.getContentResolver(), Uri.parse(loc))