mirror of
https://github.com/italicsjenga/vello.git
synced 2025-01-08 20:01:30 +11:00
fix some clippy errors/warnings
This commit is contained in:
parent
e9278a9253
commit
2b0eab2bbc
|
@ -81,8 +81,8 @@ impl RenderConfig {
|
|||
let height_in_tiles = new_height / TILE_HEIGHT;
|
||||
let n_path_tags = layout.path_tags_size();
|
||||
let workgroup_counts =
|
||||
WorkgroupCounts::new(&layout, width_in_tiles, height_in_tiles, n_path_tags);
|
||||
let buffer_sizes = BufferSizes::new(&layout, &workgroup_counts, n_path_tags);
|
||||
WorkgroupCounts::new(layout, width_in_tiles, height_in_tiles, n_path_tags);
|
||||
let buffer_sizes = BufferSizes::new(layout, &workgroup_counts, n_path_tags);
|
||||
Self {
|
||||
gpu: ConfigUniform {
|
||||
width_in_tiles,
|
||||
|
@ -175,7 +175,7 @@ impl WorkgroupCounts {
|
|||
}
|
||||
|
||||
/// Typed buffer size primitive.
|
||||
#[derive(Copy, Clone, Eq, Ord, Default, Debug)]
|
||||
#[derive(Copy, Clone, Eq, Default, Debug)]
|
||||
pub struct BufferSize<T: Sized> {
|
||||
len: u32,
|
||||
_phantom: std::marker::PhantomData<T>,
|
||||
|
|
|
@ -129,9 +129,11 @@ impl Resolver {
|
|||
self.resolve_pending_images();
|
||||
let data = packed;
|
||||
data.clear();
|
||||
let mut layout = Layout::default();
|
||||
layout.n_paths = encoding.n_paths;
|
||||
layout.n_clips = encoding.n_clips;
|
||||
let mut layout = Layout {
|
||||
n_paths: encoding.n_paths,
|
||||
n_clips: encoding.n_clips,
|
||||
..Layout::default()
|
||||
};
|
||||
// Compute size of data buffer
|
||||
let n_path_tags =
|
||||
encoding.path_tags.len() + sizes.path_tags + encoding.n_open_clips as usize;
|
||||
|
|
|
@ -330,7 +330,7 @@ impl Engine {
|
|||
let format = proxy.format.to_wgpu();
|
||||
queue.write_texture(
|
||||
wgpu::ImageCopyTexture {
|
||||
texture: &texture,
|
||||
texture,
|
||||
mip_level: 0,
|
||||
origin: wgpu::Origin3d { x: *x, y: *y, z: 0 },
|
||||
aspect: TextureAspect::All,
|
||||
|
|
|
@ -136,7 +136,7 @@ impl Renderer {
|
|||
if target.width != width || target.height != height {
|
||||
target = TargetTexture::new(device, width, height);
|
||||
}
|
||||
self.render_to_texture(device, queue, scene, &target.view, ¶ms)?;
|
||||
self.render_to_texture(device, queue, scene, &target.view, params)?;
|
||||
let blit = self
|
||||
.blit
|
||||
.as_ref()
|
||||
|
|
Loading…
Reference in a new issue