hyperforce Posted August 2, 2013 Share Posted August 2, 2013 (edited) I'm trying to write a set of values to a set of of points using the attribWrangle node and VEX. These points are processed using a for loop that deals with each point number in sequence. However, when I use the default @foo = value; function it simply overwrites the values of the foo attribute for all the points, not just the one my for loop is processing. This leaves me with all my points containing the attribute values of the last processed iteration. I know that with a point function you can extract the attribute value of a specific point.Can you also write it, using vex in a attribWrangle sop? Edited August 2, 2013 by hyperforce Quote Link to comment Share on other sites More sharing options...
dennis.albus Posted August 2, 2013 Share Posted August 2, 2013 What exactly is it that you are trying to do? Could you post an example? To me it seems that you don't need a for loop because vex automatically deals with each point individually. Right now it sounds like you are doing the following: - vex gives you the first point - for this point you loop through all points and set the value @foo - this value is set for the first point and not for the point you are iterating over in the for loop - that means that @foo will always get the last value that gets set in the for loop This process is repeated for every point which means that all the points will get the same value for @foo. It's a little tricky to explain, but I hope it makes things a little clearer. Check out my example file. -dennis attribwrangle_loop.hip Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.