Jump to content

Varying animation speed based on velocity


Recommended Posts

Hello!  Houdini noob here, asking what I'm sure has a straightforward answer, but I haven't been able to find anything that does quite what I need.  

Basically I've created a particle system that I'm instancing spiders onto, and I have a loopable Alembic-cached walk cycle of the spider.  I'm trying to use the velocity of the particles to drive the playback speed of the walk cycle.  So the faster the particle is moving, the quicker the walk cycle playback and vice versa.

Where I seem to be hitting a wall is when the particles slow down, the animation starts playing in reverse.  I tried to set up some sort of way to have the velocity cumulatively add to itself each frame with a Solver SOP, but I can't seem to get that working properly.  Not sure how to best approach this at this point.

I've attached a simple scene that has the basic setup I'm using, in case that's helpful.

 

Thanks!

 

animation_playback_by_speed.hip

Link to comment
Share on other sites

You had the right idea with the solver! I did exactly as you were thinking :) additive velocity that controls a copy stamp that affects an upstream timeshift SOP.

Your use of alembic frame is interesting and new to me; I don't have your test abc to see how that works, but you should be able to adapt my setup to work with yours.

animation_playback_by_speed_v3.hip

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