r/GraphicsProgramming • • Apr 15 '24

Is Vulkan a failed API?

I know it's modern and can do things that older APIs like OpenGL can't but how many developers are benefiting from the added verbosity and complexity?

The OpenGL reddit has more members and higher engagement than the Vulkan reddit despite the fact that OpenGL hasn't been updated in 7 years.

Personally, I would prefer if an API like Metal had cross platform support, it's modern and far less verbose.

0 Upvotes

62 comments sorted by

View all comments

67

u/Revolutionalredstone Apr 15 '24 edited Apr 15 '24

Vulcan is WIDELY misunderstood.

Most people should not be directly using it.

The fact that you are comparing it to OpenGL shows a problem.

Vulkan is MUCH lower-level than OpenGL. This control comes with the cost of greater verbosity and complexity in the code. Vulkan requires more setup and management of resources, such as memory and command buffers, which are generally handled quite well automatically by OpenGL.

Most of my friends who invested the 3-6 months to convert to Vulcan saw their performance decrease compared to easy to use OpenGL.

The exposure (and requirement) of ultra low level threading might be a benefit to some low level optimization experts on AAA titles, but most people can't do a better job managing those details than OpenGL was already doing!

The reality is people really understood OpenGL, it's just a driver with an API for users to draw 3D things!

When Vulcan came out (something much closer to a raw driver) people didn't know what to think of it and some idiot said oh it's just faster OpenGL and a million dipshits wasted their time hahaha.

The reality is these things are miles apart, even people who claim to directly use Vulcan don't actually do anything like that, they create object models and god-classes to make it reasonable.

IMHO you should really just use BGFX or other simple unified layers and let it pick Vulcan as the backend automatically where appropriate.

Failing that just use OpenGL, It runs like a dream on anything, and I've never seen a legitimate reason for bad graphics performance, a bit of LOD + frustum culling and you can render anything with OpenGL! here's some footage my newest OpenGL Minecraft clone: https://imgur.com/a/MZgTUIL (running on a computer with no GPU)

Enjoy

19

u/Glacia Apr 15 '24

The fact that you are comparing it to OpenGL shows a problem.

Before the official name Vulkan was called OpenGL Next, why wouldn't you compare it to OpenGL?

I think you're the one who misunderstood what Vulkan was/is.

Just because it end up as "write your own driver API" doesn't mean it was the original goal. It just shows that it was made by committee and completely failed to deliver. No one asked for this. People just wanted OpenGL with less driver overhead. Remember AZDO?

6

u/Revolutionalredstone Apr 15 '24 edited Apr 16 '24

IIRC Vulkan originally went under the title 'Next Generation OpenGL Initiative'?. I understand the original plan was to unify the core tech of OGL, ES and OCL. AFAIK The API was ALWAYS meant to be extremely low-level & comprehensive?

Commercially this NEVER made sense, it's an unviable upgrade for many projects due to the required learning time and it doesn't even promise an instantaneous performance benefits (without also changing up your program's structure).

If you're saying THAT outcome was less the original plan and more the result of committee bureaucracy uselessness along the way - well that would certainly make a lot more sense! (however it happened - we agree this is not what people wanted - and it's not what some people try to pretend it is)

OpenGL is much loved by users, it's down-to-earth and dead simple, however OpenGL most certainly will be implemented using the Vulkan API in the future.

Advanced new OpenGL-on-Vulcan implementations might even bring what remaining performance gap exists together as Vulcan experts will surely be bought in to implement the next version of OpenGL's backend.

Thanks for sharing

9

u/Glacia Apr 15 '24

You need to dig some history to figure out how we end up here.

Before Vulkan became a thing people were abusing OpenGL to remove driver overhead. That's why I mentioned AZDO - there was a clear demand from actual users. We would probably got OpenGL 5, but AMD donated Mantle API to Khronos and Vulkan ended up based on Mantle API.

Mantle was created by AMD driver team to test out what low level API could be, and that's how we end up here.

7

u/Revolutionalredstone Apr 15 '24 edited Apr 15 '24

Wow that's quite a story! thanks for sharing my dude! definitely all makes a lot more sense with additional context. AZDO is especially interesting! all the best my good man.

Enjoy!

2

u/IceSentry Apr 15 '24

I'm curious. Do you have an idea why you make the vulcan/vulkan typo so much? They're not close to each other on a qwerty keyboard so I assume it's something else. Do you spend a lot of time discussing star trek and vulcans?

2

u/Revolutionalredstone Apr 16 '24

Definitely blaming StartTek!

The only thing I do more than graphics programming is watching startrek!

3

u/[deleted] Mar 06 '25

