Jump to content
Sign in to follow this  
FR3D

Convert vops to wrangle (different result)

Recommended Posts

i am trying to reproduce a ramp sliding effect from vop to wrangle.

I used the vop version for very long without issue,i add a parameter before the ramp to move its position(usually used to slide the ramp across UVs)

For some reason it seems i am not reproducing the wrangle the right way.

you can see the vop in the pic and my attempt at reproducing it in wrangle.

i posted the file.

 

script:

float ptnum = (float)@ptnum;
float numpt = (float)@numpt;

float anim = chf("page_animation"); //slider from -1 to 1
float div = ptnum/numpt;
float bend_anim = div+anim;

float ramp_bend = chramp("ramp_bend",bend_anim);

@bend = fit(ramp_bend,0,1,chf("bend_left"),chf("bend_right"));//slider from -90 to 90

voptowrangle.jpg

book_odforce.hip

Edited by FR3D
  • Thanks 1

Share this post


Link to post
Share on other sites
1 hour ago, Aizatulin said:

Hi,

this should work


float grad_anim = clamp(div+anim, 0, 1);

 

Yep it does thank you.

Does that mean that in vops it is automatically clamped?

Share this post


Link to post
Share on other sites

I think spline/Ramp Function do this normalize In Vop ...guessing

  • Like 1

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
Sign in to follow this  

×