- Online Community Forums » Allegro Development » al_set_target_bitmap problem

This thread is locked; no one can reply to it. rss feed Print
al_set_target_bitmap problem
Addison Elliott
Member #12,394
November 2010

I received a ASSERT output in my program once I turned on the debugging. I am pretty sure this is a small bug that wouldn't hurt to fix.
I have seperate threads that load bitmaps and so I have to call al_set_target_bitmap to set the display backbuffer as the target.
al_set_target_bitmap has this line of code(which caused the program to quit):
I looked into it, and that function returns false if al_get_current_display returns false. So, I am calling the function to set the current display, and it requests for the current display, causing an ASSERT. Kinda ironic :P

Peter Wang
Member #23
April 2000

That seems right. al_get_current_display returns NULL, then al_is_bitmap_draw_held returns false, which means the assertion is true.

Edgar Reynaldo
Major Reynaldo
May 2007

Go to: