Search Unity

Question How to use Attractive Force on a constantly updated particle system

Discussion in 'Visual Effect Graph' started by scarscarin, Apr 4, 2021.

  1. scarscarin

    scarscarin

    Joined:
    Apr 5, 2019
    Posts:
    23
    Hello and happy Easter :)



    In the video above you can see my latest test to manipulate a volumetric live recording from Kinect to Unity.

    The process is quite simple: I'm using the "Azure Kinect Examples For Unity" package to get the point cloud from my Kinect v2, which uses a VFX Graph to constantly update a particle system based on rgbd data from the sensor.

    I was trying, then, to play with attractors (or repellers) by implementing a force field to the VFX Graph like in the image below (I followed this tutorial)



    As you can see in my video, the particle system keeps updating itself in the original place, hence the flickering effect. I can imagine I'd need to average [OriginalPos * (ForceFieldPos * OriginalPos)] and spawn the particles in a new position that is in between their original one and the attractive force field, and avoid the flickering effect.

    In a bigger picture, this is to stream the volumetric system in VR and influence the particles with the tracked hands of the user.

    Let me know if you have any suggestions on how to debug this :)