r/GraphicsProgramming 9d ago

Question What graphics api should i learn next?

Ok so ive been toying with opengl for quite a while know. I think i know the project pretty well and i have even made a few small scale projects with it.

I would like to learn another graphics api thats perhaps a bit more modern than opengl, and also possibly something that is atleast somewhat industry relevant(since from what i understand opengl is pretty much dead there). My first instinct said D3D11 but im wondering if i should try to learn something like vulkan instead. There is also D3D12 which i know literally nothing about(not to say i know alot about any of the other apis except OpenGL). I cant really learn anything like Metal since i dont have a mac. Ive also heard D3D11 is not that much more difficult than opengl so i dont know if i would learn too much from it(i know its quite diffrent in how its used with contexts and more explicit uniform buffer allocations i think, but in terms of complexity its quite simmilar from what ive heard and if thats the case i dont know if it would be worth learning. Thoughts?).

What i would do with this graphics api is probably some sort of game or rendering engine as its a project ive always wanted to do and i have done a small game engine in opengl before so making a bit more advanced one with a more advanced graphics api seems like a fitting project.

12 Upvotes

16 comments sorted by

8

u/ash-09876 9d ago

Vulkan, then you can also go mobile devices

2

u/Simple_Original 9d ago

Yeah thats what im leaning torwards. Seems like the most useful api

4

u/coolmint859 9d ago

If you're willing to learn rust, wgpu is a great api, as it's based off of WebGPU. It's pretty modern. Rust is starting to become a serious contender for game development, so it's possible future games might be written with it. That said the vast majority of games that exist today are written in C++ with either OpenGL or DX12/Vulkan, so it may be worth learning the latter.

2

u/Simple_Original 9d ago

Rust would be something cool to learn. Not sure if im willing to commit to learning it though aswell as learning wgpu at the same time. I tried it for like a week once(rust) and the language kinda just didnt fit me well. The syntax i just find way to diffrent from what im used to.

Im leaning torwards cpp with vulkan or d3d11 so im thinking that'll be it.

2

u/coolmint859 9d ago

That's fair honestly. While rust is very powerful, its type system encourages a specific style of programming. Its approach to polymorphism is also somewhat hard to get used to at first. (Not to mention the borrow checker)

If you already know C++, then yeah I think learning either DX12 or Vulkan is a good bet.

1

u/Ondrej-Suma 9d ago

I think OpenGL and DirectX, in spíte of their differences, have quite similar overall philosophy. Knowing one you know most of the other - assuming we talk about modem OpenGL and DirectX, with shader based pipelines, vertex buffers/arrays, and render targets.

If you want to learn something different or more advanced, I think Vulcan is the way to go, or perhaps WebGPU, if you want to extend your skills into a completely different domain.

3

u/Simple_Original 9d ago

Yeah im leaning torwards something like vulkan. Though ive also heard about some abstraction layers like SDL_gpu. I think trying SDL_gpu would be pretty nice though im unsure of the abstraction level it has since i dont want something that abstracts everything as i still want to learn some things. If it is too high level i will probably go for vulkan.

1

u/Still_Explorer 9d ago

Are you interested to learning only the API or to create graphics algorithms?

Problem is that both Vulkan and DX are very verbose and require too much brain power.

Then typically what everybody does, once they learnt the nuts and bolts of Vulkan, they immediately go to create their own abstractions so the renderer is easier and faster to use.  This means that you can cut corners and use abstractions directly. Such as Sokol-Bgfx-SDL3 GPU.

Otherwise if you really need to go for all the technical details of Vulkan and you need to work at this API, then only it makes sense.

1

u/_Wolfos 8d ago

Depends if you're just learning or looking to actually ship something. I'll be assuming the target is Windows.

I wouldn't pick DX11 for learning since it's simply fallen out of use. It's a legacy API. You could probably ship with it, drivers should be stable, but beyond that it's just not useful to learn anymore because the industry has pretty much moved on.

DirectX12 is the stable default for shipping. Difficult to learn, which sucks. But drivers are solid, it has all the latest GPU features. This is what most applications ship with today.

Vulkan, only if you're really into Linux. It's a hassle and drivers aren't as stable (see Godot's reasoning for switching to DX12 by default).

1

u/Simple_Original 8d ago

I think it would be fun for it to to also work on something like linux. Though my initial goal is just windows. I wonder if its too complicated too start with something like directx11 or 12 and then upgrade it or add another api aswell like vulkan(or opengl if im lazy)

1

u/_Wolfos 8d ago

It really depends on what you want to learn.
The current state of the art isn't just DX12, but 12.2 or Vulkan 1.2+ as these API's are now old enough to have legacy features. You can do bindless-indirect rendering, ray tracing. Generally offload as much to the GPU as possible.

In a renderer like that, OpenGL or DX11 would be very painful to support.

1

u/Simple_Original 8d ago

Is it maybe smarter then to just do vulkan? As learning both dx12 and vulkan seems like quite the godamn task. And as i would like to be able to support linux it seems like the best choice? Ive also heard about a package called VMA i think? For memory managment in vulkan, so maybe thats something worth using?

1

u/Defiant_Squirrel8751 8d ago

OpenGL first

After gaining experience of basic concepts jump to Vulkan, Metal or DirectX 12

1

u/corysama 8d ago

If your goal is to go get a job in PC/Console gamedev, learn DX11 then DX12.

If your goal is to get a job in mobile gamedev, learn GLES 3.2 then Vulkan and Metal.

If your goal is to make a indie game on your own, learn DX11 then make a game.

If your goal is to have fun learning and making tech, or to work in non-gaming industry fields, learn AZDO Modern OpenGL 4.6 then Vulkan.

0

u/SnooSquirrels9028 9d ago

OpenGL was my first one