A linear interpolation between a beginning and ending value.
Tween is useful if you want to interpolate across a range.
You can chain Tween objects together using the chain method, so that a single Animation object is configured by multiple Tween objects called in succession. This is different than calling the animate method twice, which results in two Animation separate objects, each configured with a single Tween.
Animation<Offset> _animation = new Tween<Offset>( begin: const Offset(100.0, 50.0), end: const Offset(200.0, 300.0), ).animate(_controller);
That would provide an
_animation that, over the lifetime of the
_controller's animation, returns a value that depicts a point along the
line between the two offsets above. If we used a MaterialPointArcTween
instead of a Tween
- Implemented by
- begin ↔ T
The value this variable has at the beginning of the animation. [...]
read / write
- end ↔ T
The value this variable has at the end of the animation. [...]
read / write
- hashCode → int
The hash code for this object. [...]
- runtimeType → Type
A representation of the runtime type of the object.
Animation<double> animation) → T
- Returns the interpolated value for the current value of the given animation. [...]
double t) → T
- Returns the value this variable has at the given animation clock value. [...]
) → String
- Returns a string representation of this object.
Animation<double> parent) → Animation<T>
Returns a new Animation that is driven by the given animation but that
takes on values determined by this object.
Animatable<double> parent) → Animatable<T>
Returns a new Animatable whose value is determined by first evaluating
the given parent and then evaluating this object.
Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]