Brad Wardell, the CEO of Stardock Studios, has been a long time advocate of the performance of the ‘next gen’ API’s, such as DirectX 12 and AMD’s Mantle. He’s has also been more vocal than a lot of developers (who’ve maintained a high degree of radio silence, particularly over DX12) which gives us a small glimpse into the future.
It’s fair to say that next months GDC (Game Developer’s Conference) is going to be… well, exciting. Not only will more information surface regarding DX12, but we’ll also have a greater insight into how it stacks up versus glNext, the latest iteration of OpenGL. Furthermore, we’ll possibly even have some technical information on how this will impact the PS4 and Xbox One.
But, I digress (I tend to do that), let’s get back onto today’s topic, rather than pining for tomorrow. Brad Wardell has taken to Twitter and his blog and has provided several insights into the wonderful world of DX12 – primarily regarding the increase in Draw Calls it affords developers. While we’ve covered just what Draw Calls are several times over, in a nutshell think of them as ‘commands’ issued from the CPU to tell the GPU what to… well, draw. So in other words, the CPU has to tell the GPU “Hey, it’d be really nice if you drew a chair here… and a table there.”
The number of batches are how much information you can throw onto screen in a given frame (remember, each frame has to be re-drawn, after all, things have moved in that time!). So there’s a question how many batches do you need for a scene to look ‘realistic’ while maintaining the desired frame rate (so ideally, you want 30FPS or preferably 60 FPS).
According to Wardell, DirectX 9 manages to hit about 15,000 Draw Calls (on currently available {PC hardware), while DX12 manages to hit over 75,000. If we’re throwing consoles into the mix, the Xbox 360 (which uses a DX9 offshoot) hits about 5,000 – 7,000 Draw Calls (if using Epic’s Unreal Engine). The Xbox One meanwhile pumps things up a notch, or ten, and is apparently capable of reaching 50,000 batches.
Pretty damn impressive, eh? There’s a slight wrinkle however – while the consoles eight CPU cores are technically able to pump out the instructions and the GPU might be able to handle the load, Brad Wardell called the Xbox One’s memory bandwidth “crumby” and isn’t sure if the eSRAM is capable of making up the bandwidth deficit. If you’re fairly familiar with the Xbox One’s architecture, you can skip the next chapter, but if not:
Remember, that the Xbox One’s CPU is running eight cores, but typically two of those are reserved for OS functionality (but developers can opt to tap into a portion of the seventh core), and the GPU is running at a peak performance of around 1.3 TFLOPS (see more of the Xbox One’s GPU performance in part 2 of our SDK breakdown). The memory bandwidth is 68GB/s, but according to Microsoft, real world achievable numbers are considerably less, operating at around 80 percent efficiency (though sometimes scraping up to about 85 percent). Therefore, Brad is basically concerned whether the DDR3 RAM is going to be able to handle the swapping of data fast enough around the console. See more on the Xbox One’s CPU and Memory bandwidth in part one of our X1 SDK breakdown.
It’s possible that these issues, with improvements to SDK’s and development tools (and let’s be honest, knowledge of developer’s) will mitigate these problems. After all, in reality Microsoft aren’t even finished developing DirectX 12, therefore these numbers aren’t ‘final’ by any stretch of the imagination, but certainly provide a bit of an indication.
According to Wardell’s blog, for a lower to mid range card (PC, the AMD Radeon HD 7790) DirectX 9 hits 4,000 Batch count, DX11 pumps this up to 11,000 and finally, the DirectX 12 or AMD’s Mantle API, hits the almighty figure of about 50,000. These figures assume that you’re aiming for only 720P and a frame rate of only 30FPS however, Naturally things would differ if you decide to adjust those requirements.
Moving the subject along a little, remember the Battle of Naboo scene in Star Wars Episode 1: The Phantom Menace? Well, Mr. Wardell believes that around the 75k mark should be able to hit that level of realism, with everything else being equal. Naturally, if you’re sporting a low end GPU then this doesn’t apply – once again however, the future is certainly bright.
While the average game has a small number of light sources – quite often, the limit being about four, according to Wardell and other developers, in reality there are hundreds of thousands of light sources. Imagine the above scene – the light from the lasers, from light sabers, hell, from the blinking of a robot – all of those are light sources. All of those creating shadows, reflections – and you can start imagining the levels of complexity we’re dealing with! It is however true that these movies were made with (now) very outdated technology, and if you watch certain parts of the scene, you’ll spot visual errors (for example, explosions no correctly casting light, or poorer lens effects… that type of thing).
In reality, most of Battle of Naboo would (according to both Brad Wardell and some of his co-workers) come down to the engine itself. If you’re running a very optimized LOD (Level of Detail), fully leveraging the power of the hardware and so on, then 50K would probably be a good enough approximation. Ideally, you’re still rather shy of what you’d need, and indeed StarDocks lead artist believes you’d be better off with 300,000 batches.
For those who’re questioning where this leaves us in the here and now – in a good position. Remember, the lead character artist at Naughty Dog, Frank Tzengi believes we’re getting ever closer to super realistic characters which would be good enough to act as a stand in for a hollywood movie. What we’ve discussed in this article will allow character artists to model super realistic characters in real time – better and more realistic skin tones (for example, accurate wrinkles, skin pores, spots, small hairs and so on), accurate shadows (for example, casting small shadows created by ears, or hairs or say the nose of a character).