Animation
animateTo():
circleNode.animateTo({
duration: 500,
loop: Infinity,
ease: 'easeInOutSin',
direction: 'alternate',
attr: {
r: 200
},
style: {
fillStyle: '#00ff00'
}
});circleNode.animateTo({
duration: 500,
loop: Infinity,
ease: 'easeInOutSin',
direction: 'alternate',
attr: {
r: 200
},
style: {
fillStyle: '#00ff00'
}
}); circle.animateTo({
duration : 1000,
ease : 'easeInOutSin',
loop : 10,
direction : 'alternate'
attr : {
r: 100
},
style : {
opacity: 0
},
end: function(){
this.remove();
}
})#.createEl({
el: 'path',
attr: {
d: 'M366.2,204.2 c-9.8,0 -15,-5.6 -15,-15.1 V77.2 h-85 v28 h19.5 c9.8,0 8.5,2.1 8.5,11.6 v72.4 c0,9.5 0.5,15.1 -9.3,15.1 H277 h-20.7 c-8.5,0 -14.2,-4.1 -14.2,-12.9 V52.4 c0,-8.5 5.7,-12.3 14.2,-12.3 h18.8 v-28 h-127 v28 h18.1 c8.5,0 9.9,2.1 9.9,8.9 v56.1 h-75 V53.4 c0,-11.5 8.6,-13.3 17,-13.3 h11 v-28 H2.2 v28 h26 c8.5,0 12,2.1 12,7.9 v142.2 c0,8.5 -3.6,13.9 -12,13.9 h-21 v33 h122 v-33 h-11 c-8.5,0 -17,-4.1 -17,-12.2 v-57.8 h75 v58.4 c0,9.1 -1.4,11.6 -9.9,11.6 h-18.1 v33 h122.9 h5.9 h102.2 v-33 H366.2 z'
},
style: {
lineWidth: 10,
strokeStyle: '#f00000',
shadowColor: 'black',
lineCap: 'round'
}
})
.animatePathTo({
duration: 10000,
loop: 10,
ease: 'linear',
direction: 'alternate'
});renderer.createEl({
el: 'path',
attr: {
d: 'M100,250 C100,100 400,100 400,250 z'
},
style: {
lineWidth: '3',
strokeStyle: '#f00000'
},
bbox: false
})
.animateTo({
duration: 1000,
loop: 100,
direction: 'alternate',
// loop:100,
attr: {
d: 'M100,250 C500,66 -1,48 400,250'
}
});