title: Android BitmapFactory.decodeFile(path) always returns null
body: <p>I see that is a lot of solutions related to this issue, but none of this solved my problem.</p>
  
  <p>I try to read image from png file to bitmap (image is very small ~16px so there is no option that I got OutOfMemoryException) using BitmapFactory.decodeFile(path) function.</p>
  
  <p>My file hierarchy is as simple as possible:<br>
  -java<br>
  --example.com.app<br>
  ---MainActivity.class<br>
  -res<br>
  --drawable<br>
  ---array.png<br></p>
  
  <p>I launch application from MainActivity and on button click I try to read png image to bitmap.
  I try to read image to bitmap in the following ways:</p>
  
  <ol>
  <li><p><code>String path = Uri.parse("android.resource://"+R.class.getPackage().getName() +"/drawable/arrow.png").toString();
  Bitmap bitmap = BitmapFactory.decodeFile(path);</code></p></li>
  <li><p><code>String path = Uri.parse("android.resource://drawable/arrow.png").toString();
  Bitmap bitmap = BitmapFactory.decodeFile(path);</code></p></li>
  </ol>
  
  <p>Everytime bitmap is null. Do you know where could be a problem?</p>
  
  <p><br>Android API 27<br></p>