-
Controlloing a camera with markers
//Abbreviation for last layer m = thisComp.layer(thisComp.numLayers).marker; //Variables for time t0 = m.key("0").time; t1 = m.key("1").time; t2 = m.key("2").time; t3 = m.key("3").time; //Positions p0=[360,288,-833] //Initial position p1=[75,288,-641] //First position p1_2=[75,288,-501] // First subposition, to mantain camera on move p2=[340,400,-641] p2_2=[360,308,-550] p3=[653,288,-641] p3_2=[653,288,-500] //Conditionals if (time <= t0) {linear (time , 0 , t0 , p0 , p1 ) } else { if ((time >t0) && (time <= t1-0.2)) { linear (time , t0 , t1-0.2 , p1 , p1_2 ) } else { if ((time >t1-0.2) && (time <= t1+0.2)) { linear (time , t1-0.2 , t1+0.2 , p1_2 , p2 ) } else { if ((time >t1+0.2) && (time <= t2-0.2)) { linear (time , t1+0.2 , t2-0.2 , p2 , p2_2 ) } else { if ((time >t2-0.2) && (time <= t2+0.2)) { linear (time , t2-0.2 , t2+0.2 , p2_2 , p3 ) } else { { linear (time , t2+0.2 , t3, p3 , p3_2 ) } } } } } }Hi, I have four markers in my last layer that set time for camera´s position. I made it with conditionals but I want to know if there is a smarter solution.
Thank you!
Sorry, there were no replies found.