Animate Object script

Use Animate Object script to create movies with an object changing its position and/or appearance from frame to frame. The object can be repositioned, stretched and rotated when moving from one movie frame to another.

To specify the variation of distortion parameters you can use arithmetic expressions using the following components:

Numeric constants
Any number like 2, 6.9, -76.67. You can also use PI for 3.1415926..., E for 2.7182818..., W for the width of the current frame, and H for the height of the current frame
One of the following operators:
+ (addition), - (subtraction), * (multiplication), / (division), ^ (power)
Parameter
Use N keyword to represent the current movie frame being processed (relatively to the first frame selected, starting from 0. So if you selected the 3rd frame of the movie and started the script, N will be 0 for 3rd frame, 1 for 4th, 2 for 5th, and so on).
Functions
One of the following functions:
SIN - Sine
COS - Cosine
TAN - Tangent
SQR - Square root
LOG - base-10 logarithm
LN - natural logarithm
EXP - exponent (e raised to the given power)
Parentheses
Use parentheses to control function evaluation order

For example, 5*N will evaluate to 0 for the first frame, 5 for the second, 10 for the third and so on.

Screenshot of the Animate Object script main dialog:

animateobjectsh.gif (7517 bytes)

Below there are some of examples:

Transformation Resulting movie
X: 0
Y: 0
H Scale: 75+25*SIN(PI*N/5)
V Scale: 75-25*SIN(PI*N/5)
Angle: 0
Opacity: 100
Frames: 10
object1.gif (2352 bytes)
X: (W/2-50)*SIN(PI*N/5)
Y: (H/2-50)*COS(PI*N/5)
H Scale: 100-35*(1-COS(PI*N/5))
V Scale: 100-35*(1-COS(PI*N/5))
Angle: 0
Opacity: 100
Frames: 10
object2.gif (7221 bytes)
X: W*N/10-W/2
Y: 0
H Scale: 100
V Scale: 100
Angle: -W*N*360/PI/1000
Opacity: 100
Frames: 10
object3.gif (11635 bytes)

Download Animate Object script for CorelPHOTO-PAINT 8:

Photo-Paint 9 version of this script is available here.


[ CorelPHOTO-PAINT Scripts | CorelDRAW Users' Page | DTP & Graphics | Oberon Home Page ]
Copyright 2000 by Alex Vakulenko. All rights reserved.
This page was last revised on 11/25/02.