OutOfMemory exception as I rotating the emulator.
- by michael
I get the following OutOfMemory Error as I rotating my android emulator.
I start with Portrait mode.
I switch to Landscape mode.
And then when I switch back to Portrait mode, I get the following error:
E/AndroidRuntime( 239): java.lang.OutOfMemoryError: bitmap size exceeds VM budget
E/AndroidRuntime( 239): at android.graphics.Bitmap.nativeCreate(Native Method)
E/AndroidRuntime( 239): at android.graphics.Bitmap.createBitmap(Bitmap.java:468)
E/AndroidRuntime( 239): at android.graphics.Bitmap.createBitmap(Bitmap.java:435)
E/AndroidRuntime( 239): at android.graphics.Bitmap.createScaledBitmap(Bitmap.java:340)
E/AndroidRuntime( 239): at android.graphics.BitmapFactory.finishDecode(BitmapFactory.java:488)
E/AndroidRuntime( 239): at android.graphics.BitmapFactory.decodeStream(BitmapFactory.java:462)
E/AndroidRuntime( 239): at android.graphics.BitmapFactory.decodeResourceStream(BitmapFactory.java:323)
E/AndroidRuntime( 239): at android.graphics.drawable.Drawable.createFromResourceStream(Drawable.java:697)
E/AndroidRuntime( 239): at android.content.res.Resources.loadDrawable(Resources.java:1705)
E/AndroidRuntime( 239): at android.content.res.Resources.getDrawable(Resources.java:580)