Jump to content
  • Advertisement

Archived

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

ColonelMustard

OpenGL OpenGL and Direct3D

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

Well, here goes. I started C++ programming about 1 year ago. Now I recently decided to make the big jump to 3d graphics, and was so confronted to this choice : D3D or GL ? I decided to start with D3D, since I would use DirectX anyway, and because it sounded so "Direct". So I downloaded the lib, headers and MSDN doc. I found out that it takes about 12 chapters to discuss how to init D3d, and another 4 just to draw a triangle, and then 3 to render the scene. I actually did do a simple Direct3d program, and it''s _quite_ big for what it actually does. So I decided to see what OpenGL was like. I therefore printed NeHe''s tutorials out and downloaded the lib. What was my amazement when I went trough the first tutorial. The OpenGL code was so SIMPLE, CLEAR, SHORT, that I couldn''t believe my eyes ! How could all the D3D fuss hold up in so few function calls ! And the same with the other tutorials too. I really have good fun now coding with this API :-). Now I heard that OpenGL was both simpler and more efficient than Direct3D. I dunno if that concerns only software rendering. I would like other people to give me a good reason to carry on programming with Direct3D. Is it because of the 3D card drivers ? I cannot believe that Direct3D is so mediocre in comparison to OpenGL, since 3/4 of the people here use D3d. Awaiting your reply :-) Mustard ------------------------------------------------------------ I don''t want to declare a flame war ------------------------------------------------------------

Share this post


Link to post
Share on other sites
Advertisement
Can anyone smell a flame war coming up? I know that I can. Well, ColonelMustard, there have been numerous debates on this topic, just read through the DirectX/OpenGL message boards and you''ll find about 5 posts that concern this. It has been debated many times. All your answers lie in the GDNet Message Boards. Cheers!

Share this post


Link to post
Share on other sites
Go c Halo from Bungie and you tell me if you willing to give up GL for D3D, once I saw HALO in GL I said who cares about D3D

Share this post


Link to post
Share on other sites
Well, Here is my thought :

It''s not cause most of the people are doing something a certain way that it''s the good way to do that thing.

(Some people will even tell you that if many people are doing things one way, it''s the wrong way.)

Like you I''ve begin with Direct3D, and I''m now an OpenGL addict.
I hope to see a time in which anybody runs the OS he wants to and that games are platform independant, using OpenGL and the upcoming promising OpenML.

OpenGL drivers allow more freedom...

In our poll @ paraknowya.de, people ask for OpenGL drivers and games rather than direct3d ones...



-* Sounds, music and story makes the difference between good and great games *-

Share this post


Link to post
Share on other sites
You can see some code for initializing and rendering a triangle in a minimalistic way here: Minimal D3D code.

When I started I did so with Direct3D (actually I first made my own software engine then went to Glide, then Direct3D). I have recently played around with OpenGL and I agree, it is real easy to work with and produces very clean code. But then I figured, I already know Direct3D, and OpenGL doesn''t have anything that Direct3D doesn''t so why should I bother to learn a new API. I couldn''t come up with any reason for that, but that''s just me.



- WitchLord

Share this post


Link to post
Share on other sites
Well Mr Mustard, I''d have to agree with completely on what you have said. And in reading the responses Im yet to see someone give you a good reason.. IMO it seems as though openGL will end up being the more common of the two, as there an obviously major differance in the two in terms of difficulty and seemingly little differance in the results. It suprises me somewhat that after researching the topic of 3D API''s I did not come across the simple fact the openGL is ten times easier than Direct X. But then again some people welcome a challange and thrive on the fact that they are "knowledgeable" enough to be able to use DirectX...mmm
Best go now...

Share this post


Link to post
Share on other sites
Thanks for the feedback guys :-)
I didn''t know about the existence of the utility library yet, so i''ll go try it out (thanx WitchLord :-)
IMHO probably some people have never even heard of OpenGL, and that''s maybe why they''re using Direct3DRM.
I found NeHe''s tutorial a GREAT help. Thanks NeHe :-)
What''s with software mode ? which is faster/better ?
Cheers

------------------------------------------------------------
I''m glad there hasn''t been a flame war yet
------------------------------------------------------------

Share this post


Link to post
Share on other sites
Whilst I agree that OpenGL is much easier and nicer to use than D3D. The reason that I use D3DIM is that when I made a program in OpenGL I thought I would show it off to my friends. Only 1 out of the 5 people I gave the program to had OpenGL compatible cards. The one person that could run it had a Matrox G400, and the frame rate was at least half that of my Voodoo Banshee! I would love to use OpenGL, but until it is supported 100% i''ll stick with D3D.

Share this post


Link to post
Share on other sites
As for software mode, OpenGL is very slow since the focus of OpenGL is image quality. As Direct3D was initially for games it is focused on speed, unfortunately its software drivers aren''t that fast (faster than OpenGL though) so if you need software mode you are probably better of building your own renderer from scratch.

- WitchLord

Share this post


Link to post
Share on other sites
I think OpenGL is much better structured than Direct3D. OpenGL is in version 1.2 and DirectX in version 7. OpenGL does not often need to be changed to support newest 3D card features.

Visit our homepage: www.rarebyte.de.st

GA

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

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

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!