Detailing NVIDIA's GameWorks 3.1
NVIDIA’s GameWorks suite of developer tools is certainly a hot-button topic which has been covered both in-depth and with no small amount of interesting accusations. Regardless of its reception in some circles and after consultation with a large cachet of developers, NVIDIA is forging ahead with additional elements which are meant to speed up development cycles and bring visual fidelity to the next level. With that in mind they are launching three additional technologies at this year’s Game Developer Conference, all of which are already available in some key titles and are part of the GameWorks 3.1 initiative.
Before I get too far into this quick article, this isn’t a place where I’m going to discuss the supposed merits (or lack thereof) of the GameWorks program since its ultimate success or failure will be determined by developers, not by pundits. If they find aspects that will easily enhance games while also optimizing a production studio’s ROI, those developers will ultimately support GameWorks or the various competing technologies contained within AMD’s competing programs. On the other hand if there are constant shortfalls, success will be fleeting at best.
One thing which is important to know is that of the three new technologies being discussed here – Volumetric Lighting, VXAO and HFS- only one will be available (for the time being at least) on architectures other than NVIDIA’s Maxwell with that exception being Volumetirc Lighting. The reason for this is relatively simple: Maxwell’s architecture contains additional hardware units within its geometry pipeline called Fast Geometry Shaders. These allow for multiple passes on the scene geometry independent of the other graphics stages. As such, they are extremely efficient at computing certain elements like lighting and shadow mapping.
The only exception to the Maxwell exclusivity I described above is Volumetric Lighting. When used on other hardware, it can utilize a low-level tessellation routine (in other words not extreme amounts of tessellation) to achieve the exact same result though at a slightly higher performance penalty.
GameWorks Goes Partially Open Source
There has been no small number of articles written about NVIDIA’s lack of openness when it comes to certain GameWorks technologies. And with good reason; a gated garden approach is the exact antithesis of where the development community is heading. Open source and the collaborative approach that comes with the ability to freely access a program’s source code is what drives innovation in many respects.
With that being said, locking down key GameWorks technologies has (according to NVIDIA) given time to properly flesh them out, insure optimizations are in place for other platforms and roll out key updates in preparation for subsequent wider releases. Think about this like keeping a cake in the oven until you’re sure it’s done baking before feeding it to a tableful of guests. If you think about it, there’s nothing to gain from keeping their developer-facing technologies behind locked doors forever. The guests want to eat that cake, right? With a console market dominated by their competitor, NVIDIA would be committing surefire performance suicide if GameWorks wasn’t accessible across a wide variety of platforms.
So that’s the situation and NVIDIA has been slowly coming around towards opening up their source codes to the community. PhysX along with its Clothing and Destruction modules are excellent examples of this since they have been available of Github for over a year now, making driver-level optimizations and parallel integration with other technologies all that much easier. Now they’re taking another significant step by immediately moving Volumetric Lighting and FaceWorks to open source status. Meanwhile, HairWorks and HBAO+ will be following soon. Those are some huge steps which should silence some critics but we also have to remember that there’s still a long list of technologies like WaveWorks, advanced DoF and TXAA which remain behind the iron curtain for the time being. In addition, licensing agreements (if any) remain a mystery.
The first of the new technologies I wanted to touch upon is NVIDIA’s Volumetric Lighting which actually isn’t all that new since it’s been integrated into Fallout 4 already.
Adding lighting and shadows in games remains an extremely laborious task to accomplish correctly due to a number of factors. In the “older” way of thinking all of a scene’s geometry is in the background and traditional shadow mapping simply takes into account items in a scene that block incoming light. There’s no calculation of air particles which could refract and disperse the incoming light. The end result is quite jarring with clearly defined pools of light that don’t have anything in the way of context or path sensing.
With Volumetric Lighting, the volumes of the light itself are taken into account, rendered and filtered in the background and then inserted into the scene alongside traditional shadow mapping. This is done via a high level extrusion of the items within the virtual atmosphere which is then able to enhance light scattering via a geometry pass while also taking into account the original light source’s location.
Voxel Accelerated Ambient Occlusion
VXAO is an interesting addition to NVIDIA’s GameWorks library since it builds upon past ambient occlusion techniques while moving well beyond the abilities of typical screen space methods. In many ways it utilizes the same primitives that are present within Voxel Global Illumination (VXGI) which was introduced some time ago.
With this new Voxel Accelerated Ambient Occlusion technique, NVIDIA set out to improve upon the platform laid out by previous SSAO techniques without completely throwing the baby out with the bathwater. With traditional SSAO methods (including GameWorks’ own HBAO+ technique) developers approximate world geometry by utilizing the z-buffer from the camera’s point of view. As such, most game engines can only take into account items in the game world that are within the camera’s direct front zone. Anything past the camera front zone can’t cast shadows and neither can elements that are behind forward-facing objects.
Looking at things with a less technical mindset this all means that shadows don’t show up even though they should be in the scene and many elements of a given render are brighter than they should be. In addition, these older techniques caused some artifacts like some shadow regions popping in and out of focus depending on what camera “sees”, flickering as the player moves or constant in / out fading.
VXAO on the other hand allows the whole scene to be voxelized to the point where each voxel represents a density or opacity of geometry. For example, in the scene above red represents elements that completely contain geometry while the blue elements partially filled. This gradation allows for a much more transparent and natural representation of a given environment.
Once the scene is voxelized a lighting calculation can be done on all the surfaces which should be casting shadows to see how much occlusion there is in the surrounding area. There’s also a secondary pass done for calculation of shadowing that’s independent of the camera and thus more correct.
As you can see in the picture above with HBAO+ alongside VXAO, the differences between older methods and what NVIDIA is proposing is nothing short of revolutionary. With HBAO+ some detail on and around the tank is indeed picked up but there are plenty of surfaces that aren’t casing shadows since this AO method only uses Z-buffer information. Essentially, anything behind that “front” isn’t being addressed by this algorithm.
VXAO on the other hand displays a lot more detail since the Fast GS module allows each voxel primal to be rendered and calculated up to three times. Doing so in the tradition way results in a lot of redundant geometry but with these hardware units everything is completely accelerated with much less overhead. It leads to a lot more detail and a more three dimensional look. Unfortunately, VXAO is a more expensive solution due to the amount of information so performance impacts will be significant, even on higher end Maxwell cards.
High Fidelity Shadows
Looking back into the history of game development, the most common form of in-game shadowing has always been simple shadow maps. Naturally, those come in various quality ratings from very basic to extremely complex. Right now tow of the best are NVIDIA’s PCSS (Percentage-Closer Soft Shadows) and AMD’s similar CHS (Contact Hardening Shadows), both of which debuted in Grand Theft Auto V. Each was able to apply very lifelike gradients to shadows, making them look like they’re gradually dispersing as the shadow moves further away from its casting object. Unfortunately, these methods are extremely costly from a compute resources standpoint and neither really achieved overly lifelike results.
High Fidelity Shadows is very much the next generation of PCSS which, like other technologies in this article, runs on Maxwell’s Fast GS modules rather than within the general rendering pipeline. What it essentially does is increase the fidelity of complex and simple shadow maps without the game developer needing to enhance the shadow resolution.
In past game situations, shadows were either too “hard”, too “soft” or got detached from the object itself. It certainly wasn’t an optimal situation but then again in the middle of combat, not many folks tend to sightsee shadows.
Nonetheless, in an effort to add a higher dose of reality into a scene, HFS will combine PCSS for shadows that are more distant from their casting object while adding in a new algorithm for closer-in shadow elements. These two techniques are then blended together to create a holistic shadow image.
The Next Steps
The last thing NVIDIA touched upon was their proposed rollout for upcoming GameWorks technologies. Rather than throw them out as they become available, there will be two key dates in every year when new SDK bundles will become available. One will be at GDC while the next will be six months later. We should also see additional technologies transition towards Open Source on those dates as well.
|Latest Reviews in Video Cards|