• Advertisement

Archived

This topic is now archived and is closed to further replies.

What do you think is a good api.

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

right know im learning dx but i heard that sdl and opengl are ok too, what do you think?

Share this post


Link to post
Share on other sites
Advertisement
To prevent a flamewar from arising (and since you posted this in the DX forum, obviously answered will be baised towards DX), each API has it''s own pros and cons. However, to me, D3D seems to be the better API.

For a better, un-biased explanation, check out this article.


Dustin Franklin
Mircrosoft DirectX MVP

Share this post


Link to post
Share on other sites
OpenGL and SDL are quite a bit easier, but DirectX has so much to offer that it''s worth the extra work in my opinion.

Share this post


Link to post
Share on other sites
A good API is one that you''re comfortable using. Obviously we know nothing of your ability level, so we can''t help you there.

SDL does something different from Direct3d and OpenGL, SDL is basically a wrapper library which makes things easier for programmers who want to use fullscreen or direct software or opengl rendering.

Whereas Direct3d of course, you have to make your own "wrapper" to set up windows, input handling etc (I''m sure there are zillions of pre-written ones, and they are all identical).

Mark

Share this post


Link to post
Share on other sites
It depends..

If you''ve never heard of anything else than Windows, and you like to have official documents, go for DirectX.

If you''re a do-it-yourself-er, and like to search and have alot of time. Go for OpenGL/SDL. There are actually quite alot of articles on those 2, although you have to search for yourself.

I went for DirectX because it seems so ready-to-use. Everything you want is in it, don''t have to search much farther than the documents that come with it.
OpenGL on the other hand, has a lot of extensions, and the system.. Me personally, don''t like that system. One download, one package, one document. DirectX.

--
You''re Welcome,
Rick Wong

- sitting in his chair doing the most time-consuming thing..

Share this post


Link to post
Share on other sites
My opinion of a good API is one that I can use for rapid prototyping and tuned high performance release code. So I chucked Direct3D for that reason, I feel like I''ve just gone the cheating way out by going with OpenGL due to the simplicity I find in using it over Direct3D. I will eventually have to learn Direct3D at some point if I was to ever get anywhere in games programming. But for now, I''m going to stick with OpenGL.

note: I use SDL, SDL_net, fmod/SDL_mixer for the other stuff.

"You are in a room. You can see a cow."
">look at cow"
"It is a cow."

.:Cubicle2:.

Share this post


Link to post
Share on other sites
If you were wondering about my knowledge, I'm really confident with DirectX, hoping to make a game engine, generic.
But I was wondering, is SDL or OPENGL really that easy, if it is, I'll start making cross platform games, but still use DX.


[edited by - snyp on May 9, 2004 9:14:24 AM]

Share this post


Link to post
Share on other sites
I don't know what you know about SDL, but it stands clearly out from the other two. It's a very simple 2D library that's easy to learn, and offers some powerful features once you've learned the basics. However, the same game made in SDL and Opengl/D3D will probably be much faster in Opengl/D3D. Also, going for SDL, you'll miss out on features such as image rotation and scaling. Sure, you can write a zoomer/rotator for SDL, but it wouldn't be near as fast (not to mention good-looking) as in Opengl or D3D.

Don't get me wrong, SDL is great for beginners who want to make simple 2D games, and do it with a small amount of code lines. If you use SDL with OpenGL, it's great for window creation (a couple of function calls does the trick), and as a bonus you'll get platform-independent code.


Edit: Forgot to mention that SDL provides you with some easy-to-use features such as multithreading, audio, CD-ROM controlling, keyboard- and mouse input, and with some additional libraries, networking and text output.

[edited by - Goldfish on May 9, 2004 9:40:43 AM]

Share this post


Link to post
Share on other sites
Lets put it like this:

If you understand C++ then you can choose both.
If you''re just starting with programming, and never read about classes, you might *think* that OpenGL is easier because it''s ''just functions''.

MicroSoft works on DirectX so I''d go for OpenGL. NOOOOT!! That''s the best reason to go for DirectX. MicroSoft never loses. (But not always wins. Sony.)

--
You''re Welcome,
Rick Wong

- sitting in his chair doing the most time-consuming thing..

Share this post


Link to post
Share on other sites
quote:
Original post by Goldfish

Edit: Forgot to mention that SDL provides you with some easy-to-use features such as multithreading, audio, CD-ROM controlling, keyboard- and mouse input, and with some additional libraries, networking and text output.

[edited by - Goldfish on May 9, 2004 9:40:43 AM]


How the hell could you forget ALL that?

snyp: You''re learning DirectX, carry on learning it. Forget about OpenGL and SDL for now, that''s all there is to it.

