Loop a volume lop?

   2998   4   2
User Avatar
Member
1743 posts
Joined: May 2006
Offline
I've made a 40 frame looping vdb sequence, and pulled this into Solaris with a Volume lop pointing to /path/to/loopingfire.$F4.vdb.

Reading the docs it looks like I should be able to use a valueclip lop to make this loopable in solaris, but it's not clear how to go about this. Any clues?
http://www.tokeru.com/cgwiki [www.tokeru.com]
https://www.patreon.com/mattestela [www.patreon.com]
User Avatar
Staff
4443 posts
Joined: July 2005
Offline
I think the much easiest solution is to change the Volume LOP expression to:

/path/to/loopingfire.`padzero(4, $F % 40)`.vdb

Value clips aren't appropriate here (or are massive overkill in complexity) because the only thing being animated here is a single attribute value…
User Avatar
Member
1743 posts
Joined: May 2006
Offline
Right. I should explain the use case:

We have a big forest fire sequence, planning to publish tree assets with a ‘fire_state’ variant, with ‘fire’ and ‘no_fire’ being the options. That way the layout team can place trees in the set, and as the story develops can choose which trees are burning. Would also like to set time offsets per tree so the motion isn't twinning.

We'll be pushing these sets and setups to other apps, would the expression still work in that case, or would it have to be baked to run over 1000 frames to allow for time offset and slight speedups/slowdowns per instance?

My quick read of the usdclip stuff implies it can handle all that, hence the original question.
http://www.tokeru.com/cgwiki [www.tokeru.com]
https://www.patreon.com/mattestela [www.patreon.com]
User Avatar
Staff
4443 posts
Joined: July 2005
Offline
The expression would have to be baked over the full frame range. But this still probably isn't all that much data (1000 strings per tree doesn't seem like a big deal?)

“Slight” speedups and slowdowns aren't going to work in any case (baked expressions or value clips) because the attribute that is animating is a string, and so USD won't do any intepolation (you can't tell a volume prim to use a blending of two VDB files). So you would only be able to exactly double or half the speed (unless you have a bunch of substep VDB files, in which case you still need to make sure you hit exact substeps or you'll have some fires that occasionally freeze for a frame). Because of all this, I feel like the expression approach would actually make it easier to ensure that you were always hitting a new VDB file per frame, and generally have better control over the rate of change of the fire.

All that being said, using value clips should work too, and the Value Clip LOP should let you set this up. I've attached a hip file that shows how to use a Value Clip LOP to do this.

Attachments:
VolumeValueClipLop.hip (185.0 KB)

User Avatar
Member
1743 posts
Joined: May 2006
Offline
Awesome, thanks Mark!
http://www.tokeru.com/cgwiki [www.tokeru.com]
https://www.patreon.com/mattestela [www.patreon.com]
  • Quick Links