3 ms·
> Is learning OpenGL pretty much inevitable as a precursor to learning Vulkan? Well, maybe not OpenGL, but almost surely some graphics API which allows you to
by bsder 6y ago
> Is learning OpenGL pretty much inevitable as a precursor to learning Vulkan?
Well, maybe not OpenGL, but almost surely some graphics API which allows you to do graphics without a couple thousand lines of obscure boilerplate.
There are lots of "middleware" systems built on Vulkan that are WAY friendlier than raw Vulkan. They handle things like asset loading, memory management, and scene composition for you. If you want to build something, use those. You'll be vastly happier at the end of the day. Maybe at some point you'll hit a performance bottleneck--fine, but by then you know a lot more about graphics.
If you're doing raw Vulkan, you should have a darn good idea as to your purpose.
If someone says: "I want to use Vulkan." I ask "Why?"
If they say: "Because I want to make a thing that does <X>." then they absolutely should be in a middleware system and not Vulkan. They'll get something on the screen much faster and keep their motivation going.
If they say: "Because I want to learn" I have to try to redirect them to something a lot simpler. Learning is about motivation and Vulkan boilerplate saps your motivation really hard.
It also doesn't help that Vulkan development is basically C++ and Windows and there is no negotiating this as a beginner. Trying to develop Vulkan through a language wrapper or on Linux/OS X adds an unnecessary amount of pain to the process--quadruply so if the wrapper tries to be "idiomatic" in your language of choice.
If they say: "Well, we found a bottleneck using RenderDoc and we..." then I ... HA! I'm kidding. Nobody says this because they KNOW why they need to use Vulkan so they don't even ask me.
The primary problem with Vulkan is that you are mapping REALLY closely to the underlying hardware. If you don't understand what the pieces of your graphics card are and what they are doing and why, Vulkan makes very little overarching sense.
One thing I will warn you about when programming Vulkan, you better be really good in your programming language of choice. There are times when you are writing Vulkan code where you have to add a couple hundred lines of code before you can finally test that you got it right. You have to be very confident in your programming skill that you got all the essential things in your language right so that any bug is really in the way you are using Vulkan. For example, if your understanding of pointers and pointers-to-pointers isn't rock solid, you're gonna have a bad time.
However, if you still wish to persist. Here is a class at Oregon State that does Vulkan:
http://web.engr.oregonstate.edu/~mjb/vulkan/ http://web.engr.oregonstate.edu/~mjb/vulkan/
Note that this is considered an upper division/graduate class. That should give you an idea of what you're in for.
- pjmlp 6y ago> It also doesn't help that Vulkan development is basically C++ and Windows and there is no negotiating this as a beginner. Trying to develop Vulkan through a language wrapper or on Linux/OS X adds an unnecessary amount of pain to the process--quadruply so if the wrapper tries to be "idiomatic" in your language of choice. Actually Vulkan uses C, not C++ as usual in most Khronos APIs, and only GNU/Linux and Android 10 onwards are the only platforms where Vulkan has any meaningful usage. On Windows everyone just uses DirectX, OpenGL ICD which are also used by Vulkan drivers aren't even allowed on Windows sandbox driver model, and on Switch, Vulkan might be supported, but so is OpenGL and NVN is actually the one holding the GPU keys. In what concerns Sony and Apple, Vulkan doesn't even exist.
- bsder 6y ago> Actually Vulkan uses C, not C++ as usual in most Khronos APIs You are technically correct--Vulkan is a C API. However, all the tutorials you will use are written in C++. I have never seen a C-only Vulkan tutorial. Link welcomed. On Windows, everyone is using DirectX 11. That is a very different (and much simpler!) beast than DirectX 12 (which--unsurprisingly--looks very much like Vulkan). And, as for Apple, I suspect the fact that Valve/Steam is all-in on MoltenVK(Vulkan on top of Metal) for development means that way more gamers are running games with Vulkan on OS X than plain Metal. (DotA 2--for example--is MoltenVK only on OS X, IIRC). However, most game developers DON'T CARE. They are writing to a game engine that handles all that behind the scenes. As long as the game engine is ported to the appropriate system, the underlying implementation is irrelevant to them.
- pjmlp 6y agoHere is one, https://www.amazon.com/Vulkan-Programming-Guide-Official-Learning/dp/0134464540/ https://www.amazon.com/Vulkan-Programming-Guide-Official-Lea... > On Windows, everyone is using DirectX 11 Which is quite different from "It also doesn't help that Vulkan development is basically C++ and Windows". On Apple, all relevant engines support Metal directly, no need for MoltenVK at all. That is just for the usual FOSS anti-Apple folks that buy Apple hardware and then complain it isn't GNU/Linux. > However, most game developers DON'T CARE..... I agree 100% with this statement.