"You are in a room. You can see a cow."
">look at cow"
"It is a cow."

.:Cubicle2:.

Share this post


Link to post
Share on other sites
why are people acting like D3D has more capabilities then open GL? have you guys not seen the screen shots for doom 3 yet ? and look at q3, which is imo the greatest engine ever created

[edited by - graveyard filla on May 9, 2004 11:25:50 AM]

Share this post


Link to post
Share on other sites
OpenGl is just a tool, there is no BEST tool, it depends on what you are trying to accomplish, if you disagree then try writing word with OpenGL

Share this post


Link to post
Share on other sites
quote:

MicroSoft works on DirectX so I''d go for OpenGL.



MS is also on the advisory board for OGL, so that''s kind of a moot point.

Share this post


Link to post
Share on other sites
quote:

why are people acting like D3D has more capabilities then open GL? have you guys not seen the screen shots for doom 3 yet ? and look at q3, which is imo the greatest engine ever created



Another moot point. Look at Half-Life 2, Halo, or...

The API does not make the game.

By the way: Every id Software game since Quake 3 has used Direct X - DirectMusic, DirectSound, and DirectInput (at least in the windows versions). Carmack is just VERY familiar with OGL (id is another advisory board member), so he prefers it (also, when he did the first API version of Quake - QuakeGL, D3D was horrible). Carmack also wants his games to be cross-platform, so OGL makes sense.

You''re attributing the capabilities of arguably the best programmer in the industry to the API he''s using...and that''s a very poor arguement.

That''s not to say that the engine would be any better with D3D - it would just be a little different.

There is really nothing you can do with D3D that you can''t do with OGL (or vice versa). This is especially true for beginners.

Share this post


Link to post
Share on other sites
quote:
MS is also on the advisory board for OGL, so that''s kind of a moot point.


MS have left the ARB now actually.

As for DX vs GL, learn both if you can, or at least have a look at both. They''re basically just different interfaces to the same hardware so you can do the same stuff in both (well there may be some differences e.g. an extension in GL could allow you do to something that you''ve got to wait for the next version of DX to do it in D3D). SDL is very useful when working with GL as it can take care of the input and sound side of things as well as being cross-platform (like GL). It''s not just something beginners use either. Commercial games in linux use it (I believe UT2003 and UT2004 both use SDL).

Share this post


Link to post
Share on other sites
etnu - you must have read my post wrong. i did NOT say that any API was better. i was just defending OGL because if you read the posts above me people are trying to make OGL look worse then D3D, when in fact (as i already knew) there is no better API. i never said anything in my post that either was better

Share this post


Link to post
Share on other sites
quote:
Original post by Monder (well there may be some differences e.g. an extension in GL could allow you do to something that you''ve got to wait for the next version of DX to do it in D3D).

You''re talking about something that can happen, but will not at this level.

--
You''re Welcome,
Rick Wong

- sitting in his chair doing the most time-consuming thing..

Share this post


Link to post
Share on other sites
quote:
Original post by snyp
OpenGl is just a tool, there is no BEST tool, it depends on what you are trying to accomplish, if you disagree then try writing word with OpenGL


Just out of curiosity, have you ever *tried* to write word in OpenGL? Hell, wtf would word in d3d look like!?!

Life would be so much easier if we could just get the source code.

Share this post


Link to post
Share on other sites
Funny you should mention word, because I''ve been thinking for a long time about taking advantage of D3D''s capabilities to make consumer applications that were far prettier and more intuitive than standard windows apps.

But that''s another story...

Share this post


Link to post
Share on other sites
Yeah it''s called Avalon

quote:
You''re talking about something that can happen, but will not at this level.


I know, I was just giving an example about when DX and OGL can differ in the feature set they can access.

Share this post


Link to post
Share on other sites
I think, generally it just depends on which one you like. I found directX first, so I use that. Other than that, once you choose one there won''t be much of a difference for a while. From what I know, all of the low-level functionality (ie, simple primitives) are available in both OGL and D3D.

I, of course, would argue that Dx has DirectMusic and DirectInput, but that''s just me.


Yes... VB6 is here to steal your minds fps. Very slowly.
Call .optimize(you.sig)

Share this post


Link to post
Share on other sites
quote:
Original post by Venerable Vampire
quote:
Original post by snyp
OpenGl is just a tool, there is no BEST tool, it depends on what you are trying to accomplish, if you disagree then try writing word with OpenGL


Just out of curiosity, have you ever *tried* to write word in OpenGL? Hell, wtf would word in d3d look like!?!

Life would be so much easier if we could just get the source code.


I think you should read before you actually say something, I was just making a point sheesh!!!! :|

Share this post


Link to post
Share on other sites

  • Advertisement