subtype idKGScriptParserduration?ð framebaseencodingparms inputFormat inputCountpublic angleofpushtitle directionuitypeuiinfolabelsl to rr to Lupdowntypemin?€max@€default?€value?€ motion_blur motion blur blurlength blur lengthCúAðAðrampB–easeinease inÀ@??qualityquality?€BÈAA%B´privatestaticsscript//--------------------------------// // Stib's better push 2.0 // //for more visit www.fxscript.org // //--------------------------------// //copyright 2005 stephen dixon //This software is free - you may use, modify and distribute it as you wish, with the following provisos: //*it may not be used by any military organisation, or to produce goods or services for any military organisation. //* this source code must remain open //* this message and the accompanying doccumentation files must remain with the source //additionally this software is released under the terms of the GNU general Public license //see http://www.gnu.org/licenses/gpl.html for the full text of this license or look at the readme that came with the plugins //this software comes with no warranty of fitness for any purpose whatsoever, ok. //adapted from the Apple Push transition scriptid "stib's push2.01" transition "stib's push 2.01"; group "stib's transitions"; wipeCode(1, 69); producesAlpha; input AngleofPush, "direction", Popup, 1,"l to r", "r to L", "up", "down" input Motion_Blur, "motion blur", CheckBox, true input blurLength, "blur length", Slider, 30, 0, 500 ramp 75 //--------------Ease In control --------------- input EaseIn, "ease in", Slider, 0.5, -2, 2 input quality, "quality", Slider, 8, 1, 100 ramp 90 code //-------------stib's ease in ease out------------------- float e, magicnumber, newRatio,Acceleration; magicnumber = 8; e = 2.71828; //just defining a basic constant newRatio = EaseIn*(1-2/(1+power(e,magicnumber*power(ratio,e))))+(1-EaseIn)*ratio Acceleration = ((16*EaseIn*power(ratio, e-1)*power(e,8*power(ratio,e)+1))/power((power(e,8*power(ratio,e))+1),2))-EaseIn //acceleration is the derivative of the ease in function, ie it is the change of speed Acceleration += 0.5 //we want some blurring even if the acceleration is constant if srcIsGap1 newRatio =0.5 + newRatio / 2 else if srcIsGap2 newRatio /=2 end if; //----------------------------------------------------- point srcRect1[4], srcRect2[4], srcRect3[4], targetRect[4]; float i, width, height; DimensionsOf(dest, width, height) if (AngleofPush < 3) //horizontal push image buf1[width*2][height]; image buf2[width*2][height]; else image buf1[width][height*2]; image buf2[width][height*2]; end if channelfill(dest, 0, 0, 0, 0); channelfill(buf1, 0, 0, 0, 0); boundsof(dest, targetRect) boundsof(src1, srcRect1) boundsof(src2, srcRect2) //set up our buffers - with the sources next to each other if (AngleofPush == 1) //horizontal push, L to R Offset(targetRect, srcRect1[0].X,0) //put our first frame on the right blitRect(src2, srcRect1, buf1, targetRect) Offset(targetRect, srcRect2[2].X - srcRect1[0].X,0) blitRect(src1, srcRect2, buf1, targetRect) if Motion_Blur Blur(buf1, buf2, Acceleration*blurLength, 1000) else buf2 = buf1 end if else if (AngleofPush == 2) //horizontal push, r to L Offset(targetRect, srcRect1[0].X,0) //put our first frame on the right blitRect(src1, srcRect1, buf1, targetRect) Offset(targetRect, srcRect2[2].X - srcRect1[0].X,0) blitRect(src2, srcRect2, buf1, targetRect) if Motion_Blur Blur(buf1, buf2, Acceleration*blurLength, 1000) else buf2 = buf1 end if else if (AngleofPush == 3) //vertical push, up Offset(targetRect, 0, srcRect1[0].Y) blitRect(src1, srcRect1, buf1, targetRect) Offset(targetRect, 0, srcRect2[2].Y-srcRect1[0].Y) blitRect(src2, srcRect2, buf1, targetRect) if Motion_Blur Blur(buf1, buf2, Acceleration*blurLength/100, 0.01)//it blurs more vertically than horizontally ..? else buf2 = buf1 end if else Offset(targetRect, 0, srcRect1[0].Y) blitRect(src2, srcRect1, buf1, targetRect) Offset(targetRect, 0, srcRect2[2].Y-srcRect1[0].Y) blitRect(src1, srcRect2, buf1, targetRect) if Motion_Blur Blur(buf1, buf2, Acceleration*blurLength/100, 0.01) else buf2 = buf1 end if end if; boundsof(dest, targetRect) boundsof(dest, srcRect3) if (AngleofPush == 1) Offset(srcRect3, newRatio*srcRect1[0].X + (1-NewRatio)*srcRect2[2].X,0) else if (AngleofPush == 2) Offset(srcRect3, (1-NewRatio)*srcRect2[0].X + newRatio*srcRect1[2].X, 0) else if (AngleofPush == 3) Offset(srcRect3, 0, newRatio*srcRect1[2].Y + (1-NewRatio)*srcRect2[0].Y) else if (AngleofPush == 4) Offset(srcRect3, 0, (1-NewRatio)*srcRect2[2].Y + newRatio*srcRect1[0].Y) end if blitRect(buf2, srcRect3, dest, targetRect);scriptidstib's push2.01namestib's push 2.01groupstib's transitionswipecode wipeaccuracyE producesalphaencoded