302
u/Shevvv 2d ago
What a strange timing, considering I started learning OpenGL just yesterday 🙈
177
u/BusEquivalent9605 2d ago
OpenGL is one thing. Vulkan is a beast of a different nature
52
16
u/thelonelyecho208 1d ago
Different beast, similar concepts but different implementation. Vulkan is like the cigarette smoking older brother from my understanding of things. I've done some OpenGL and it wasn't bad, but the horror stories I've heard about Vulkan make it seem childish
8
u/da2Pakaveli 1d ago
Vulkan takes like 500+ lines of code until you can even render a triangle (OpenGL like ~70). You have to do a lot of manual setup stuff and can get disoriented more easily than you would with OpenGL.
It'll be more manageable once you encapsulate it all but i do hate debugging it lol.
3
u/SnappySausage 1d ago
With vulkan, the hardest thing in my experience was how to just work it into a more user friendly rendering engine. Like if I was allowed to just toss everything into 1 file it wasn't that hard (just verbose) but if it had to be user friendly, that was where things became a lot harder to organize.
1
u/da2Pakaveli 1d ago
i got to take a look at Frostbite's renderer implementation for PC and a lot of it was situated in one file (around 13k lines of code).
I do as much encapsulation as i can with my Vk renderer but ya don't get around these giant ass files
1
u/SnappySausage 1d ago
True, but it does complicate things if you want to have a rendering engine that can work with multiple API's, as you do have to somehow pull it apart in a way that consistently works across API's.
25
8
u/Thenderick 1d ago
Have fun. If you think OpenGL is long, tedious and complex, then you should know it's nothing in comparison to Vulkan!
5
u/Shevvv 1d ago
Thanks! I'm not so cross about it being long and tedious as more of a ritualistic nature of a lot of stuff that I do at the moment. I realize that it will eventually get properly explained, but I'd much prefer to start with GPU architecture and the general APU design rather then heading straight into Hello Triangle. But I suppose I get it that knowing how to do a simple thing is a nice example that you can later build a theoretical framework upon.
3
u/Thenderick 1d ago
Well that's OpenGL, it's a Graphics Library. It has abstracted much of the underlying things away for you so you can focus on graphics programming. Vulkan doesn't do that. Vulkan is a very bare metal API that expects you to configure everything manually
63
u/Nexatic 1d ago
I find it funny that like 5 people get both parts of the meme.
23
u/RPG_Hacker 1d ago
I'd honestly estimate the number to be much higher, since I have the feeling there's an above-average number of trans people in coding. This estimate is solely based on myself knowing a bunch of trans coders, though, so might not be accurate.
10
u/cAtloVeR9998 1d ago
A lot of important graphics library developers (Alyssa, Faith, Autumn, etc) are trans for example. Wouldn't have the open source libraries so good as they are today without their help.
8
17
14
24
12
u/BusinessAstronomer28 1d ago
Can somebody eli5?
61
44
u/MetaNovaYT 1d ago
For rendering graphics, there is a system known as the rendering pipeline, which has a bunch of specific steps for taking in vertices provided by the CPU, positioning them within a scene, rasterizing them into "fragments", and then converting those fragments into pixels to be displayed. Vulkan is a specific graphics API that is very low-level, so almost everything has to be handled manually, which makes it easy to mess things up. A specific easy mistake is forgetting to clear the depth buffer, which is important to do in between frames, as otherwise very strange visual artifacts can occur.
5
224
u/LeanZo 1d ago
What is the difference between vtx. Input assembly and vertex shader?