Show
General practice, can only display two pictures, because wipe scrub technology limit only two pictures between the switch flower. But you can turn two pictures to animate alternately
<script>
var i=0,pictures=new array (),//Set picture array, number of pictures is odd
var picbase= "";
pictures[i++]= "1.gif"
pictures[i++]= "2.gif"
pictures[i++]= "3.gif"
pictures[i++]= "4.gif"
pictures[i++]= "5.gif"
pictures[i++]= "6.gif"
pictures[i++]= "7.gif"
pictures[i++]= "8.gif"
pictures[i++]= "9.gif"
pictures[i++]= "10.gif"
pictures[i++]= "11.gif"
pictures[i++]= "12.gif"
pictures[i++]= "13.gif"
pictures[i++]= "14.gif"
pictures[i++]= "15.gif"
pictures[i++]= "16.gif"
pictures[i++]= "17.gif"
pictures[i++]= "18.gif"
pictures[i++]= "19.gif"
pictures[i++]= "20.gif"
pictures[i++]= "21.gif"
pictures[i++]= "22.gif"
var picturewidth=400//picture width
var pictureheight=290//picture Height
var delay=1//delay Time
</script>
<script>
if (document.all) {
document.write (' <object id= ' dacontrol_wipe ')
document.write (' style= ' width: ' +picturewidth+ '; height: ' +pictureheight+ ')
document.write (' classid= "clsid:b6ffc24c-7e13-11d0-9b47-00c04fc2f51d" > ")
document.write (' </OBJECT> ')
m = dacontrol_wipe.meterlibrary;
Whattransformation = new ActiveXObject ("DXImageTransform.Microsoft.Wipe");
Whattransformation.gradientsize = 1.0;//Set Gradient degree
Whattransformation.wipestyle = 0;//Set Scrub type
var myarr=new array (), myarr2=new Array ();
var len=math.floor (PICTURES.LENGTH/2);//Divide the picture into two groups
for (Var i=0;i<len;i++) {
Myarr[i]=m.importimage (Picbase+pictures[2*i])
Myarr2[i]=m.importimage (Picbase+pictures[2*i+1])
}
if (Pictures[2*i])
Myarr[i]=m.importimage (Picbase+pictures[2*i])
Else
Myarr[i]=m.importimage (Picbase+pictures[0]);
Myarr=m.array (Myarr)
Myarr2=m.array (MYARR2)
Index = M.interpolate (0.5,len+0.5,len*2*delay). RepeatForever ();
Index2 = M.interpolate (0,len,len*2*delay). RepeatForever ();
Staggered run half time unit
var whatpictures=new Array ();
Whatpictures[0] = Myarr.nthanim (Index);
WHATPICTURES[1] = Myarr2.nthanim (INDEX2);
Forward = m.interpolate (0, 1, delay);
back = m.interpolate (1, 0, delay);
Whatmovement = M.sequence (Forward, back). RepeatForever ();
Set parameter orientation
Theresult = M.applydxtransform (whattransformation, Whatpictures, whatmovement);
Dacontrol_wipe.image = theresult.outputbvr;//Set Display graphic
Dacontrol_wipe.start ()/Start
}
</script>
The techniques used differ from the previous ones mainly in alternating the images into two arrays, using internal counting interpolate and Nthanim techniques to achieve animation.