fmt: ran clippy

This commit is contained in:
2026-05-13 13:27:37 +02:00
parent 194328d92f
commit d4f4b6a715
8 changed files with 14 additions and 14 deletions

View File

@@ -36,7 +36,7 @@ impl Texture {
width: img.width(),
height: img.height(),
source: img,
stride: stride,
stride,
}
}
@@ -51,7 +51,7 @@ impl Texture {
let b = self.source.as_bytes();
let idx = self._idx(u, v);
Vec3::from_u8(b[self.stride * idx + 0], b[self.stride * idx + 2], b[self.stride * idx + 1])
Vec3::from_u8(b[self.stride * idx], b[self.stride * idx + 2], b[self.stride * idx + 1])
}
}
@@ -59,6 +59,6 @@ impl Material for Texture {
fn scatter(&self, hit: &Hit, _ray: &Ray) -> Option<(Option<Ray>, Vec3)> {
let (u, v) = hit.uv();
let col = self._at(u, 1. - v);
return Some((None, col));
Some((None, col))
}
}