Skip to content

Fix Projection values being displayed transposed in the inspector#110526

Open
aaronfranke wants to merge 1 commit intogodotengine:masterfrom
aaronfranke:fix-proj-insp-transpose
Open

Fix Projection values being displayed transposed in the inspector#110526
aaronfranke wants to merge 1 commit intogodotengine:masterfrom
aaronfranke:fix-proj-insp-transpose

Conversation

@aaronfranke
Copy link
Copy Markdown
Member

In Godot's internal C++ code, the [] operator on Basis (3D) uses rows, but the [] operator on Projection uses columns. The inspector code in master was using the same numbers for Projection as it did for Basis, which resulted in the values being displayed as transposed. This PR fixes it by swapping the numbers, and I also threw in a change to preserve the unit just like it already does in Basis (3D) though this is different from Transform3D.

In 3D, the Basis inspector works correctly, as shown in this video:

2025-09-14.23-41-47.mp4

The Projection inspector is transposed in master, as shown in this video of it affecting the wrong 4D basis vector:

2025-09-14.23-45-00.mp4

Simply put: the green-labeled values are supposed to move the green arrow, but the red arrow moved instead.

This PR fixes the issue, as shown in this video:

2025-09-14.23-42-29.mp4

This is purely a fix to the editor inspectors, there is no change to anywhere else.

@aaronfranke aaronfranke added this to the 4.6 milestone Sep 15, 2025
@aaronfranke aaronfranke requested a review from a team September 15, 2025 06:56
@aaronfranke aaronfranke added bug topic:editor cherrypick:4.3 Considered for cherry-picking into a future 4.3.x release cherrypick:4.4 Considered for cherry-picking into a future 4.4.x release cherrypick:4.5 Considered for cherry-picking into a future 4.5.x release labels Sep 15, 2025
@beicause
Copy link
Copy Markdown
Contributor

@aaronfranke
Copy link
Copy Markdown
Member Author

@beicause Ah, good catch! This PR is a subset of PR #109222 so we can merge this fix first and debate the labels later.

@Mickeon
Copy link
Copy Markdown
Member

Mickeon commented Sep 15, 2025

Albeit very niche, this may affect the muscle memory of some users, that's worth keeping in mind.

@aaronfranke aaronfranke force-pushed the fix-proj-insp-transpose branch from 792b618 to e2ad428 Compare October 14, 2025 01:36
@aaronfranke aaronfranke modified the milestones: 4.6, 4.7 Dec 7, 2025
@aaronfranke aaronfranke force-pushed the fix-proj-insp-transpose branch from e2ad428 to 650b691 Compare December 7, 2025 06:21
@aaronfranke aaronfranke force-pushed the fix-proj-insp-transpose branch from 650b691 to fdc4e94 Compare January 10, 2026 18:39
@aaronfranke aaronfranke force-pushed the fix-proj-insp-transpose branch from fdc4e94 to 8e9464a Compare February 13, 2026 18:20
@aaronfranke aaronfranke requested a review from a team as a code owner February 13, 2026 18:20
@aaronfranke aaronfranke force-pushed the fix-proj-insp-transpose branch from 8e9464a to 8261fa0 Compare March 5, 2026 07:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug cherrypick:4.3 Considered for cherry-picking into a future 4.3.x release cherrypick:4.4 Considered for cherry-picking into a future 4.4.x release cherrypick:4.5 Considered for cherry-picking into a future 4.5.x release topic:editor

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants