问题
i am saving an image by passing a bitmap to the savephoto(Bitmap function) now i want to retrieve the photo which is saved ,, how to do that i am new in android , plz give me the code of retrival and also convert it into Bitmap
public void savePhoto(Bitmap b2)
{
File imageFileFolder = new File(Environment.getExternalStorageDirectory(),"Rotate");
mageFileFolder.mkdir();
FileOutputStream out = null;
Calendar c = Calendar.getInstance();
String date = fromInt(c.get(Calendar.MONTH))
+ fromInt(c.get(Calendar.DAY_OF_MONTH))
+ fromInt(c.get(Calendar.YEAR))
+ fromInt(c.get(Calendar.HOUR_OF_DAY))
+ fromInt(c.get(Calendar.MINUTE))
+ fromInt(c.get(Calendar.SECOND));
File imageFileName = new File(imageFileFolder, date.toString() + ".jpg");
try
{
out = new FileOutputStream(imageFileName);
b2.compress(Bitmap.CompressFormat.JPEG, 100, out);
out.flush();
out.close();
out = null;
} catch (Exception e)
{
e.printStackTrace();
}
thanx helping :)
来源:https://stackoverflow.com/questions/9939719/how-to-retrieve-an-image-from-memory-card-in-this-scenario