title: encoded image in base64 back to image
body: <p>so I am trying to take a string for an image I encoded using base64 and turn it back into an image I can use in an ImageView. The code to encode it is:</p>
  
  <pre><code>final Bitmap bitmap = BitmapFactory.decodeFile(fileUri.getPath(), options);
  ByteArrayOutputStream baos = new ByteArrayOutputStream();
  bitmap.compress(Bitmap.CompressFormat.JPEG, 100, baos);
  byte[] b = baos.toByteArray();
  image_str = Base64.encodeToString(b, Base64.DEFAULT);
  </code></pre>
  
  <p>I'm assuming it would be convert image_str back to a byteArray then back to bitmap?</p>
  
  <p>I am not very familiar with base64 functions so I figured I would ask here while I search, to get more done in the same amount of time.</p>
  
  <p>Thank you in advance,</p>
  
  <p>Tyler</p>
  
  <p>EDIT: I did find this bit of code but the image does not show up and logcat says decode returned false:</p>
  
  <pre><code>byte[] imageBytes=Base64.decode(imageString,Base64.NO_WRAP);
  InputStream in = new ByteArrayInputStream(imageBytes);
  Bitmap b = BitmapFactory.decodeStream(in);
  </code></pre>