# interpolate_brush

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-livecharts/paint/function-interpolate_brush/

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

```rust
fn interpolate_brush(from: &std::rc::Rc<dyn IBrush>, to: &std::rc::Rc<dyn IBrush>, progress: f64) -> Option<std::rc::Rc<dyn IBrush>>
```

Interpolates native paint values with the source encoded-channel arithmetic.
A different gradient stop count snaps that property to its target while
compatible spatial properties continue moving. Unsupported kind changes
return `None`, allowing the scene host to crossfade the two primitives.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.LiveCharts/paint.rs#L232)

## Availability

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