Good!
I have a problem with the following code in Android Studio:
try {
FileInputStream fileInputStream = new FileInputStream(dirPhoto);
bitmap = BitmapFactory.decodeStream(fileInputStream);
vwImagen.setImageBitmap(bitmap);
}
catch (SecurityException io){
}
catch (FileNotFoundException io) {
}
The fileInputStream file seems to be created correctly, but when wanting to convert it to Bitmap, the function BitmapFactory.decodeStream(fileInputStream)
returns a null value.
It is worth clarifying that it is an image in jpg. The value of dirPhoto is:
/data/data/com.example.leandro.application/files/pic_20170316104409.jpg
Thank you!