No subject


Wed Jan 24 21:54:03 PST 2007


SDL-announce) <sdl.libsdl.org>
List-Unsubscribe: 
<http://www.libsdl.org/mailman/listinfo/sdl>,<mailto:sdl-request at libsdl.org?subject=unsubscribe>
List-Archive: <http://www.libsdl.org/pipermail/sdl/>
X-Original-Date: Mon, 1 Apr 2002 11:11:48 -0800 (PST)

Hi everyone!

Ive been dabbling and experimenting with blitting
bmps. I created a bitmap that has two images (template
2x1) and have tried to blit one image after the other
from the same bmp.

Here's my code:

SDL_Surface*bmp=SDL_LoadBMP("image.bmp");

int posx;

SDL_Rect image;

for(posx=0; posx>=1 ;posx++)

image.x=posx*51;
image.y=0;
image.w=50;
image.h=50;

SDL_BlitSurface(bmp,&image,Surface,&dest);

The total bmp size is 101 pix and each image is 50x50.
there's a line that separates the two bitmap images at
position pixel x=50. I've tried to use the for loop to
get the blitter to blit first, the bmp at (0,0) then
the image at (0,51), the upper left location of the
second image. Needless to say, it only blits one of
the images and not the second. Any ideas why and am I
way off on this idea using the for loop? If this is
unworkable, please tell me so I can stop wasting my
time trying to get this to work.

thanks

Richard



__________________________________________________
Do You Yahoo!?
Yahoo! Greetings - send holiday greetings for Easter, Passover
http://greetings.yahoo.com/

_______________________________________________
SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl



¤¤¤V¤I¤T¤A¤L¤I¤Y¤¤¤

_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp.





More information about the SDL mailing list