# InterpolatingTransitionBase

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-base/animation/trait-interpolatingtransitionbase/

**trait** · [`ferroui-base`](/docs/0.5.0/api/ferroui-base/) · v0.5.0

```rust
trait InterpolatingTransitionBase<T: PropertyValue>: Transition<T>
```

The base for user-defined transitions that are fully described by an
interpolation function.

Declare the class with
`ferro_transition_class!`, implement
this trait and implement `Transition::do_transition` by calling
[`interpolating_do_transition`](/docs/0.5.0/api/ferroui-base/animation/function-interpolating_do_transition/).

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/animation/interpolating_transition_base.rs#L13)

## Members

- [`interpolate`](#function-interpolate)

<a id="function-interpolate"></a>

### interpolate

```rust
fn interpolate(this: &Self, progress: f64, from: &T, to: &T) -> T
```

Interpolates between two values using the specified progress.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/animation/interpolating_transition_base.rs#L15)

## Availability

Extracted for `aarch64-apple-darwin`. Cargo features are listed in the [crate index](/docs/0.5.0/api/).
