pub trait WindowedDrawTarget: DrawTarget {
// Required method
fn set_window(&mut self, area: &Rectangle) -> Result<(), Self::Error>;
}Expand description
Capability trait for hardware display controllers (e.g. ST7789, ILI9341, SSD1306)
supporting direct column/row address window setting (set_address_window).
Allows rendering dirty regions by transmitting SPI/DMA transfers exclusively to
the target sub-window instead of the full screen.
Re-exported from embedded_draw_target.
Partial-present capability for a DrawTarget.
Display controllers with a column/row address window (SSD1357, ST7789, ILI9341, …) can accept a sub-rectangle of pixels and leave the rest of the panel untouched. On a slow bus that is the difference between pushing a whole frame and pushing the handful of rows that actually changed.
Implementors set the controller’s address window; the subsequent pixel
writes are expected to fill area in row-major order.
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".