This commit is contained in:
2026-07-11 00:14:41 +02:00
parent 87dd8e1190
commit c9e463bb9a
15 changed files with 183 additions and 51 deletions
+2
View File
@@ -21,6 +21,7 @@ impl Mat4 {
[0.0, 0.0, 0.0, 1.0],
]);
#[allow(clippy::needless_range_loop)] // Zeilen-/Spalten-Index ist bei 4×4-Mathematik klarer als Iteratoren
pub fn mul(&self, rhs: &Mat4) -> Mat4 {
let mut out = [[0.0f32; 4]; 4];
for c in 0..4 {
@@ -34,6 +35,7 @@ impl Mat4 {
/// Punkt-Transformation auf der CPU — bisher nur von den Tests
/// gebraucht; der Renderer transformiert auf der GPU.
#[cfg(test)]
#[allow(clippy::needless_range_loop)] // Zeilen-Index ist bei der Matrix-Vektor-Mathematik klarer
pub fn transform(&self, v: [f32; 4]) -> [f32; 4] {
let mut out = [0.0f32; 4];
for r in 0..4 {