Looking for advice (DX vs. OpenGL)

The Partridge Family were neither partridges nor a family. Discuss.
Post Reply
John73 John
Posts: 4
Joined: August 6th, 2020, 7:16 pm

Looking for advice (DX vs. OpenGL)

Post by John73 John » August 15th, 2020, 7:50 pm

I'm looking for some advice here. I know everyone on this forum is going to be biased toward DX, but I thought I'd ask anyway.

This spring, I took a university computer graphics class. They taught me OpenGL in C++. We covered up to GLCallLists for rendering large numbers of triangles, but the second half of the class was disrupted by the Varona Cirus pandemic.

On my own, over the summer I started looking for more advanced tutorials and was told that (apparently) the GLCallList is kind of deprecated and that VBO's, VAO's, etc. are the way to go.

I tried several tutorials about those in OpenGL, and it went so far over my head I think it might have made a new crater on the moon. I remembered how easy and fun it was to follow Chili's beginner-level course, so I thought I'd give his 3D tutorials a try.

Things started out okay, but now I'm on episode 28 and starting to get lost. Instead of writing out the code and explaining as he goes, most of it is just "pull this from GitHub" with a brief summary. I don't really understand 80% of it. Between each episode I've been trying to fiddle with the code and see if I can make it do different things, but for the most part I don't understand what the hell is going on. I'm currently at the "swirling tornado of random shapes" stage of the project. I tried to make some shapes of my own, but after a few days of frustration I haven't had any success at modifying the code for myself.

The GLCallLists were doing everything I needed them to do. All I want is a thing I can shove a bunch of triangles into and have it draw them -- but I saw in multiple places that they're deprecated and should be phased out.

So what should I do:
A. GLCallLists aren't as deprecated as they say, just go back to what I know.
B. Give the OpenGL VBO/VAO/etc. another try.
C. Chili already owns my soul at this point, do what it says at the top of the forum and learn DX or die trying.

Slidy
Posts: 79
Joined: September 9th, 2017, 1:19 pm

Re: Looking for advice (DX vs. OpenGL)

Post by Slidy » August 16th, 2020, 3:38 am

Graphics APIs have evolved over the years, giving more and more power, and therefore responsibility, to the user. It used to be that you just tell the API to "draw this thing" and it'd do it for you, but that doesn't really give you much control over how things get drawn on the screen. With more control you get better performance & better looking things on screen.

e.g. Long time ago APIs had a fixed function pipeline, so you would just call some premade functions in pixel/vertex stages. But if a function didn't exist to do what you wanted then you were out of luck, so programmable shaders were added. This lets you program exactly how the stages of the graphics pipeline work. Obviously this is better, but it also places more burden on the programmer since they have to now write/understand more of the code.

In the same vein, the newest generation of graphics APIs (Vulkan, DX12, Metal) are much lower level than the previous generation (DX11, OGL) and therefore much harder to learn. With each generation, the barrier to entry gets more difficult since there's more to understand, but you also get rewarded for your efforts since you can do so much more.

In Chili's series he teaches DX11, which I think is a good middle ground. It's not too old that it's deprecated (most games today are still on DX11), but isn't quite as difficult to get into as the newest stuff. So my recommendation is to stick with that. That being said, DX11 & modern OGL (with the VBO/VAO stuff) are quite similar, so you probably won't go wrong with either of them.

As for your issues with understanding the content, I recommend you go back and rewatch/reread things while also coding along and making sure you understand every step. Having a weak foundation in the beginning will make things harder to understand later on.

Hope this helps, good luck.

albinopapa
Posts: 4266
Joined: February 28th, 2013, 3:23 am
Location: Oklahoma, United States

Re: Looking for advice (DX vs. OpenGL)

Post by albinopapa » August 16th, 2020, 5:22 am

Yeah, I got really lost when he came up with all the bindable/drawable stuff. I've watched most of the videos, but haven't followed along with HW3D series yet. I'm sure I'll be in the same boat when that day comes.

I don't know anything about opengl, so to me what little I've looked through confuses me.
If you think paging some data from disk into RAM is slow, try paging it into a simian cerebrum over a pair of optical nerves. - gameprogrammingpatterns.com

Post Reply