What is the most efficient way to load my saved jpg file into ImageView?

I have valid jpg files and now I want to load them into a layout containing ImageView. I have code for findViewId (R.id.myimage). I followed a few code examples using File, but that didn't work. The file is stored in /data/data/com.myapp/files/someimage.jpg.

What is the easiest and most efficient way to load and display?

+7
android jpeg load imageview
source share
1 answer
((ImageView)view).setImageBitmap(BitmapFactory.decodeFile("/data/data/com.myapp/files/someimage.jpg")); 

With a bit of information, you give everything I can do.

+13
source share

All Articles