How to speed up opening .png bitmaps on Android?
<p>Welcome all</p>

<p>actually i'm opening png files from assets folder with this code:</p>

<pre><code>public static Bitmap loadImage( String imageName ){
    if( imageName.charAt(0) == '/' ) {
        imageName = imageName.substring(1);
    }
    imageName = imageName + ".png";
    Bitmap image = BitmapFactory.decodeStream(getResourceAsStream(imageName));
    return image;
}
public static InputStream getResourceAsStream( String resourceName ) {
    if( resourceName.charAt(0) == '/' ) {
        resourceName = resourceName.substring(1);
    }

    InputStream is = null;
    try {
        is = context.getAssets().open( resourceName );
    } catch (IOException e) {e.printStackTrace();}
    return is;
}
</code></pre>

<p>This code opens the bitmaps with full cuality and it takes a lot of time to open it. </p>

<p>Also any sugerences to speed up the opening of the bitmap will be welcome</p>

<p>Thanks in advance</p>
