croogie
8/20/2013 - 10:01 PM

Read assets' file From http://www.vogella.com/articles/Android/article.html#view_overview

  // Get the AssetManager
    AssetManager manager = getAssets();

    // Read a Bitmap from Assets
    InputStream open = null;
    try {
      open = manager.open("logo.png");
      Bitmap bitmap = BitmapFactory.decodeStream(open);
      // Assign the bitmap to an ImageView in this layout
      ImageView view = (ImageView) findViewById(R.id.imageView1);
      view.setImageBitmap(bitmap);
    } catch (IOException e) {
      e.printStackTrace();
    } finally {
      if (open != null) {
        try {
          open.close();
        } catch (IOException e) {
          e.printStackTrace();
        }
      }
    }