We present a hydrodynamic simulation system using the GPU compute shaders of DirectX for simulating virtual agent behaviors and navigation inside a smoothed particle hydrodynamical (SPH) fluid environment with real-time water mesh surface reconstruction. The current SPH literature includes interactions between SPH and heterogeneous meshes but seldom involves interactions between SPH and virtual boid agents. The contribution of the system lies in the combination of the parallel smoothed particle hydrodynamics model with the distributed boid model of virtual agents to enable agents to interact with fluids. The agents based on the boid algorithm influence the motion of SPH fluid particles, and the forces from the SPH algorithm affect the movement of the boids. To enable realistic fluid rendering and simulation in a particle-based system, it is essential to construct a mesh from the particle attributes. Our system also contributes to the surface reconstruction aspect of the pipeline, in which we performed a set of experiments with the parallel marching cubes algorithm per frame for constructing the mesh from the fluid particles in a real-time compute and memory-intensive application, producing a wide range of triangle configurations. We also demonstrate that our system is versatile enough for reinforced robotic agents instead of boid agents to interact with the fluid environment for underwater navigation and remote control engineering purposes.
翻译:我们提出了一种利用DirectX GPU计算着色器实现的流体动力学模拟系统,用于在光滑粒子流体动力学(SPH)流体环境中模拟虚拟代理的行为与导航,并实现实时水面网格重建。当前SPH文献涉及SPH与非均匀网格的交互,但很少涉及SPH与虚拟Boid代理的交互。本系统的创新在于将并行SPH模型与分布式Boid虚拟代理模型相结合,使代理能够与流体产生交互。基于Boid算法的代理会影响SPH流体粒子的运动,而SPH算法产生的力也会反作用于Boid的运动。为在粒子系统中实现逼真的流体渲染与模拟,必须从粒子属性构建网格。本系统在管线中的表面重建环节也有贡献——我们采用并行Marching Cubes算法逐帧从流体粒子中构建网格,在实时计算与内存密集型应用中生成了大量三角形构型。实验表明,该系统具有良好通用性,可替代Boid代理的强化学习机器人代理与流体环境交互,应用于水下导航及远程控制工程。