Skip to content

Commit

Permalink
Add fn encoding_mut() to Scene. (#701)
Browse files Browse the repository at this point in the history
This is a useful escape hatch to implement things not supported by the
standard API.

---------

Co-authored-by: Daniel McNab <[email protected]>
  • Loading branch information
timtom-dev and DJMcNab authored Sep 26, 2024
1 parent 0850de8 commit ddcfcba
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions vello/src/scene.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,13 @@ impl Scene {
&self.encoding
}

/// Returns a mutable reference to the underlying raw encoding.
///
/// This can be used to more easily create invalid scenes, and so should be used with care.
pub fn encoding_mut(&mut self) -> &mut Encoding {
&mut self.encoding
}

/// Pushes a new layer clipped by the specified shape and composed with
/// previous layers using the specified blend mode.
///
Expand Down

0 comments on commit ddcfcba

Please sign in to comment.