Physx, one of the world's best physical engines, is gaining more and more attention after being acquired by NVIDIA, the graphics boss. Not long ago, NVIDIA released a graphics card driver supporting physx cuda, which officially announced to the world that the era of physical acceleration with graphics cards is coming.
Let's take a look at how to use physx to simulate a fluid.
The physx development kit contains a fluid simulation part. In its example, we can find related examples, and the fluid is based on, however, we will find that its example only achieves particle simulation of the fluid, and converting from the particle to the part of the mesh requires us to implement it ourselves.
Grids generated by particles are usually made using the marching cube or metaball deformation ball technology. This technology has been proposed by foreigners for decades. There are also a lot of related information on the Internet, if you are interested in its principles, do not go into depth.
About the marching cube technology, you can take a look at the generating complex procedural terrains using the GPU in chapter 1 of NVIDIA's GPU gems 3.
This section describes the technologies in detail. Http://http.developer.nvidia.com/GPUGems3/gpugems3_ch01.html
Metaball has many problems.ArticleLook at this: http://http.developer.nvidia.com/GPUGems3/gpugems3_ch07.html
------------------------------------------------