[SDL] segfault in SDL_RLEACCEL | SDL_SRCCOLORKEY

paul at theV.net paul at theV.net
Sun Feb 17 07:26:00 PST 2002


My program segfaults using SDL_RLEACCEL | SDL_SRCCOLORKEY,
but runs fine with SDL_SRCCOLORKEY alone.

But testsprite in SDL test suite runs fine with the above
setting. The only different is, testsprite.c is using a
surface with palette. My surface is a SDL_SWSURFACE with
same video format as main screen surface.

I am using SDL 1.3, below is the trace:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 32728)]
0x40087af9 in SDL_RLEAlphaBlit (src=0x87f5200, srcrect=0xbffff1ec, dst=0x89d61c0, 
    dstrect=0xbffff25c) at SDL_RLEaccel.c:865
865                     RLEALPHABLIT(Uint16, Uint8, BLIT_TRANSL_565);
Current language:  auto; currently c
(gdb) where
#0  0x40087af9 in SDL_RLEAlphaBlit (src=0x87f5200, srcrect=0xbffff1ec, dst=0x89d61c0, 
    dstrect=0xbffff25c) at SDL_RLEaccel.c:865
#1  0x4009b230 in SDL_LowerBlit (src=0x87f5200, srcrect=0xbffff1ec, dst=0x89d61c0, 
    dstrect=0xbffff25c) at SDL_surface.c:369
#2  0x4009b3f0 in SDL_UpperBlit (src=0x87f5200, srcrect=0xbffff264, dst=0x89d61c0, 
    dstrect=0xbffff25c) at SDL_surface.c:459

Is there any way to solve this problem? I mean, my surface
is encoded fine with SDL_RLEACCEL | SDL_SRCALPHA, but just
couldn't work with SDL_SRCCOLORKEY.

Regards,
.paul.




More information about the SDL mailing list