Jump to content
  • Advertisement
Sign in to follow this  
ISDCaptain01

SDL+OpenGL vs DirectX

This topic is 2065 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 just cant seem to decide which one. Its either opengl+sdl or DirectX
What I like about OpenGL is that u can use outdated code or techniques and it will still run. So I dont have to keep on constantly keeping up with changes(staying on top of changes is exhausting, especially when programming isn't your income). Also sdl is easier, than again lack of books


Then on the other hand, DirectX has all documentation. All the books I wanna read use DirectX. So that's also a big deal. But DirectX keeps on changing. By the time I get the hang of it, directx12 will be out. If I were to write an engine in dx9, it would one heck of a time to get it to dx11 and add its features.
honestly what would u guys do?

also is sdl + Direct3d(just direct3d, no directsound,input, etc etc) possible Edited by ISDCaptain01

Share this post


Link to post
Share on other sites
Advertisement
SDL + Direct3D should work.
http://www.gamedev.net/page/resources/_/technical/apis-and-tools/direct3d-90-with-sdl-r2249

I'm not sure its a great idea though.

Share this post


Link to post
Share on other sites
D3D may use a different API every major version, but that doesn't mean that you have to. D3D9 is still well-supported and has been very stable for a decade or so now, for example, so if you wanted to learn that then go right ahead - there's nothing forcing you to jump to a higher version.

Share this post


Link to post
Share on other sites

IMO, learn OpenGL > 3.2. Everything except the Microsoft systems use OpenGL, better to learn 3D graphics via OpenGL and then learn Direct X when you need to.


While this is in principle true, I generally advise that when you're learning you're better off just forgetting about portability, at least for the first few programs. Your primary task is to learn, not to be portable, and if you worry over much about being portable then you're taking on a whole slew of additional headache that is just going to detract from the job of learning.

Of course helper frameworks/etc make this issue fade a little into the background, but despite that I believe that the basic core of it still stands - focus on what you're learning, not on whether or not it's portable.

Share this post


Link to post
Share on other sites

I generally advise that when you're learning you're better off just forgetting about portability, at least for the first few programs. Your primary task is to learn, not to be portable.


++ to that

I wasn't really talking about portability - which is all well and good until you see a horrible attempt to hack a DirectX like interface over OpenGL sent from the US office and that creates even porting more headaches.

I would consider having OpenGL as your most familiar graphics API is better because of wider support and it is easier to get going with in my experience - It is more fun to learn with OpenGL and there are usually less "WTF is going on??" moments.

Share this post


Link to post
Share on other sites

I would consider having OpenGL as your most familiar graphics API is better because of wider support and it is easier to get going with in my experience - It is more fun to learn with OpenGL and there are usually less "WTF is going on??" moments.


I'd suggest qualifying this statement a little.

GL has wider support in terms of platform availability for sure, but in terms of driver quality and assuming Windows, D3D is ahead.

Regarding it being easier to get started, that could be said to be true if you're referring to glBegin/glEnd code, which D3D has no equivalent of. However, many people would advise that learning glBegin/glEnd stuff is actually a case of learning the wrong thing, and when you compare glBegin/glEnd to modern OpenGL, the difference between GL and D3D becomes virtually non-existent.

So if you're referring to glBegin/glEnd, then it needs to be made clear that you'll get started for sure, but you'll quickly enough hit a point from which you can't really go forward.

Isolating the discussion to the modern versions of each API (by which I mean we're talking about VBOs, shaders, render to texture and GPU computing), the APIs are equivalent with D3D being slightly stronger with documentation (I'd dock marks for the awful D3D11 documentation) and substantially far ahead for tools/etc.

Share this post


Link to post
Share on other sites
I did say learn OpenGL > 3.2, not the glBegin/glEnd rubbish.

I still, personally, think GL is easier to learn even with the modern way of doing things in GL is easier and clearer.

I'm not going to get into a row about OpenGL vs DirectX. They are both graphics APIs, they do exactly the same job.

Share this post


Link to post
Share on other sites

I did say learn OpenGL > 3.2, not the glBegin/glEnd rubbish.

I still, personally, think GL is easier to learn even with the modern way of doing things in GL is easier and clearer.

I'm not going to get into a row about OpenGL vs DirectX. They are both graphics APIs, they do exactly the same job.


True, I grant you that. :)

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!