Jump to content

Particles On Curves


Visual Cortex Lab

Recommended Posts

is there a way to ... "drive" the way of particles with curves? ... i need get something like the water flow on a river which avoids rocks and such.. by drawing curves for the particles motion .. or to make another example to create a crowd of insect that walks around a room.. avoiding stuffs... but i wish to "draw" the path.. that's it. and not just one curve.. many.. which the particle system should distribute itself on the curves.

any idea is welcomed.

:)

cheers

Link to comment
Share on other sites

there are a number of ways to use curves to drive particles.. i suggest doing a quick search here and over at sesi forums for the different methods available (attractors, creeps, etc)..

as far as what you're wanting to do.. why not just send your particles down the river and use attractors with negative radial forces on your collision objects? Also, you'll probably want some direct collisions against the objects as well instead of just simple avoidance, so play with some bounce/slide action off of those..

hth

Link to comment
Share on other sites

is there a way to ... "drive" the way of particles with curves?

23257[/snapback]

Download the tangent sop from the houdini exchange and apply that to your curves.

then you can use the attribute transfer pop to have the particles inherit the tagent attribute

and use this to move your particles.

If you have trouble let me know and I'll give you a more detailed description.

all the best

Luca

Link to comment
Share on other sites

why not avoiding the tangent thing and simply using sortSOP to order the points + pointSOP to align the normals along the curvature, and then as doc said - attribute transfer.

23264[/snapback]

I assume you mean subtracting the position of one point from the other to get the normal.

the only problem with this is that you always get one normal that's screwed up (the point at the

end of the line points to the point at the begining of the line). The tagent sop's nice

because it avoids this problem.

As an aside you could always use primduv expression (which is what the tagent sop uses)

to get the tangent.

typical houdini, many ways to skin a cat :)

Link to comment
Share on other sites

hm .. ok i archivied to use of force/curve setup ... but.. now i've got a problem .,, about distribution of particles.

with such method i see all my particles like running ON the curve... while what I'd like it to create some path where particles should stay (randomly) on or close to it... but not attracted until they all lay on the curve... like having "tubes" where those particles should walk inside once they're attracted ... hope this help showing my target :)

cheers.

Link to comment
Share on other sites

Howdy,

I did something like this recently. One of the things I struggled with is that my particles had to move very fast, and using the tangent method they would inevitably stray off the curve. I created a system where the particle wouldn't look at the tangent of the curve, but rather it would figure out where in relation to the curve it should be next frame, after which I would set the acceleration to that. I think I did it by setting the uvs on the curve to real world scale, and looking at the velocity of the particle I could figure out how far along the curve it would travel, then grab the position, N and up from the curve based on the uv I calculated and figure out where the particle would go. I had much more control that way, and since you're only modifying acceleration, you could still add noise, gravity, etc, and it would look fairly natural.

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...