Mail Archives: djgpp/2001/06/09/04:01:01
Dirk Pawlowski wrote in message
news:Xns90BB60C66B2B6vandyrkgmxde AT user DOT dfncis DOT de:
[snip]
> #include "allegro.h"
>
> int main()
> {
> BITMAP *b;
> allegro_init();
> install_keyboard();
> set_gfx_mode(GFX_VGA , 640, 480, 0, 0); // no different
> if I use
> AUTODETECT
> putpixel(b, 12, 12, 1);
> return 0;
> }
>
> After compiling this program (no errors!!!) I start the
> exe-File and get the following error message:
>
> Shutting down Allegro
> Exiting due to signal SIGSEGV
[snip]
Read your code before reading the FAQ. You are trying to put a
pixel on the BITMAP b. But b is just a pointer, pointing
somewhere, to something and nobody knows where. You will have to
create that bitmap first (b = create_bitmap (width, height); ).
Manni
- Raw text -