How do i set a particle in the VFXGraph to "Orient: Along Velocity" AND "Orient: Face Camera Plane"?

As stated in the Topic, i don’t understand how I can set a particle to always face the Camera AND the direction of the Velocity?

Is there a way to combine these two settings?

I am working on a project that has a fixed, isometric camera which cannot be rotated if that helps.

I can’t give them a specific direction because they don’t fall evenly at the same angle, there is a variation to the rain.

I Appreciate every hint, how to do this :pray:
(I can only upload one picture as a new user, apparently, so that’s why the image is how it is)

It’s been some time since i did VFX work but when i wanted something like this i used to go to the “Orient (advanced)” node.

You want to get both you velocity vector & camera forward vector to mix them in the resulting orientation of your particle.

Something like this:

It gets tricky depending on your VFX coordinate space (local/world), so really give a thought about what “Axes” you really need on the Orient node, and to what space you should transform either the Camera forward and your own velocity.

There might be an easier way to set this up, but certainly Orient (advanced) is the most versatile of the orient nodes.

PD: When you DO find out how to get this right, make it a BlockOperator so you can forget about it later :stuck_out_tongue:

1 Like

Morning, so from what I can understand, the Along Velocity mode should be what you’re looking for.
If we look at the computed source code of this block, it considers the Particle’s velocity and uses it for the Y-axis used to align particles. Now the Z-axis, which is the particle’s facing vector, uses the Camera’s position.

axisY = normalize(velocity);
axisZ = position - GetViewVFXPosition();
axisX = VFXSafeNormalizedCross(axisY, axisZ, float3(1,0,0));
axisZ = cross(axisX,axisY);

The fact that you are using an Isometric camera shouldn’t be a problem here.
Now, I tried on my side, and I think that the issue that you’re having is related to “perspective impression” or the lack of it. The result would be the same with a perspective camera and a tiny FOV, as the depth impression is being squashed and everything appears like it’s on the same plane.


When looking at the Iso view, something seems wrong at first, but it’s an optical illusion due to the lack of depth information. Our eyes have trouble understanding on which depth layer are the different particles, and their velocity and Y-axis seem to be aligned on the Camera plane.

Now, If I just display my emitter source gizmo, suddenly particles alignments depth are more “readable”.


Unity_6553PkmftO

So, I maybe what you could do is to try to reinforce the depth/layer impression of your particles.
They are several ways to do this, and here is a short list that could be tested:

  • Add a small clouds/source object on top of your Rain.
  • Reinforce the depth by creating layers
    of rain instead of spawning uniformly in a volume.
  • Modulate the Size or Color and/or Alpha based on those layers.
  • Lit or Fake lighting so that particles that are supposed to be in shadow are less visible, making it more obvious where they stand in your depth.
  • Add Spawn splashes/drip at collision to help make some connection with the environment.

These are some ways that could help counter the effects that an ISO Cam can have on depth perception.

I’ve made a quick attempt to apply those solutions, and while it’s definitely more work, it “felt” better.

Unity_S3K1RHCUF2_0022-0136_600x541

I hope that I’m not wrong and that you don’t have a more in-depth issue with your orientation. If so, please don’t hesitate to continue this conversation.
Wish you a day without rain.

1 Like

Thank you so much!

This helped a ton. i managed to do it now :slight_smile:

1 Like

I’m glad that you were able to make it work!
Don’t hesitate to share your results whenever you’re happy with them.
Wish you a sunny day