Jump to content

Particles along surface


Jesper Rahlff

Recommended Posts

Greetings to the best forum on the web :)

I am struggling a little with wrapping my head around the xyzdist() and primuv() functions in vex.

I have attached a scene file that holds a dopnet with some points created on frame 1. I would like those points to stick to the geometry coming into the second input on the dopnet.

any suggestions to how this could be done is appreciated. I am in particular interested in the usage of the xyzdist() and primuv() solution, however other methods is also encouraged!

should there be some people that wanted to "show off" a little vop magic that is cool too.

looking to learn so hit me with everything you got.

 

All in all a simple task but good fun.

 

Thanks for playing :)

Cheers

particles_on surface.hiplc

Link to comment
Share on other sites

Heh, I was taking at dig at my lazy self, not your question. :)

You're right, pushing along @N should work, curious that it doesn't. It was more to do with how the sprite display sits right on the surface, so they'd clip, this was a cheap fix. If this were a Proper Solution, I'd instance real geo that was properly offset away from the origin along z, so they roll along the surface, or use a peaked version of the geo for the sim, and non-peaked for the merge at the end.

 

Link to comment
Share on other sites

16 hours ago, mestela said:

minpos is my new favourite lazy way.

 

pop_minpos.hipnc

Pop_minpos_capture.gif.73e02a0add4c3477af0ddcad07bdd73e.gif

This is cool. However with the minpos the position does not stick on the sphere if the sphere was animated. I am looking for a dop way of doing a scatter -> attrib interpolate to keep the points at the same spot on the geometry.

Link to comment
Share on other sites

13 hours ago, mestela said:

How accurate do you need to be? Point deform works well if your standards are low (and still works pretty well if your standards are higher than that, within reason)

pop_minpos_align_pig_pointdeform.hipnc

pig_surface_pops_deform.gif.ef3537667240c6d6d5de59ee6b779a7f.gif

 

It does not have to be 100 percent accurate  the problem with doing it with a pointdeform (or any post sim solution I could come up with), is that I am not getting the animated  geometry velocity as an effector on the particles (when  desired).. Let me explain a littte better:

- first step is to get the particles  to stick to a surface. (scatter ---> attrib interpolate, or point deform as in your example).

- second step is to get some animation on the particles (can still be done in sops as per your example).

- third step is to release the particles from  the surface having them  inheriting the velocity from the animated object (this is where I think dops is requered rather than sops, which is why I want step one and two to be in dops as well)

- fourth step is to not have all the particles exist one frame one, but get born over time, pickup their animation, and then based on some attribute created in step 3 get released and get velocity from geometry animation.

 

I hope this clarifies a little more what I am trying to do.

I appreciate every ones time so far.

 

Cheers

 

 

Link to comment
Share on other sites

I can't open your hip cause i have no access to H now but i'm curious :

Why do you guys prefer to use either

- primuv() / xyzdist()

- or min pos ?

Instead of the classical sdf and volumegradient() / volumesample() path ?

- inject a non divergent noise with curl noise for ex

- stick the pop to surface with the distance to sdf

Sound like a good option too ?

What are the advantage of other methods in this scenario ?

Thanks for your lights !

Cheers 

E

EDIT:

here is a test with sdf method.

i also love Matt technics didn't know this one ... pbd stuff looks really cool.

 

 

 

goal_sdf.hipnc

Edited by sebkaine
Link to comment
Share on other sites

On 12/17/2017 at 2:29 AM, Jesper Rahlff said:

Greetings to the best forum on the web :)

I am struggling a little with wrapping my head around the xyzdist() and primuv() functions in vex.

I have attached a scene file that holds a dopnet with some points created on frame 1. I would like those points to stick to the geometry coming into the second input on the dopnet.

any suggestions to how this could be done is appreciated. I am in particular interested in the usage of the xyzdist() and primuv() solution, however other methods is also encouraged!

should there be some people that wanted to "show off" a little vop magic that is cool too.

looking to learn so hit me with everything you got.

 

All in all a simple task but good fun.

 

Thanks for playing :)

Cheers

particles_on surface.hiplc

This method uses the function you want to learn about it! And the nice thing is that is very simple to implement. Of course you need also to implement the goal using forces or modifying directly the position to attract to the surface plus this, and because we are saving the delta, all points will always stick to the rest sampled position.

Cheers!

Alejandro

particles_on surface_aeb.hiplc

 

Edited by Pazuzu
  • Like 1
Link to comment
Share on other sites

Thanks everyone for your contributions. You guys all have a different but clever solution.

I setup an example myself as well, and this is what I came up with. 99% of the magic happens in the POP network with just a few lines of vex. This setup is very simple but it still have collision with moving and static particles on the surface. (thanks popgrains!).

 

anyway let me know what you think :)

 

@mestela you should consider adding this topic to your Wiki if it does not already exist. this opens up some really cool possibilities for advanced FXs.

@Farmfield Thanks for sharing your RnD adventure and making the hip files available! you rock.

 

 

 

particles_on surface_dopsolution.hiplc

  • Like 1
Link to comment
Share on other sites

13 hours ago, mestela said:

There already was a section, I've been cribbing from my own notes to contribute to this thread. :)

http://www.tokeru.com/cgwiki/index.php?title=HoudiniDops#Pop_stick_to_surface

 

 

Awesome! I should have looked there first before starting this thread then :P I just couldn't find anything on the subject.. maybe I skimmed through your site to fast for this one.

Thanks for the wiki man. It is really the best ressource out there (maybe except for odforce).

  • Like 1
Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...