[removed] β€” view removed comment

2

u/Revolutionalredstone Mar 06 '25

Exactly πŸ˜‰

0

u/[deleted] Mar 08 '25

[deleted]

1

u/Revolutionalredstone Mar 08 '25

Nope just that you need to use wrappers πŸ˜‰

2

u/[deleted] Mar 10 '25

[removed] β€” view removed comment

1

u/Revolutionalredstone Mar 10 '25

I wrote mine πŸ˜‰

I'm not against people using ASM as a target but doing ASM by hand is just crazy town.

Same logic with vulcan πŸ––

3

u/[deleted] Mar 10 '25

[removed] β€” view removed comment

1

u/Revolutionalredstone Mar 10 '25

No I'm not πŸ‘Ž why do people claim without evidence lol

My wrappers are used at many large graphics companies.

Specifically my render object is used by the French and Japanese governments for mapping and infrastructure.

Enjoy ✌️

5

u/PeterBrobby Apr 15 '24

I think it would of been a good idea for Khronos to still update OpenGL whilst offering Vulkan to those who want it.

7

u/Revolutionalredstone Apr 15 '24 edited Apr 15 '24

I'm not sold, OpenGL is pretty much done, it works completely fine.

Looking at the timeline it's clear they were just adding random stuff by the end, even by 3.0 there was very little true new core tech.

4.0 and beyond is kind of like 'General Compute' and 'bindless' which are fine but OpenCL exists and already does compute much much better (and it was already completely compatible with OpenGL anyway) bindless is super cool but it's such a departure and radical change that it basically only gets used by a niche set of people who really go hard (since most people don't want to unlearn everything they knew just for the computers which can support it)

IMO people should be more focused on their game and less focused on their API ;)

I've used OpenGL 3.0 for over 15 years straight, it never lets me down and it runs everywhere like a dream! (the few devices which don't support it WILL support gles 2 which is basically just identical, you change one or two things here and there and it just works!)

Enjoy

4

u/winterpeach355 Feb 18 '25

OpenGL is not "done" by any means. They have yet to go full DSA or ditch geometry shaders. A modern OpenGL 5.0 would be perfect for people who just want an easy cross platform API.

3

u/HildartheDorf Apr 15 '24

OpenGL works fine. It doesn't need an update, any new features are exposed as extensions. At most it could use an occasional roll up to make ubiquitous extensions core, but it doesn't need new features at the core API level.

10

u/shadowndacorner Apr 15 '24

any new features are exposed as extensions

That's not really true anymore, though. It's been a while since I've specifically kept up with OpenGL, but afaik, most new hardware features since ~2018 are either completely unsupported or only supported on nvidia, whereas D3D12 and Vulkan have cross vendor support for most features at this point. Beyond that, a lot of libraries like DLSS, FSR, and XeSS only support the newer APIs - not that they fundamentally couldn't be rewritten to target OpenGL, but that would be a significant investment.

For simple apps, those features are likely irrelevant, but the fact is that vendor support for OpenGL is distinctly worse than D3D12 and Vulkan today, and for some use cases, that can be an outright deal breaker.

3

u/Ok-Sherbert-6569 Apr 15 '24

Well vulkan should be more like metal. You should have explicit ability to manually memory management and also be able to leave that up to the driver. Any other approach is doomed and stupid

11

u/Revolutionalredstone Apr 15 '24

Agreed, I've actually seen c++ wrappers for Vulcan which do something just like that!

IMO The real issue comes from people writing directly against it, Vulcan is a great driver! and you can USE IT TO EXPOSE an excellent graphics interface!

But for whatever reason people don't do that... they try to force their game systems to treat Vulcan like it was a high level graphics API which it just is not.

Enjoy

-1

u/morglod Apr 15 '24

Fact

Also looks like people (as always) reading only big labels from big companies. OpenGL have most things (and somewhere even more) than Vulkan through extensions. And most games on vulkan works slower than gl. GL state management is bad? Ofc better copy 40 bytes of descriptors for every api callπŸ€™ yeaaahh. 2024. Make your graphic api calls through multiple data copies to buffers that you write from all cores of your CPU and than wait while 192bit GPU connector will eat that stuff. Low leveeaaall yeaaahh

2

u/Revolutionalredstone Apr 16 '24

Hats off for the snazzy flair! :D It's refreshing to see that I'm not alone in the old "OpenGL Retirement Home" .

Vulkan is sold on it's low-level features, but when it comes down to the actual race (where program quality = programmers time / api difficulty) old simple and reliable OpenGL leaves it eating dust.

Thanks for the laughs, Enjoy

→ More replies (2)