Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4362: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4364: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4365: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4366: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
anddev.org • View topic - How to avoid a Bitmap to be recycled?

How to avoid a Bitmap to be recycled?

Problems with Canvas, OpenGL, etc...

How to avoid a Bitmap to be recycled?

Postby gskbyte » Mon Jun 28, 2010 10:26 pm

Hi,

I'm writing a small app in which I load a sample Bitmap and modify it several times. Each modification is saved inside a static Vector<Bitmap>. The problem is that when I call canvas.drawBitmap(mBitmaps.get(i));, it throws a NullPointerException because the bitmaps are recycled.

Is it possible to avoid the bitmaps to be automatically recycled?

Thank you!
gskbyte
Experienced Developer
Experienced Developer
 
Posts: 52
Joined: Tue Jan 12, 2010 1:51 pm

Top

Re: How to avoid a Bitmap to be recycled?

Postby Zael » Thu Oct 07, 2010 6:56 pm

I am having a similar problem with Bitmaps in an array. They load fine (BitmapFactory doesn't return null), but later when I try to use them, I find that several have become null (recycled), while others are still available. I am fairly certain I am not setting any bitmaps to null myself. Did you, gskbyte, or anybody else ever figure out a solution to this problem?

Thanks.
Zael
Freshman
Freshman
 
Posts: 5
Joined: Tue Oct 05, 2010 8:43 pm

Top

Return to Android 2D/3D Graphics - OpenGL Problems

Who is online

Users browsing this forum: No registered users and 4 guests