Jump to content

Attribute Wrangle Run Over Points


Recommended Posts

Hello,

I don't understand how I do this and was hoping someone could help me. With this basic script in a Wrangle, set to run over 'Points', it works as expected. When I switch it to run over 'Primitives', nothing happens and it breaks. Could someone please explain how I do the equivalent when it is set to run over 'Primitives' please? For a bigger script I require it to run over primitives, or at least I believe so.

v@new_pos;
getattribute(@OpInput2, @new_pos, "point", "P", @ptnum, @vtxnum);
vector blend = lerp(@P, @new_pos, ch("blend"));
@P = set(blend);

Cheers

Link to comment
Share on other sites

Guest mantragora

1. There are more points that primitives, how do you want to interpolate data between points?

2. If you go over primitives, than you are not getting all point positions, because it will not loop automatically over each point in getattribute(), only over one point in each primitive. You need to get all point positions from each primitive and loop over it.

Thats for start :)

Link to comment
Share on other sites

Maybe it's easier to explain with a scene so below is a stripped down version.

When you play the scene and look inside (solver1/mover) - you'll notice that the points move at different speeds. My wrangle node is trying to get the previous frame point position, and the add a vertex to the new point position. But for some reason it isn't working correctly. On the other side I have dropped a tail Sop down and that is working correctly, so I'm not sure where I'm going wrong? I maybe of course, be going about this entirely wrong so I would appreciate some advice.

Thanks

 

https://dl.dropboxusercontent.com/u/2802779/Wrangler_A1.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...