function createAnimation() {
var startRotation = new dali.Rotation(180, -180, 0);
- myActor1.rotation = startRotation;
- myActor2.rotation = startRotation;
+ myActor1.orientation = startRotation;
+ myActor2.orientation = startRotation;
dali.stage.add( myActor1 );
dali.stage.add( myActor2 );
var endRotation = new dali.Rotation(0,0,0);
animOptions.alpha = "easeInOutSine";
- anim.animateTo(myActor1, "rotation", endRotation, animOptions);
+ anim.animateTo(myActor1, "orientation", endRotation, animOptions);
// Delay the myActor2 by a second
animOptions.delay = 0.0;
// rotate back to correct orientation
animOptions.alpha = "easeInOutSine";
- anim.animateTo(myActor2, "rotation", endRotation, animOptions);
+ anim.animateTo(myActor2, "orientation", endRotation, animOptions);
return anim;
}
- rotates the image actor
- magnifies and color shifts the image using a fragment shader
-<img src="../assets/img/shader-animation.png">
+![ ](../assets/img/shaders/shader-animation.png)
+
```
// also rotate the imageActor 90 degrees at the same time.
var rotation = new dali.Rotation(90,0,0,1);
-shaderAnim.animateTo(imageActor, "rotation", rotation, { alpha:"linear", duration:duration, delay:delay });
+shaderAnim.animateTo(imageActor, "orientation", rotation, { alpha:"linear", duration:duration, delay:delay });
shaderAnim.play();