It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened,
visit the help center.
Closed 7 years ago.
How can I show a thumbnail from a fixed image path in an ImageView?
you can create Image thumbnail from the image path as:
public Bitmap getbitpam(String path){
Bitmap imgthumBitmap=null;
try
{
final int THUMBNAIL_SIZE = 64;
FileInputStream fis = new FileInputStream(path);
imgthumBitmap = BitmapFactory.decodeStream(fis);
imgthumBitmap = Bitmap.createScaledBitmap(imgthumBitmap,
THUMBNAIL_SIZE, THUMBNAIL_SIZE, false);
ByteArrayOutputStream bytearroutstream = new ByteArrayOutputStream();
imgthumBitmap.compress(Bitmap.CompressFormat.JPEG, 100,bytearroutstream);
}
catch(Exception ex) {
}
return imgthumBitmap;
}
call this method on filepath click to show Image thumbnail in ImageView