tyFlow Forum
Camera Cull operator with Delete operation deletes all particles - Printable Version

+- tyFlow Forum (https://forum.tyflow.com)
+-- Forum: tyFlow Discussion (https://forum.tyflow.com/forum-1.html)
+--- Forum: Bugs and Issues (https://forum.tyflow.com/forum-3.html)
+--- Thread: Camera Cull operator with Delete operation deletes all particles (/thread-4015.html)



Camera Cull operator with Delete operation deletes all particles - Viper - 12-14-2023

I make a simulation of underwater bubble particles behind moving torpedo. I have a camera behind torpedo which is attached to and following torpedo. I use Camera Cull operator (Frustum) to hide particles out of camera frame. I use Camera Cull as Hide operation. But I actually do not need particles which are out of camera frame, so, I think I could use Camera Cull in Delete operation instead of Hide. But when I change operation to Delete mode then all particles are deleted. I expected that only particles out of camera frame will be deleted, similar as Hide operation. Is this a bug or I just misunderstood how Camera Cull Delete operation works?


RE: Camera Cull operator with Delete operation deletes all particles - tyFlow - 12-14-2023

Can you post a file so I can test your setup?


RE: Camera Cull operator with Delete operation deletes all particles - Viper - 12-14-2023

(12-14-2023, 05:27 PM)tyFlow Wrote: Can you post a file so I can test your setup?

Here is the file attached. I work in Max2024 but saved file in version Max2021 just in case. In this file you can find two tyFlow setups. One is plankton particles with two Camera Cull operators I asked early about issue with exporting to tyCache, and another tyFlow setup is for bubbles with Camera Cull Delete operation I ask in this thread.


RE: Camera Cull operator with Delete operation deletes all particles - tyFlow - 12-15-2023

When your Cull operator is in 'delete' mode, it's being evaluated in regular operator order. In this case, it's deleting all particles because it's being evaluated before any particles are placed where you want them using the Position Icon operator...instead they're sitting at [0,0,0] when the Cull operator executes, which is out of the frustum.

Move the Cull operator to the end of the event and it'll function as intended.


RE: Camera Cull operator with Delete operation deletes all particles - Viper - 12-15-2023

This makes sense. Thank you for clarification! Would be nice to have such information in documentation as well.


RE: Camera Cull operator with Delete operation deletes all particles - Viper - 12-16-2023

Is there a reason Camera Cull operator shouldn't always be latest in event order? I think in Particle Flow Camera Cull operator event order was not important.


RE: Camera Cull operator with Delete operation deletes all particles - tyFlow - 12-16-2023

In cull mode order doesn't matter, but in delete mode you're directly affecting in the sim in a history-dependent way, so order matters.