Get Bitmap image from the given Asset path - Android App

Android examples for App:Assets Image

Description

Get Bitmap image from the given Asset path

Demo Code


//package com.java2s;

import android.graphics.Bitmap;
import android.graphics.BitmapFactory;

public class Main {
    /**//from  w ww. ja  v  a2s . c  o m
     * Get image from the given path
     * @param path
     * @return
     */
    public static Bitmap getImageFromPath(String path) {
        return BitmapFactory.decodeFile(path);
    }
}

Related Tutorials