AnimationController constructor

AnimationController({
  1. double? value,
  2. Duration? duration,
  3. Duration? reverseDuration,
  4. double lowerBound = 0.0,
  5. double upperBound = 1.0,
  6. int fps = 30,
  7. Object? id,
})

Creates an animation controller.

  • value: initial value. Defaults to lowerBound.
  • duration: the length of this animation when going forward.
  • reverseDuration: the length of this animation when going in reverse. Defaults to duration when null.
  • lowerBound / upperBound: the range of values this animation spans.
  • fps: target frame rate for animation ticks. Higher values produce smoother animation at the cost of more TEA messages.
  • id: an identity object used to match AnimationTickMsgs to this controller. Auto-generated if not provided.

Implementation

AnimationController({
  double? value,
  this.duration,
  this.reverseDuration,
  this.lowerBound = 0.0,
  this.upperBound = 1.0,
  this.fps = 30,
  Object? id,
}) : _id = id ?? Object() {
  _value = value ?? lowerBound;
  _status = AnimationStatus.dismissed;
}