• Advertisement
Sign in to follow this  

SDL help

This topic is 4866 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I downloaded the third cone 3d tutorial for SDL, and am completly lost. I dont know how to use multiple source files, which is how the code is set up. so can somebody tell me how they work together? [Edited by - jakpandora on September 21, 2004 6:41:02 PM]

Share this post


Link to post
Share on other sites
Advertisement
Tutorial right here on gamedev. Good luck, basically you just have to understand compiling and linking, and what problems can occur when you have multiple source files.

Link to tutorial.

Share this post


Link to post
Share on other sites
ok, thanks. Also, I also seem to have trouble understanding everything thats going on with all the drawing functions and stuff. Is it ok if I dont 100% know of everything thats going on all the time?

Share this post


Link to post
Share on other sites
Basically, you have to know how to use a function or class, what it does, what parameters it takes, how to set it up properly etc. You can get by fine without knowing what goes on under the hood.

The only way to know whether to know enough or not is to try and accomplish something and see if you can do what you want. If you get errors or it doesn't work, you need to ask questions or do more research, but I'm sure you know that [wink].

Seems like you feel guilty about not knowing everything and if you feel inclined to learn more, then go for it! I'd say it is OK if you don't know 100% of everything.

Share this post


Link to post
Share on other sites
ok, thanks. just one last question. when ever I try to speed things up (the movement of an object) it leaves this weird trail behind it. I cant post my code at the moment, but I hope this is just some type of simple error someone can aswer without it. I will post it in a few hours if its needed.

Share this post


Link to post
Share on other sites
your probably forgetting to "clear" the screen.

you see, how it works is, once you draw something to the screen, its there forever. which means, you have to cover-up everything thats old, or "clear" the screen.

you can either just re-draw the entire background each frame, before you draw all your objects, OR, you can draw a piece of that background each frame, the piece which is behind the object that moved.

Share this post


Link to post
Share on other sites
ok, thanks. I actually think ill be switching to allegro, now, since I just bought a book that uses allegro for graphics.(it also seems a lot easier to learn then SDL)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement