i'm having problem in loading image coming from the internal storage of my android phone. I want to load the image and use it for grabcut segmentation.
I tried using this code
File file = new File(getExternalFilesDir(null).getAbsolutePath()+"pic.jpg");
ImageView iv = (ImageView) findViewById(R.id.imagePreview);
Bitmap bitmap = BitmapFactory.decodeFile(file.getAbsolutePath());
But everytime I run the app on my phone the application suddenly stopped. Can I ask for help and know what's wrong in my code? Thank you so much.