PGD Home

NVIDIA PhysX, VisualFX (TurfEffects, HairWorks, etc) and T3D

by on Feb.07, 2016, under Miscellany, P-0, Software and Games

While researching technologies for my virtual world project, I looked into a realistic physics library. This would allow me to further explore dynamic content, by allowing players to, for example, construct objects, buildings, or simple machines from discrete elements in the world, using only the physics model to “Make them work”. I would not need to use prefabricated objects, object combinations, and scripted logic and mechanics. I don’t know if this concept will work out, but I am planning to research it in more detail, and come up with a concept. There are a few options out there for physics libraries in games. The main ones I found were NVIDIA’s PhysXBullet Physics, and Intel’s Havok physics, and ODE.

I am not going to spend time comparing the advantages and disadvantages of different physics engines, but suffice as to say, the two main options for T3D are Physx and Bullet Physics. Bullet is open source, but PhysX is free for commercial use, so there really is advantage in price. I am leaning towards PhysX, mainly because it seems like the most supported (by commercial projects) engine, and it seems like the most fully featured, although Bullet is catching up. PhysX is used in many Triple-A games, and it part of Nvidia’s “GameWorks” technology package.

GameWorks also contains several other fascinating and powerful technologies, including one that I am particularly interested in, NVIDIA TurfEffects. I haven’t looked into the licensing of this yet, or the work required to integrate it into T3D, (Nvidia’s website mentions a dependenc onf DirectX 11, currently, T3D uses DirectX 10, but this is being worked on) however, this system capability to render grass is staggering. I have seen many games, even high quality games, use what is obviously a randomly generated sprite system for grass. A 2D sprite is created, animated, and then replicated many times in the world. The effect looks decent, but unless the object count is very high, the grass just looks patchy and fake. In addition, the sprites will be billboarded, which means that they will rotate to face the player. This prevents the player from noticing that the grass is two dimensional. This can cause problems if the player views the grass from above, or from an extreme angle.
However, with TurfEffects, the grass is not only completely seamless with no patches or dead spots, it is also capable of collision! Even large grass fields support deformation due to player footsteps, or objects striking the grass. This video, from Nvidia’s site, demonstrates this:

According to the video, TurfEffects allows one millions blades of grass to be drawn in less than a millisecond, using a GTX 680, which is incredible performance.

Nvidia’s Gameworks also features HairWorks, which provides superbly detailed hair and fur simulations. This solves an irritating problem in the creation of characters for games. Hair is normally modelled as a mesh, similiar to any other object, and then either left static, or animated as a mesh, which looks very stilted and wooden, and very poor looking. This is one of the things that I, as a developer and gamer, just accepted as the status quo in games, since real time hair physics was just not really possible. However, with solutions like HairWorks, this may change. From watching the below video, it is surprising to see how much of a difference realistic hair actually makes to the depth and immersion in a game. This is a video, from Nvidia, of HairWorks in action:

Again, I don’t know what type of licensing or pricing HairWorks uses, (It’s not on Nvidia’s site) and I am also not sure how easy, or even how possible, it would be to integrate this into T3D. This is an area where using a more populate engine, such as Unity or Unreal, would be an advantage, since there would be greater support for the integration of technologies like this.

I personally tend not to like to use external libraries and resources, I am reluctant even to use art packs, since I prefer to create everything completely from scratch. I do use engines, such as T3D, and I do use some resources and libraries, but I try to create my own solutions and art when possible. However, the time required to “reinvent the wheel” like this will get prohibitive for a massive undertaking like a virtual world. I intend to seriously look into various libraries and tools to make the job easier. Some, like PhysX and MakeHuman, will be readily available, however, other technologies will have to be developed, such as a Spherical Terrain implementation (I was never able to find a library or resource which fit my needs).

Virtual Worlds are my main area of interest, if I am going to create the world that I am working towards, I am probably going to have to make use of any tools that are available. This is especially true with art and animation tools, since I have much more limited skills in this area.

Facebooktwitterredditpinterestlinkedinmail

Comments are closed.

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!