Forum Replies Created

  • Adam Fuller

    February 27, 2014 at 8:01 pm in reply to: Animating a slider control with a checkbox

    Actually I seem to have got it working now, it’s not ideal but I think it’ll do for the project I am working on.

    Now when it looks at the value of the nearest keyframe, and it’s equal to the value it wants (in this case 10) it starts the 0-100 animation. When the nearest keyframe changes to something else, it looks at the previous keyframe to see whether it was the value it wanted (10) before firing the 100-0 animation.

    This keeps all the expressions from firing the 100-0 animation before they are at 100.

    There are still some issues, you need 2 keyframes at the start of the animation, I used frame -1 and -2, or else the the expression will attempt to evaluate a keyframe[0] and receive an error.

    Also, if you try have 2 keyframes that are the same in a row, the second one restarts the animation back to 0-100 even though the value was already 100.

    For this puppet rig I’m working on I don’t think it will cause any problems, but if anyone knows an easy solution for these problems I’m all ears.

    sc = effect("123")("Slider");
    sTime =.1;
    sStart = 0;
    sEnd = 100;
    v=0;
    oldv=0;
    if (sc.numKeys > 0){
    n = sc.nearestKey(time).index;
    oldv=n;
    if (sc.key(n).time > time) {
    n--;
    }
    if (n > 0){
    t = time -sc.key(n).time;
    if (sc.value==10){
    v = linear(t,0,sTime,sStart,sEnd);
    }else{
    if(sc.key(sc.nearestKey(time).index-1)==10){
    v = linear(t,0,sTime,sEnd,sStart);
    }

    }
    v;
    }else{
    value;
    }
    }else{
    value;
    }

  • Adam Fuller

    February 27, 2014 at 4:51 pm in reply to: Animating a slider control with a checkbox

    Thanks Dan, that worked for the checkbox, I actually found something similar last night that you posted to another thread about scaling with a checkbox.

    Basically what I’m trying to set up is “Blendshapes” like you would see in a 3d program like maya. I have a mouth puppet rig set up and am trying to make it simple for lip sync later on.

    As I kept building the rig I realized I needed to have multiple sliders to trigger at different times, from one set of keyframes. So I’ve changed the checkbox control for a different slider that’s using hold keyframes, I’ve posted the modified script below.

    So on keyframe.value 10, the first slider fires and moves from 0-100, but all the other sliders do their 100-0 animation. Any keyframe that isn’t the correct trigger for that slider makes it do it’s second animation.

    So now I’m trying to find a way to only have them animate 100-0, if they were either already at 100, or if the previous keyframe was their trigger.

    Any ideas?

    sc = effect("123")("Slider");
    sTime = 1;
    sStart = 0;
    sEnd = 100;
    v=0;

    if (sc.numKeys > 0){
    n = sc.nearestKey(time).index;
    if (sc.key(n).time > time) {
    n--;
    }
    if (n > 0){
    t = time -sc.key(n).time;
    if (sc.value==10){
    v = linear(t,0,sTime,sStart,sEnd);
    }else{
    //if(oldv==10){
    v = linear(t,0,sTime,sEnd,sStart);
    //}

    }
    v;
    }else{
    value;
    }
    }else{
    value;
    }

  • Adam Fuller

    March 25, 2010 at 7:20 am in reply to: hvx 200 remote lens control

    So I have the varizoom rock pzfi, which uses the connections you mentioned. I’m trying to use it with a homemade focus follow system.

    I simply need to tap into the correct leads off the line for the focus pot. C B D, is what I’m thinking leads to the focus pot, but it’s not working correctly. Is there something about how the remote is wired that will not allow me to gain access to one pot from three wires off the 4-pole plug?

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy