diff --git a/README.md b/README.md index 6cb5b1d..274866b 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ -# vello (formerly piet-gpu) +# vello -This repo contains the new prototype for a new compute-centric 2D GPU renderer. +This repo contains the new prototype for a new compute-centric 2D GPU renderer (formerly known as piet-gpu). It succeeds the previous prototype, [piet-metal]. diff --git a/vello/src/scene.rs b/vello/src/scene.rs index 6ec2fb5..06201f6 100644 --- a/vello/src/scene.rs +++ b/vello/src/scene.rs @@ -620,26 +620,11 @@ impl<'a> PathBuilder<'a> { } fn affine_to_f32(affine: &Affine) -> [f32; 6] { - let c = affine.as_coeffs(); - [ - c[0] as f32, - c[1] as f32, - c[2] as f32, - c[3] as f32, - c[4] as f32, - c[5] as f32, - ] + affine.as_coeffs().map(|value| value as f32) } fn affine_from_f32(coeffs: &[f32; 6]) -> Affine { - Affine::new([ - coeffs[0] as f64, - coeffs[1] as f64, - coeffs[2] as f64, - coeffs[3] as f64, - coeffs[4] as f64, - coeffs[5] as f64, - ]) + Affine::new(coeffs.map(|value| value as f64)) } fn point_to_f32(point: Point) -> [f32; 2] {