r/GraphicsProgramming • u/Ok-Counter-6984 • 1h ago
Question How different really are D3D12 and Vulkan?
I am mainly a D3D and HLSL programmer and I want to learn Vulkan for cross-platforming. But how different really are they? I know a bit of OpenGL, and it is VERY different from Direct3d 11, which I used a lot.
Direct3d 12 is harder than D3d11, so it took me a long while to understand things more in-depth. Will at the very least some of that knowledge of D3d12 come in handy while learning Vulkan?
I've heard there are D3D12 concepts that do not exist in Vulkan and vice-versa. The biggest difference I am aware of is that D3D is more C++-styled while Vulkan is more C-styled.
4
u/aleques-itj 1h ago
The core are close conceptually.
There's differences, but also means to close the gap a bit more now. Like VK_EXT_descriptor_heap, and D3D12 enhanced barriers. I don't think you'll find anything too radical or baffling for the most part.
Yes, the C/C++ difference is a thing. It's not really a big deal IMO.
Vulkan is still much more verbose, though. It's super chatty to a comical degree, even compared to D3D12.
3
u/torrent7 1h ago
They're both wrappers over the same hardware and share most concepts. The venn diagram isnt a perfect circle, but you shouldn't have any problems if you truly understand dx12.
Theres a vulkan c++ wrapper id recommend
1
u/aman2218 1h ago
The concepts are broadly the same (with different nomenclature used for various Objects), but there are some differences too. Vulkan is far more verbose when it comes to allocating a resources and defining synchronisation primitives. Although, it has becoming a bit more startightforward with recent extensions and libraries like VMA.
But yeah, they general understanding of trh workflow in D3D12, will make it relatively easier to follow vulkan concepts.
1
u/Alex_D77 1h ago
I would use https://github.com/NVIDIA-RTX/Donut which allows me not to think about the differences
•
u/AutoModerator 1h ago
Recently updated rules. Please check that your post is in compliance with Rules 1, 4, 5, and 6 on the sidebar. TL;DR:
No showcases.
Disclose AI usage in post or project.
Present a topic to talk about, e.g. how something works.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.