Jump to content
  • Advertisement
Sign in to follow this  
Azzazil

SDL or OpenGL

This topic is 3269 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

Hi, guys I'm beginner in game programming so I don't know which is better SDL or OpenGL, and which is book good for beginner in game programing. I hope that you understand me

Share this post


Link to post
Share on other sites
Advertisement
Quote:
Hi, guys I'm beginner in game programming so I don't know which is better SDL or OpenGL, and which is book good for beginner in game programing.
The question 'which is better, SDL or OpenGL' doesn't really mean anything (it's kind of like asking which is better, a hammer or a screwdriver).

Maybe what you're meaning to ask is, 'which is better, SDL alone using software blitting, or SDL with hardware accelerated graphics via OpenGL?'. Before trying to answer that question though, I think it'd be helpful to know a little more about your situation. Have you already learned or started to learn a programming language? If so, which one? What platforms/OSs are you wanting to target? What types of games are you wanting to make?

Share this post


Link to post
Share on other sites
Typically, you only learn how to use OpenGL if you want to learn graphics programming. If you want to make games, start using a library of some type. Maybe Allegro, Ogre, etc. Later, if you are interested in graphics programming you can come back to the low-level stuff. But in the beginning, you want something that can give you faster results or you will be more likely to become frustrated and overwhelmed.

Share this post


Link to post
Share on other sites
Quote:
Original post by jyk
Quote:
Hi, guys I'm beginner in game programming so I don't know which is better SDL or OpenGL, and which is book good for beginner in game programing.
The question 'which is better, SDL or OpenGL' doesn't really mean anything (it's kind of like asking which is better, a hammer or a screwdriver).

Maybe what you're meaning to ask is, 'which is better, SDL alone using software blitting, or SDL with hardware accelerated graphics via OpenGL?'. Before trying to answer that question though, I think it'd be helpful to know a little more about your situation. Have you already learned or started to learn a programming language? If so, which one? What platforms/OSs are you wanting to target? What types of games are you wanting to make?


Well my situation I'm solid in C++ but.
Windows and Linux.
For beginning 2D games.

Quote:
Original post by jackolantern1
Typically, you only learn how to use OpenGL if you want to learn graphics programming. If you want to make games, start using a library of some type. Maybe Allegro, Ogre, etc. Later, if you are interested in graphics programming you can come back to the low-level stuff. But in the beginning, you want something that can give you faster results or you will be more likely to become frustrated and overwhelmed.


Yes I want to make games, and I want faster results.

Share this post


Link to post
Share on other sites
When you're starting out just stick with SDL's built in graphic API's, you can add in things like SDL_rotozoom if the base API doesn't do enough. You can then add in OpenGL graphics to your SDL code when the built in API either isn't fast enough or if you want to start doing 3D effects.

Share this post


Link to post
Share on other sites
Pick up XNA its fantasic for begginers, don't bother with 2D games, get going with 3D, its all 3D now these days, even 2D games.

JonRambo

Share this post


Link to post
Share on other sites
Quote:
...don't bother with 2D games, get going with 3D, its all 3D now these days, even 2D games.
Are you sure about that? I seem to recall playing quite a few games recently that were 'real' 2-d games.

[Edit: I agree though that given that the OP is looking for fast results, there are probably better options than C+SDL (such as XNA, or even a game authoring tool such as Game Maker).]

Share this post


Link to post
Share on other sites
If you want to target Linux as well as Windows, I don't think that XNA supports Linux. You might want to look into SFML instead of SDL. It's based more directly on OpenGL as a rendering engine but produces excellent 2d results for beginning game programming. The forums and wiki on the SFML website (linked above) will get you started really easily if you already know object-oriented C++.

Share this post


Link to post
Share on other sites
Quote:
Original post by jlwing
Pick up XNA its fantasic for begginers, don't bother with 2D games, get going with 3D, its all 3D now these days, even 2D games.

JonRambo


I didn't learn C#.
Quote:
Original post by samuraicrow
If you want to target Linux as well as Windows, I don't think that XNA supports Linux. You might want to look into SFML instead of SDL. It's based more directly on OpenGL as a rendering engine but produces excellent 2d results for beginning game programming. The forums and wiki on the SFML website (linked above) will get you started really easily if you already know object-oriented C++.


It looks easy to learn, can you show me some game made in SFML

Share this post


Link to post
Share on other sites
Quote:
Original post by jlwing
Pick up XNA its fantasic for begginers, don't bother with 2D games, get going with 3D, its all 3D now these days, even 2D games.

JonRambo


Beginning game programmers learn so much by starting off with 2D. In the beginning, it is not about the end result, but learning through experience. Most people won't be making games with mass appeal as their first few projects. 3D is a monster compared to 2D, and it can stump new game programmers pretty quickly.

Share this post


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

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!