Jump to content
  • Advertisement
Sign in to follow this  
Terminalkillah

Which to choose

This topic is 4515 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 all, Im in bit of a pickle at the moment beacause im trying to decide which to use between SDL, DirectX and OpenGL i have tried using all 3 and found that i still coudnt decide on which to use. I know there must be a million other threads like this but i just want to know what the pro's and con's of each one are then using this information i can then decide on which to use Cheers

Share this post


Link to post
Share on other sites
Advertisement
Personal preference and most importantly, target audience.

If you're working on a simple 2D game for yourself and your friend, SDL would probably be the best route because it is the easiest. If you want 3D graphics with portability then OpenGL. If you're not concerned with portability then probably DirectX. OpenGL is easier to get up and running with that Direct3D, but becoming comfortable with the Direct3D API will get you working with a common API for sound, networking, etc whereas with OpenGL you have to find other means.

Beyond that, just use what strikes your fancy. Both OpenGL and Direct3D are industry standards.

Share this post


Link to post
Share on other sites
If you are pretty new to programming, I would suggest starting with SDL. It's designed to be very easy to use (the 'S' stands for simple!) and it comes with everything you need (ie, you don't need Win32).

Also, once you get the hang of it, it can be used as a great framework for OpenGL (and event Direct3D).

Also don't listen to those who tell you "DirectX is better because once you learn Direct3D, DirectSound and DirectInput etc. will be easier." I don't care if you know what "lpUnkown" means or not, SDL or FMOD is way easier than any DX API!

Good Luck!

Share this post


Link to post
Share on other sites
Before I started using the Irrlicht Engine, I was using OpenGL for graphics and DX for sound and input. I liked OpenGL because it was easier to work with. But since it doesn't do anything but graphics, I learned DX for that and input, since it is free to use. FMOD, BASS etc... as far as I know cost money for a commercial project, but fro non-commercial are free. Since I wanted to get into more complex development of games, I was going to have to either make my own engine or use one, so I went with Irrlicht. I hadn't heard of SDL when I was API hunting so I can't appropriately comment, but I have seen many compliments for it. Plus you should be able to use SDL for input and window initialization and connect the window to OpenGL to get hardware accelerated 3d graphics.

Share this post


Link to post
Share on other sites
If you are just starting out I would say go with SDL. It will give you an idea on how to setup the library with your compiler and then include files and such. If you want to do something with 3D graphics then go for DX or OpenGL. I know that there are a lot of good OpenGL & DX tutorials around but you might want to pick up a book to have as a reference. So I'd say for 2D and small games go with SDL. Graphics demos and 3D go with DX or OpenGL.

Share this post


Link to post
Share on other sites
Cheers guys a lot of good points about the three. I think i will go with SDL beacause i am a complete begginer to game design and programming but i have basic knowlege in C++. But i am also doing a night school course in games design and programming using visual basic which is getting my feet wet in designing games but i want to do this as a career im going to have to advance to c++ and directx and such...

Cheers for all the help you guys its much appreciated

Terminalkillah

Share this post


Link to post
Share on other sites
I enjoy using SDL. It has alot of power and can really help you out, especially as a beginner. Later on when(if) you move into OpenGL, you can still use SDL to do input, sound, networking, and pretty much anything else that you'd need.

SDL has a good amount of tutorials out there and excellent documentation. However, it can't compeat with OpenGL and DirectX with tutorials.

Unless you need blazingly fast performance, go with SDL.

Share this post


Link to post
Share on other sites
Quote:
Original post by Ezbez
I enjoy using SDL. It has alot of power and can really help you out, especially as a beginner. Later on when(if) you move into OpenGL, you can still use SDL to do input, sound, networking, and pretty much anything else that you'd need.

SDL has a good amount of tutorials out there and excellent documentation. However, it can't compeat with OpenGL and DirectX with tutorials.

Unless you need blazingly fast performance, go with SDL.


SDL can be used with both OpenGL and Direct3D(if you REALLY wanted to).

Share this post


Link to post
Share on other sites
Quote:
Original post by Ezbez
I enjoy using SDL. It has alot of power and can really help you out, especially as a beginner. Later on when(if) you move into OpenGL, you can still use SDL to do input, sound, networking, and pretty much anything else that you'd need.

SDL has a good amount of tutorials out there and excellent documentation. However, it can't compeat with OpenGL and DirectX with tutorials.

Unless you need blazingly fast performance, go with SDL.


Depending on what you are doing, SDL will give you blazingly fast performance on modern CPU's. If you stick to pure pixel pushing at moderate resolutions and low bpp, SDL is very fast. However, one of the things that does annoy me is not being able to synchronize with the monitor's vertical retrace.

And for the documentation, SDL is certainly on competing terms. For tutorials, SDL may even win. MS does put out some great documentation for Direct3D and there are many tutorials for that too. I have found OpenGL documentation post version 1.1 to be lacking.

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!