Im trying to get an L system to start growing where a particle hits the ground. i have the basics of it working with particle instancing but the instanced cache it brings in it reads from the current frame number so when the particle hits the tree is already half grown, and when the next one hits it is already grown to the same level as the first ect..
How can i get the instance to read in from the start of the cached animation? or is their a better way to cache it out so it reads in as a sequence/animation rather than frames?
Particle instancing Cached animations
3875 7 2- nikmolson
- Member
- 54 posts
- Joined: Dec. 2011
- Offline
- sadhu
- Member
- 112 posts
- Joined: Feb. 2010
- Offline
One of the solns is copy stamping. Shifting the animation using timeshift sop and copy stamping.
1)In popnet add hittime attrib (on collision pop)
2)Copy animated Lsystem on the output of popnet1
3)In copy sop go to stamping , create variable , say tshift. Set it's value equql to hittime. Use point expression to access hittime value. Your expression should be something like this.
point(“../popnet1”,$PT,“hittime”,0) * $FPS (Multiply by $FPS to convert hittime in frames)
5)Connect timeshift node after lsystem.
6)In timeshift node write the following expression
$F - stamp(“../copy1”,“tshift”,0)
I dont have Houdini in front of me but this should give you an idea.
1)In popnet add hittime attrib (on collision pop)
2)Copy animated Lsystem on the output of popnet1
3)In copy sop go to stamping , create variable , say tshift. Set it's value equql to hittime. Use point expression to access hittime value. Your expression should be something like this.
point(“../popnet1”,$PT,“hittime”,0) * $FPS (Multiply by $FPS to convert hittime in frames)
5)Connect timeshift node after lsystem.
6)In timeshift node write the following expression
$F - stamp(“../copy1”,“tshift”,0)
I dont have Houdini in front of me but this should give you an idea.
- nikmolson
- Member
- 54 posts
- Joined: Dec. 2011
- Offline
- nikmolson
- Member
- 54 posts
- Joined: Dec. 2011
- Offline
so I have all that working but now im trying to use the same type of stamp expression on a switch to alternate which cached sequence is used each time a particle hits, but each time a new particle hits it switches all the instances over… any reason this shouldn't work? or a better way to go about this?
im creating a new variable in the copy node called switch, setting its value to
round(rand($ID))
and in the switch node using the expression
stamp(“../copy1”,“switch”,1)
im creating a new variable in the copy node called switch, setting its value to
round(rand($ID))
and in the switch node using the expression
stamp(“../copy1”,“switch”,1)
- zdimaria
- Member
- 390 posts
- Joined: Jan. 2012
- Offline
- nikmolson
- Member
- 54 posts
- Joined: Dec. 2011
- Offline
- sadhu
- Member
- 112 posts
- Joined: Feb. 2010
- Offline
- nikmolson
- Member
- 54 posts
- Joined: Dec. 2011
- Offline
It doesn't seem to like $PT, nothing shows up, iv posted the scene here http://www.sidefx.com/index.php?option=com_forum&Itemid=172&page=viewtopic&t=25856 [sidefx.com]
if anyones willing to take a look
if anyones willing to take a look
-
- Quick Links