gamecoupon – Vulkan API: It’s Gaming, Jim, But Not As We Know It

March 25, 2016Business Review

0 Comments

gamecoupon - Vulkan API: It’s Gaming, Jim, But Not As We Know It

One API to rule them all. Wrong fantasy franchise, perhaps, but that’s the idea behind Vulkan, the snazzy open-source successor to OpenGL, alternative to Microsoft’s DirectX and something that might shake up gaming on everything from PCs to phones. But what’s an API? And why should you care? We’ll come to that. For now, if Vulkan is everything it’s cracked up to be, it’ll make games run faster and look better on your existing PC. It might make that SteamOS thing a goer, too. Anyway, version 1.0 is out, so the chattering weberati will be casually trading Vulkan references to prove their PC gaming prowess. Time to bone up. Plus I’ve just sat through a five-hour keynote stream on Vulkan from GDC 2016. So humour me. This stuff is actually quite interesting.

TL;DR
– Vulkan is an open source alternative to Microsoft DirectX on the PC
– It’s the successor to OpenGL
– But it’s derived from AMD’s Mantle API
– It’ll be on everything from phones to PCs
– Like DirectX 12, it claims to make games run faster
– It won’t cost you anything
– It’ll run on AMD graphics cards right back to Radeon HD 7000 series and Nvidia GeForce 600 series boards and newer
– A driver update is all you’ll need
– Oh, and it might make Valve’s SteamOS a viable gaming platform

Let’s begin by elbowing the question of what an API is into touch. It stands for Application Program Interface. And it’s just that. An interface between bits of software.

In practice, an API provides building blocks and tools that make it far simpler for developers to achieve a working application. If we’re talking graphics – and we are indeed talking graphics – then the API is the interface that connects your games with your graphics driver. And thus the 3D visuals are rendered.

The advantages of this approach are pretty profound. With a graphics API, it’s possible to have (mostly) one set of game code that will run on any hardware that’s compliant with the API. So, a game is coded for, say, DirectX 9 and any graphics card that’s DirectX 9-compatible will run it. In theory, anyway. In practice, it’s usually a bit more complicated.

So using an API means that game developers don’t need to be world authorities on both Nvidia and AMD graphics chips, for example. They can use the tools provided by the API and let Nvidia and AMD do the heavy lifting through the driver.

It’s also worth understanding that APIs come in different flavours, otherwise known as high- or low-level abstraction. That sounds fancy, but the implications are pretty straight forward. The higher the level of abstraction, the more distant the application becomes from the specifics of the hardware and the greater the workload handled by the API and graphics driver (in this case).

gamecoupon - Vulkan API: It’s Gaming, Jim, But Not As We Know ItAll aboard the Vulkan train

That’s good in the sense that it makes games development simpler in some ways. The downsides include the need for extensive optimisation jiggery pokery via drivers and in turn fewer opportunities for developers to get things really flying.

As things stand, DirectX has largely been quite a high-level API. It just so happens that DirectX has also been pants when it comes to CPU overheads and multi-threading. And that’s meant DirectX games have been pretty pants by both metrics. And developers often haven’t been able to do much about all that.

Enter a new age of low-level APIs that aim to solve these problems. Arguably, it all started with AMD’s proprietary Mantle API. At the very least, it seems like Mantle bucked up Microsoft’s ideas, leading to DirectX 12 and promises of much reduced CPU overheads and improved multi-threading.

And now we have Vulkan, brought to you by Khronos, the industry consortium behind OpenGL. Fair to say that OpenGL had conspired to become messy, inefficient, unloved, stagnant and left behind for serious PC gaming.

The idea was a clean break from OpenGL, a total reboot. Key features and aspirations for Vulkan include addressing all those nasties mentioned above – so that’s reduced driver overhead, low CPU overhead, better use of multi-core CPUs.

If you want to get more detailed, Vulkan’s low-level API status means games will have more control over their own destiny in terms of performance. Games rather than the API and driver will handle memory allocation and thread management under Vulkan.

As it happens, one of Oxide games graphics gurus, Dan Baker, reckons these aspects will be critical. He says it turns out that memory bandwidth and latency are the big issues for CPU performance in games, not number crunching. So the ability for developers to fine tune things will make a huge difference.

As for threading of games, Baker says with Vulkan, everything becomes hyper granular. In other words, instead of big, heavy threads, a typical game frame will contain 50-100 tiny rendering jobs. And those can be very efficiently load balanced across as many cores as your CPU can offer.

All a simple matter of syncing command buffers in the command queue…

Of course, like OpenGL, Vulkan isn’t tied to one platform. It’ll be on PC in both Windows and Linux. But it will also be in Google’s Android OS (I believe in an updated version of Marshmallow, for those who care). In fact, all the big names have (at least ostensibly) thrown their hat into the Vulkan ring on some level. AMD, Nvidia, Oculus, Nintendo, EA, Oxide, Sony, Lucasfilm, you name it. The only obvious omission at this stage is Apple, which is going it alone as ever with its Metal API.

It’s also worth noting that Vulkan won’t be limited to Windows 10, like DirectX 12. It’ll be supported right back to Windows 7. That could be critical to encouraging uptake of Vulkan by developers – the knowledge that a Vulkan code path gives them access to a fast, low-level API beyond just Windows 10 and DX12.

Oh, and Valve. Did I mention Valve? Vulkan seems purpose built to put Linux-based SteamOS back on the map as a gaming platform. Up to now, SteamOS’s prospects have looked patchy at best. A lot of that was thanks to poor graphics drivers in Linux and the laggardly state of OpenGL.

In theory, Vulkan solves both of those problems. Drivers will be far less critical for performance. And it will be feature and performance competitive with DX12 as an API. Plus, once you have a Vulkan codepath, knocking out versions for both Windows and Linux ought to be straight forward.

Moreover, the big boys of the PC game engine jungle seem to be pro Vulkan – Unreal from Epic, Valve’s Source 2 and Frostbite from Dice are all going to support Vulkan and that should mean it’s straight forward for game developers using those engines to also support Vulkan.

That said, one of the unknowns is just how big an impact all this will have on developers generally and how keen they will be with the new work loads. Vulkans gives them more opportunities. But it also creates new work and puts much more onus on them when it comes to ensuring good performance.

Games with lots of stuff going on, like Ashes of Singularity, are the go-to titles for demonstrating the advantages of new low-level APIs like Vulkan

Which brings us to probably the most controversial aspect of Vulkan. AMD donated the Mantle API in its entirety to the Khronos consortium. At its core, Vulkan is derived from AMD’s Mantle API.

At this stage, it’s impossible to say how influential this single fact will be to its long term prospects. It’s easy to see how that could be interpreted as a killer advantage for AMD hardware and how, in turn, Nvidia wouldn’t want to touch the thing.

In practice, insiders say much of Vulkan has been rebuilt. What’s more, Nvidia actually beat AMD to releasing a fully compliant and tested Vulkan driver.

Right now, there’s little to nothing you can play to give Vulkan a go. There’s the Talos Principle, but it apparently doesn’t run terribly well. There’s a guide here for getting it going if you really must.

Obviously an awful lot of this is fairly speculative at this early stage. Just how keen will developers be? Will Vulkan’s AMD roots be a long term issue? Will Vulkan on Android make the slightest difference to its success on the PC?

Who knows, but the theory all makes sense. So it’s all to play for. But at least now you know what it’s all about.

 
 

0 Responses to "gamecoupon – Vulkan API: It’s Gaming, Jim, But Not As We Know It"