Latimerias Posted July 19, 2022 Share Posted July 19, 2022 (edited) So i have a flip simulation where the water is in a lake and moving slightly up and down the land. I want to scatter some lilypads on it but am not sure how. I tried extracting points from the particle sim using their point id which kept the same points on each frame but ran into issues because i only want particles on the edge of the simulation not in the center of the lake so i was deleting all particles inside of a bounding object but particles were going in and out of this boundary causing newly appearing/disappearing points on some frames. Another problem i had is that not all the particles from the fluid sim are at the surface some are inside but i was able to somewhat get around this with a ray. Just looking for any advice, thankyou! Edited July 19, 2022 by Latimerias Quote Link to comment Share on other sites More sharing options...
Latimerias Posted July 19, 2022 Author Share Posted July 19, 2022 I got something working by initializing an attribute on the first frame where i pick certain points to keep based on their id and then i transfer that keep value to each frame of the simulation so it checks if the particle should stay or not. if(@id = point(1, "id", idtopoint(1, @id)) && point(1, "keep", idtopoint(1, @id)) == 1){ i@keep = 1; } Here the first input of the wrangle is the sim and the second is the frozen frame where i manually select points. Quote Link to comment Share on other sites More sharing options...
doc Posted July 20, 2022 Share Posted July 20, 2022 A number of different ways to handle this. 1 create a grid above your surfaced flip sim. Scatter points on the grid. Copy your flat lillypads to the points. Ray the Lilly pads onto your surfaced flip sim. 2. Create your lillypads as above. In your flip surfacing node there's an option to output a VDB. Instead of rating on a polygon surface. You can use the SDF value and the gradient of the VDB to move the points of the lillypads to the surface of the water. If you were really ambitious you could do this in a solver and actually inherit the velocities from the flip sim Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.