Unix Programming - howto stretch an image with SDL

This is Interesting: Free IT Magazines  
Home > Archive > Unix Programming > January 2004 > howto stretch an image with SDL





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author howto stretch an image with SDL
atv

2004-01-23, 5:15 pm

Hi,

i'm trying to load a background, which is a tile, but how do you let it
draw to the entire screen? or stretch it? I tried using SDL_BlitSurface
and changing the width and height variables returned by IMG_Load from
SDL_Image but that doesn't work. Or it works, but just changes the
surface coordinates.

I'm trying to build a simple game, and need to have a scrolling
background. I'm assuming a tile is the way to go, for a simple
background, and then stretch it.

Any help is welcome
thx
atv

Chuck Dillon

2004-01-23, 5:16 pm

atv wrote:
quote:

> Hi,
>
> i'm trying to load a background, which is a tile, but how do you let it
> draw to the entire screen? or stretch it? I tried using SDL_BlitSurface
> and changing the width and height variables returned by IMG_Load from
> SDL_Image but that doesn't work. Or it works, but just changes the
> surface coordinates.



This really isn't the forum to ask your question. I suggest you ask
in a forum that specifically deals with SDL. Google.com is your friend.

-- ced
quote:

>
> I'm trying to build a simple game, and need to have a scrolling
> background. I'm assuming a tile is the way to go, for a simple
> background, and then stretch it.
>
> Any help is welcome
> thx
> atv
>




--
Chuck Dillon
Senior Software Engineer
NimbleGen Systems Inc.

Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com