Skip to content

Commit

Permalink
Fix matrices
Browse files Browse the repository at this point in the history
  • Loading branch information
REDxEYE committed Mar 24, 2024
1 parent 28c76d8 commit 3bd822d
Showing 1 changed file with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ protected static Matrix4d worldTransformToMatrix(@NotNull RTTIObject transform)
final var col1 = ori.obj("Col1");
final var col2 = ori.obj("Col2");
return new Matrix4d(
col0.f32("X"), col1.f32("X"), col2.f32("X"), 0,
col0.f32("Y"), col1.f32("Y"), col2.f32("Y"), 0,
col0.f32("Z"), col1.f32("Z"), col2.f32("Z"), 0,
col0.f32("X"), col0.f32("Y"), col0.f32("Z"), 0,
col1.f32("X"), col1.f32("Y"), col1.f32("Z"), 0,
col2.f32("X"), col2.f32("Y"), col2.f32("Z"), 0,
pos.f64("X"), pos.f64("Y"), pos.f64("Z"), 1
);
}
Expand All @@ -37,10 +37,10 @@ protected static Matrix4d mat34ToMatrix(@NotNull RTTIObject object) {
final RTTIObject row2 = object.obj("Row2");

return new Matrix4d(
row0.f32("X"), row0.f32("Y"), row0.f32("Z"), row0.f32("W"),
row1.f32("X"), row1.f32("Y"), row1.f32("Z"), row1.f32("W"),
row2.f32("X"), row2.f32("Y"), row2.f32("Z"), row2.f32("W"),
0.0, 0.0, 0.0, 1.0
row0.f32("X"), row1.f32("X"), row2.f32("X"), 0.0f,
row0.f32("Y"), row1.f32("Y"), row2.f32("Y"), 0.0f,
row0.f32("Z"), row1.f32("Z"), row2.f32("Z"), 0.0f,
row0.f32("W"), row1.f32("W"), row2.f32("W"), 1.0f
);
}

Expand Down

0 comments on commit 3bd822d

Please sign in to comment.