Enum PdfRichMediaAnimationStyle
- Namespace
- BitMiracle.Docotic.Pdf
- Assembly
- BitMiracle.Docotic.Pdf.dll
Specifies how to apply timeline scaling to keyframe animations.
public enum PdfRichMediaAnimationStyle
Fields
Linear = 1
Drives keyframe animations linearly from beginning to end. This animation style results in a repetitive playthrough of the animation, such as in a walking motion.
None = 0
Disables keyframe animations. This value is useful for documents that are intended to drive animations through an alternate means, such as JavaScript.
Oscillating = 2
Drives keyframe animations oscillating along their time range. This animation style results in a back-and-forth playing of the animation, such as exploding or collapsing parts.
Remarks
Linear animations are defined by the following formulas:
t = (m * (ta - t0) + r0) % (r1 - r0)
p = (r1 - r0) / m
Oscillating animations are defined by the following formulas:
t = 0.5 * (r1 - r0) * (1 - cos(m * (ta - t0))) + r0
p = 2 * pi / m
The formulas above use the following variables:
-
t
is a point on the animation time line. This value shall be used in conjunction with the keyframe animation data to determine the state of the artwork. -
[r0, r1]
is the keyframe animation time line. -
m
is the positive multiplier specified by the Speed property. -
ta
is the current time of the PDF viewer. -
t0
is the time when the PDF viewer starts the animation. -
p
is the time it takes to play the keyframe animation through one cycle. In the case of the Linear animation style, one cycle consists of playing the animation through once from beginning to end.