Guna Posted July 18, 2018 Share Posted July 18, 2018 Hello Everyone, Can anyone explain how to set parameter values using VEX function? Say for example,there is a sphere, scattered. If the current frame is between 5 and 10, the number of scatter points should be 10 else 0. if(@Frame >= 5 && @Frame <= 10) { @scattercount=10; } else { @scattercount=0; } How to set @scattercount to force total count parameter of scatter sop. Thank you. Quote Link to comment Share on other sites More sharing options...
ikoon Posted July 18, 2018 Share Posted July 18, 2018 Hi! You could reference a wrangle node with this expression: detail("../detail_wrangle","scattercount",0) Attached is the complete solution. scatter.hiplc 1 Quote Link to comment Share on other sites More sharing options...
bunker Posted July 18, 2018 Share Posted July 18, 2018 you can also use hscript directly in the parameter field: if($F>=5 && $F<=10,10,0) 1 Quote Link to comment Share on other sites More sharing options...
Guna Posted July 19, 2018 Author Share Posted July 19, 2018 Hi ... Thanks for the replies. Both the solution works fine. Quote Link to comment Share on other sites More sharing options...
Guna Posted July 23, 2018 Author Share Posted July 23, 2018 Similarly, how to use a value from vop to set parameter values? Quote Link to comment Share on other sites More sharing options...
ikoon Posted July 23, 2018 Share Posted July 23, 2018 As regards the technique that I have posted ... it doesn't matter if the detail attribute was created in VEX or VOP. I attach the updated version with VOPs. scatter-vop.hiplc 1 Quote Link to comment Share on other sites More sharing options...
Guna Posted July 24, 2018 Author Share Posted July 24, 2018 Thanks a lot jiri 1 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.