What does `Vulkan` do exactly?

This forum is the ideal place for all discussion relating to X4. You will also find additional information from developers here.

Moderator: Moderators for English X Forum

Socratatus
Posts: 1626
Joined: Tue, 11. May 04, 15:34
x4

What does `Vulkan` do exactly?

Post by Socratatus »

I hear this talk of `vulkan` over and over again, and that its all X4 uses, almost like it`s some kind of super utility for games... can someone explain to a luddite exactly what is so amazing about Vulkan?
1. Please do more on NPC civilian/uniform variety, and bio customisations, Devs.
2. Stations need sirens/warnings when enemy is close in numbers or Station in danger of destruction (in Sandbox).
Yes, for immersion. Thankyou ahead of time. (Edit: This is actually happening!!!)

"No problem can withstand the assault of sustained thinking."
"Before acting 'out of the box', consider why the box was there in the first place."
Alewx
Posts: 303
Joined: Sun, 23. Mar 03, 11:09
x4

Re: What does `Vulkan` do exactly?

Post by Alewx »

It is a different API for the graphics card, and it is cleaner and contains a lot less overhead than directX.
I7 9900k 4GHz
RTX 3080TI
32GB Corsair
Win10 64bit

But now on a freaking fast SSD aber immernoch ziemlich lahm beim laden :(
Tomonor
EGOSOFT
EGOSOFT
Posts: 1932
Joined: Wed, 12. Sep 07, 19:01
x4

Re: What does `Vulkan` do exactly?

Post by Tomonor »

Also better performance. But a simple google search resulted in lots of good answers. Check them out.
Image
radcapricorn
Moderator (English)
Moderator (English)
Posts: 3230
Joined: Mon, 14. Jul 08, 13:07
x4

Re: What does `Vulkan` do exactly?

Post by radcapricorn »

...than OpenGL, not DirectX. With DirectX, it's just "less", not "a lot less". Basically, it gives more direct control over how graphics is done to the programmers, instead of piggy-backing large amounts of safety checks on the graphics driver (thus specific to vendors). In exchange for much, much, MUCH more boilerplate code to write and maintain. And with the usual "we don't deal with platform stuff, let the vendors sort it out" approach adopted from OpenGL. There's basically three levels to this API, each one prone to it's own quirks and bugs liable to appear across different vendors/GPUs (or combinations thereof) and operating systems. There's also two ways of using it, with possibly different performance implications. So basically, it aims to fix random graphics bottlenecks while at the same time introducing quite a bit of new "voodoo" the programmers have to deal with.
Invasion
Posts: 212
Joined: Tue, 11. Dec 18, 10:14

Re: What does `Vulkan` do exactly?

Post by Invasion »

Vulkan is an API. It is the software interface that your CPU uses to render graphics. The game engine is something else entirely.
<Blunt Threadslayer>
Making you sweat today, so you won't have to bleed tomorrow
radcapricorn
Moderator (English)
Moderator (English)
Posts: 3230
Joined: Mon, 14. Jul 08, 13:07
x4

Re: What does `Vulkan` do exactly?

Post by radcapricorn »

The CPU doesn't "use" software interfaces. The programmer does.
Socratatus
Posts: 1626
Joined: Tue, 11. May 04, 15:34
x4

Re: What does `Vulkan` do exactly?

Post by Socratatus »

Ok, I think I get it now, guys. Seems like a more efficient way of throwing around graphics? Sounds good. Cheers.
1. Please do more on NPC civilian/uniform variety, and bio customisations, Devs.
2. Stations need sirens/warnings when enemy is close in numbers or Station in danger of destruction (in Sandbox).
Yes, for immersion. Thankyou ahead of time. (Edit: This is actually happening!!!)

"No problem can withstand the assault of sustained thinking."
"Before acting 'out of the box', consider why the box was there in the first place."
SpaceCadet11864
Posts: 476
Joined: Tue, 4. Dec 18, 02:14
x4

Re: What does `Vulkan` do exactly?

Post by SpaceCadet11864 »

Better performance??? Where did you even come up with that? It's better than openGL but isnt squat compared to DirectX.

Besides, Vulkan is more comparable to OpenGL, as both are cross-platform and Open Source. DirectX is proprietary to Windows, and API is not open source either. Every AAA title you find uses DirectX 11 or 12. The games look a lot better with it too.

If youre using NVIDIA, you have a lot more optimization and graphics options with DirectX, more limitations with openGL (ambient occlusion is not even supported with openGL) - while Vulkan is nonexistant save for a few blog posts saying "we support vulkan!"

Here's the thing: if you want to make a game that looks amazing on windows but not be cross platform, then you want to use DirectX.

If you want to make a game that supports mac and linux and windows, better off using openGL, and now Vulkan. Or if you have a political agenda, use openGL or vulkan.

Vulkan is superior to openGL they say. But there is plenty of evidence that suggests it doesn't hold a candle to DirectX. DirectX12 has real time ray tracing for chrissake. Honestly, whoever said "its better than directx" are you fkn trolling?
User avatar
StoneLegionYT
Posts: 1478
Joined: Fri, 4. Nov 05, 01:18
x4

Re: What does `Vulkan` do exactly?

Post by StoneLegionYT »

Vulkan can be faster / better because it has more direct communication to the hardware and does not slow down as much with the software. This is a fact.

Optimizing it well and using it correctly is a whole other story.
SpaceCadet11864
Posts: 476
Joined: Tue, 4. Dec 18, 02:14
x4

Re: What does `Vulkan` do exactly?

Post by SpaceCadet11864 »

Kane Hart wrote: Tue, 11. Dec 18, 21:37 Vulkan can be faster / better because it has more direct communication to the hardware and does not slow down as much with the software. This is a fact.
That is a huge over-simplification. Vulkan is not machine language /assy, its an API. API by definition is not direct communication. Also, different graphics drivers and graphics card do better or worse with different graphics APIS.

Also, the graphics card manufacturers expose their own API that Vulkan or DirectX or openGL interface with. https://superuser.com/questions/668019/ ... am-the-gpu

Vulkan is just a cross platform API. how it "communicates" with hardware is probably very nuanced, and depending on what instructions, methods, functions you use varies greatly in how "close to the metal" it actually gets. How many layers of abstraction are inbetween depend on the very method, function, or "interface" you use. to claim "more direct communication to the hardware" also claims you would know exactly how directx works and since that is PROPRIETARY you can't, we can guess and speculate but we just can't know for sure, therefore that claim is not provable. So don't fall for the vulkan sales marketing BS here. DirectX is proprietary, nobody except the people who work on it and the people who create graphics cards know this.

side note: NVIDIA and directX both are proprietary and this makes some people mad, especially AMD so its not surprising VEGA works great with vulkan technology lol. ATI brand is also open source.

As far as I can tell, vulkan has a lot of potential but it isnt widely adopted as directx or opengl. directx has a lot of features such as ambient occlusion or real time raytracing that opengl and vulkan dont even have. Again, graphics cards have their own APIs, instructions are sent from Vulkan, or opengl, or directx in terms of shaders that are written in low level languages like C, but thats 2 levels of abstraction already. there's no "direct communication" here at all.
Kane Hart wrote: Tue, 11. Dec 18, 21:37 Optimizing it well and using it correctly is a whole other story.
I agree usage of the api is important, that goes the same with all apis though.
radcapricorn
Moderator (English)
Moderator (English)
Posts: 3230
Joined: Mon, 14. Jul 08, 13:07
x4

Re: What does `Vulkan` do exactly?

Post by radcapricorn »

Yeees, SpaceCadet, yees, of course (backs away slowly).
ero_sk
Posts: 53
Joined: Thu, 30. Oct 08, 14:35
x4

Re: What does `Vulkan` do exactly?

Post by ero_sk »

Kane Hart wrote: Tue, 11. Dec 18, 21:37 Vulkan can be faster / better because it has more direct communication to the hardware and does not slow down as much with the software. This is a fact.

Optimizing it well and using it correctly is a whole other story.
Now, I'm not into games/game engines development at all, I am a software developer though. Correct me if I'm wrong, but is the story with Vulkan not similar to C++ vs other, more high-level languages? I.e. used right can bring lot of benefits (in terms of performance), however if done wrong can cause more trouble?
SpaceCadet11864
Posts: 476
Joined: Tue, 4. Dec 18, 02:14
x4

Re: What does `Vulkan` do exactly?

Post by SpaceCadet11864 »

Well, I dont think anyone can say with certainty how close to the metal it gets, but we can benchmark test it and it does appear that vulkan is faster than directx:
https://www.anandtech.com/show/11223/qu ... i-overhead

i dont think it has as many features like ambient occlusion and realtime raytracing.
User avatar
LennStar
Posts: 910
Joined: Fri, 1. Apr 05, 15:22
x4

Re: What does `Vulkan` do exactly?

Post by LennStar »

SpaceCadet11864 wrote: Tue, 11. Dec 18, 21:34 Better performance??? Where did you even come up with that? It's better than openGL but isnt squat compared to DirectX.
As Direct X12, Vulkan is closer to teh hardware. It offers comparable advantages for performances. The main point for Vulkan is that it reduces CPU load, which was always a X bottleneck.
:idea: BUG REPORT INFO: I play X4 vanilla. You can find all my bug report files in there:
All X4 files: https://www.dropbox.com/sh/83j3cjfhkdlf ... w6HLa?dl=0
SpaceCadet11864
Posts: 476
Joined: Tue, 4. Dec 18, 02:14
x4

Re: What does `Vulkan` do exactly?

Post by SpaceCadet11864 »

ero_sk wrote: Tue, 11. Dec 18, 22:18
Kane Hart wrote: Tue, 11. Dec 18, 21:37 Vulkan can be faster / better because it has more direct communication to the hardware and does not slow down as much with the software. This is a fact.

Optimizing it well and using it correctly is a whole other story.
Now, I'm not into games/game engines development at all, I am a software developer though. Correct me if I'm wrong, but is the story with Vulkan not similar to C++ vs other, more high-level languages? I.e. used right can bring lot of benefits (in terms of performance), however if done wrong can cause more trouble?
Very true, low-level languages like C for example require you do your own garbage collection whereas C#/java do that for you.

If you look at the shaders dir in the modding, you can see they wrote a lot of their shaders in what appears to be C++, but using .f and .p1 extensions.

but shaders even for dx12 are in a low level C type language.
User avatar
bubbabenali
Posts: 122
Joined: Tue, 14. Jan 14, 07:30
x4

Re: What does `Vulkan` do exactly?

Post by bubbabenali »

Alewx wrote: Tue, 11. Dec 18, 17:07 It is a different API for the graphics card, and it is cleaner and contains a lot less overhead than directX.
It also has the powers of messing with your capturing software and being only used by a few games introducing you to new and never before heard of errors (like a nice typo in an important config file)
radcapricorn
Moderator (English)
Moderator (English)
Posts: 3230
Joined: Mon, 14. Jul 08, 13:07
x4

Re: What does `Vulkan` do exactly?

Post by radcapricorn »

bubbabenali wrote: Tue, 11. Dec 18, 22:54 It also has the powers of messing with your capturing software and being only used by a few games introducing you to new and never before heard of errors (like a nice typo in an important config file)
First one is a problem of capturing software, not Vulkan. Second one has nothing to do with Vulkan at all, at most stupid vendors who forget to clean up their own mess.
radcapricorn
Moderator (English)
Moderator (English)
Posts: 3230
Joined: Mon, 14. Jul 08, 13:07
x4

Re: What does `Vulkan` do exactly?

Post by radcapricorn »

SpaceCadet11864 wrote: Tue, 11. Dec 18, 22:23 Very true, low-level languages like C for example require you do your own garbage collection whereas C#/java do that for you.
No they don't require you to do your own garbage collection. They simply could care less what you do with memory. Garbage collection takes away control from you in favor of convenience. Vulkan empowers you with control at the cost of convenience. The comparison to garbage collection is therefore just asinine.
If you look at the shaders dir in the modding, you can see they wrote a lot of their shaders in what appears to be C++, but using .f and .p1 extensions.
In core Vulkan shaders are supplied through the API in the SPIR-V bytecode. Which means one can implement their own compiler and use whatever syntax they fancy.

In short, it's blatantly obvious you have no idea what you're talking about, yet you presume to make blatantly outrageous claims. Please fix one or the other, or preferably both, for your own sake, and for the sake of those who'd happen upon your posts in the future.
User avatar
esd
Posts: 18002
Joined: Tue, 2. Sep 03, 05:57
x3tc

Re: What does `Vulkan` do exactly?

Post by esd »

SpaceCadet11864 wrote: Tue, 11. Dec 18, 21:34 are you fkn trolling?
Well wasn't that nice? Go check the rules on swearing, and don't go accusing people of trolling just because you don't agree. It's not something we tolerate.
esd's Guides: X² Loops - X³ MORTs
SpaceCadet11864
Posts: 476
Joined: Tue, 4. Dec 18, 02:14
x4

Re: What does `Vulkan` do exactly?

Post by SpaceCadet11864 »

radcapricorn wrote: Tue, 11. Dec 18, 23:21
SpaceCadet11864 wrote: Tue, 11. Dec 18, 22:23 Very true, low-level languages like C for example require you do your own garbage collection whereas C#/java do that for you.
No they don't require you to do your own garbage collection. They simply could care less what you do with memory. Garbage collection takes away control from you in favor of convenience. Vulkan empowers you with control at the cost of convenience. The comparison to garbage collection is therefore just asinine.
If you look at the shaders dir in the modding, you can see they wrote a lot of their shaders in what appears to be C++, but using .f and .p1 extensions.
You are correct they dont care about what you do with memory, I mean, we're splitting hairs here because in the context of software engineering GC is a real thing that needs managed, but this was an entire digression from vulkan.
In core Vulkan shaders are supplied through the API in the SPIR-V bytecode. Which means one can implement their own compiler and use whatever syntax they fancy.

In short, it's blatantly obvious you have no idea what you're talking about, yet you presume to make blatantly outrageous claims. Please fix one or the other, or preferably both, for your own sake, and for the sake of those who'd happen upon your posts in the future.
You can write your own compiler to use whatever syntax you fancy without vulkan. I wrote my own lisp compiler in javascript. So what is your point here?

Also, please please tell me what claims specifically were outragoues? I'm at a loss here.

Lastly, I apologize if I came across rude - and no, I'm not a graphics API expert, not in the slightest! I am merely sharing what I do know, and if there is something I'm wrong about, please specifically tell me what "claim" i made was wrong so that I can learn, instead of just making a blanket statements.

Return to “X4: Foundations”