Jump to content
garf

Copy Stamp / For-Each / Compile-Block

Recommended Posts

Hi all,

I'm building a crude crowd-like system using POPs and I'd like to copy my imported walkcycle on to the particles with a random timeoffset. The old method of copystamp with a timeoffset value on a timeshift node works - but it's really slow. I've been reading up on the for-each / compile block method but I'm unable to compile timeshift or file nodes.

So my question is - is it possible to do it with a for-each/compile setup or am I stuck with the old copystamp method?

Share this post


Link to post
Share on other sites

Indeed, File node is not compilable (you can display the "badges" to see which nodes can be compiled, in the Display option).

But I remember from the video of Jeff Lait there are tricks to use non-compilable nodes, but outside of the network : you need to create many "Compile Begin" nodes as you want and setup them as "fetch input", so that they serve as input point for the compiled blocks.

You can try that to use Files node to read a cache of your particles, and also the crowd-agents. But I am afraid that by doing so, you don't gain a lot of time multithreading the instancing of cache files on points... I am pretty sure the speed of hard drive and then the graphic card are more limitating than the CPU tasks for this kind of things... but I may be wrong :-)

Let us know if this works and how many times you gained !

Look around 00:25 of this video, he talks about using Copiled Begin setup for Fetch Input :

 

Share this post


Link to post
Share on other sites

Thanks - this example by anim is perfect for what I need - I've converted my walkcycle to an alembic and it's lightning quick

 

Share this post


Link to post
Share on other sites
Posted (edited)

@anim - I'm curious. I've been buggering about with this today and I'm lost as to what's going on.

I've been trying to use your suggested setup for offsetting alembics. i.e. wrangle and timeoffset value and then applying it after a copy to points SOP using a setprimintrinsic(0, "abcframe", @primnum, f@time);

I don't see the animation offset on the copies unless I unpack. Do you know why this would be?

cheers for all your help

Edited by garf

Share this post


Link to post
Share on other sites

it looks like a bug,

something with alembic and overall packed primitives viewport optimization in H16.5

H16.0 seems to be fine

  • Like 1

Share this post


Link to post
Share on other sites

Thanks for confirming that. I'll post a bug report

Share this post


Link to post
Share on other sites

Just for posterity - the build 16.5.268 has this issue. The latest build (16.5.438) does not.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×