Merge pull request #479 from i509VCB/docs/render_at

renderer: describe at parameter in Frame::clear
This commit is contained in:
Victoria Brekenfeld 2022-01-22 22:18:38 +01:00 committed by GitHub
commit bdf3a50b63
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -122,6 +122,9 @@ pub trait Frame {
/// Clear the complete current target with a single given color.
///
/// The `at` parameter specifies a set of rectangles to clear in the current target. This allows partially
/// clearing the target which may be useful for damaged rendering.
///
/// This operation is only valid in between a `begin` and `finish`-call.
/// If called outside this operation may error-out, do nothing or modify future rendering results in any way.
fn clear(&mut self, color: [f32; 4], at: &[Rectangle<i32, Physical>]) -> Result<(), Self::Error>;