Search code examples
javaandroidbitmapandroid-imageviewuniversal-image-loader

Display images from Drawable folder using Universal Image Loader


I want to load image from Drawable folder using Universal Image Loader (NOSTRA my code is below

imgLoader = ImageLoader.getInstance();
imgLoader.init(new ImageLoaderConfiguration.Builder(this).build());

Now i am loading image in wallImage (ImageView) below is my code

imgLoader.displayImage("drawable://" + result, wallImage);

my problem is, it is taking to much time to load image. Can anybody give me solution what should I have to do ?


Solution

  • Imgloader.displayImage("drawable://" + result, wallImage); 
    

    this method is not recommending for loading the images in drawable... You should use native method as Vigbyor as suggested

    imageview.setImageResources(res id);