PDA

View Full Version : Dynamics Question


Jhonus
02-28-2002, 03:53 PM
Is there a way to simulate sand falling out of a hole in a cube and having it pile up on the ground?

I'm not very experienced with dynamics... is it possible to do this?

Terekki
02-28-2002, 10:42 PM
AIX, I'd actually be interested in how you did that, could you post?

rsalonen
02-28-2002, 11:05 PM
Yes me too, I'm intrested to learn every little part of maya (thou that will be hard :) ) so please tell us how you did that ;)

alx
03-01-2002, 12:11 AM
ok.. forget about the modeling ( it isn't important for this part)

sorry for the i thinks i just did it before and know im home... but its a good aproximation
create an emiter.. put it where it would be pouring from the box.

emit 100 particles (default)
render type multipoint
not omni but directional direction x or z (depends on the way your box is looking) to 5
spread , about 0.9 ( i think)
then with the particles selected create gravity
now you have that arch movement
then
change the lifespan to constant( i think) and change it until it goes jut under your plane

ps... if you want it to look a bit better you might want to use the particle pp lifespan and atach a ramp... but it almost looks the same

so now you have the pouring part

k... too many characters... next message LOL

alx
03-01-2002, 12:19 AM
the next part is making them look like they are acumulating

( we fake this )
create another emiter.
DON'T attach it to the gravity

make a volume
volume shape cone
then scale it untill you have it wow it'll look once al the pouring has been done. ( note what are your scale numbers on xyz)
and position it.. just over the plane and in the middle of the falling particles..
speed 0 and tangent speed 0.
( but i think that there is no need to change the tangent speed)
then
play... if the particles ar kind of like apering out of the blue inside the cone shape you are on the right track!!
then.
emition rate ( from 100( default) to say 200 or 300.

then go to frame 0 ( unless you allready are there)
and play.. stop when the pour hits the floor. and scale the volume shape to 0.004 xyz
set a key

Sorry part 3 LOL

alx
03-01-2002, 12:23 AM
then keep on playing and stop where you think that the acumulation is bigger and scale the volume to a bigger number 3 or 4( depends on you scene) but make sude that X and
Z are bigger than Y so that its a little more flat
set a key
Once that is done
go bak to the first KEYFRAME of the volume
and set the rate to 0
then after 1 or 2 secs (thats 30 or 60 frames more or less)(depends on your frame rate)
set the rate to 200 or 300
and set a key...
if im not wrong..
that should do it..

ill try it tonight and post the scene..

ps i use maya 4 in case you have maya 3.. if so let me know... i also have maya 3.. but i don't remember now if it has voulme shapes...

k see ya

sincerely

alx

Jhonus
03-01-2002, 01:12 AM
wow, thanks Alx. :)

Is it not possible to have the sand falling to form a pile? (Rather than using the fake)

stark-001
03-01-2002, 01:23 AM
yes yes yes ... i never though about this .... but Excelent thread

thanks for the input axl ...

alx
03-01-2002, 04:04 AM
Krugar ... yes it can be done.. i guess that as anything in 3d there is always more then one approach...
another way that i can think of doing t is
make the plane a pasive rigid body collition 0.001
and then when the pouring particles collide with the plane make a particle collition event..
then once you create it you make the orginal particle die
"original particle Dies" /on/
and then make the new emiter a volume shader and then repeate pretty much the same thing i did...
so now it is created and activated upon particle collition.. but it becomes more processor heavy... and as you know we try to get away from that in a production env...

well hope that helps...

sincerely

alx

ps ill post the mb file later on today...:D

alx
03-01-2002, 05:21 AM
here is the file

this is with no particle collition nor the fake idea...
straight up particles...
the trick is tho make the bounciness of the floor 0
and the resilence of the second geoconector 0.001 (geoconector2)
this is the seccond collition.. FYI..:p
hope that helps a bit...
and if you want me to ill post the fake... but let me know...

sincerely

alx
:D
ps i think that the damping of the floor also should be set high... i put it on 5

select -r particle1 ;
select -tgl nurbsPlane1 ;
collision -r 1 -f 0 nurbsPlane1;
// Result: nurbsPlaneShape1 //

connectDynamic -c nurbsPlane1 particle1;
// Result: particleShape1 //

setAttr "rigidBody2.damping" 5;
setAttr "rigidBody2.bounciness" 0.001;
select -addFirst geoConnector2 ;
setAttr "geoConnector2.resilience" 0.2;
"i had to change the resilence "

setAttr "geoConnector2.resilience" 0.001;
and this was the best result of the resilence.

it took 7 minutes to create the scene more or less.

hope that helps guys..

Jhonus
03-01-2002, 05:44 AM
Ok, I've been holding back the third part of the problem :)

An object needs to rise up through the pile of sand and displace the sand as it does so.

Thanks Alx, great help your giving here. Much appreciated.

oh yeah, it would be cool if you could post that "fake" version too... ;)

Grooveholmes
03-01-2002, 11:27 AM
This has been something i've tried to do a few times but couldn't get, mel is the key, but sadly i'm pretty mel illiterate.

alx- The scene you just posted is cool but the particles still dont 'pile' up like in an hourglass.

I think the best thing for this situation is to composite seperate elements. You would get the best control, look, and feel that way. We've gotten pretty good results like that.

alx
03-02-2002, 06:31 PM
k... here is te scene with the pile up... hope it helps... the main thing to keep i mind is:
a. the falling p[articles need to die after amout 5 secs ( save procesing time)

b. the volume emmiter needs top be 0 on spped, away from center and away from axis. ( specially away from axis)

hope it heps...

alx

PS... sorry i had to delete the vid... but i need space to put another one for the Gi post...
sorry...
;)


sincerely

Chappo
03-02-2002, 10:54 PM
i was thinking here...

and i had a thought...

What if you made those particles collide with the plane (or other objects nearby) and making those particles collide with each other....

Then you won't need a new emitter for the (fallen) particles and it also adds a realistic motion to it all....(it will pile up and stuff)
I know that it will put a heavy strain on the cpu as every particle will have to be calculated upon collision....

Hmmm.... i'm kinda curious what you guys think of this method...

Grooveholmes
03-02-2002, 11:40 PM
Or maybe just have the particles collide with the groundplane, and animate a bulge slowly coming up on the ground, that way the particles could still slightly bounce and slide when they land. As long as the coverage of particles is thick enough you shouldn't be able to see the ground plane bulging unrealistically.

CGTalk Moderation
01-13-2006, 01:00 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.