Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

get_final_transform() does not return the complete transform of a Window #66690

Closed
Sauermann opened this issue Oct 1, 2022 · 0 comments · Fixed by #66692
Closed

get_final_transform() does not return the complete transform of a Window #66690

Sauermann opened this issue Oct 1, 2022 · 0 comments · Fixed by #66692

Comments

@Sauermann
Copy link
Contributor

Sauermann commented Oct 1, 2022

Godot version

v4.0.beta.custom_build [e69b708]

System information

Linux

Issue description

According to the documentation of Viewport::get_final_transform it should: "Returns the total transform of the viewport."
When used on a window, this function does not contain all transforms of a window, so users can not convert between the coordinate system of the window's embedder and the coordinate system of the window's viewport (#30950 (comment)).

The following picture shows the MRP:

image

Displaying the final transform of the three windows (from left to right) results in:

Window [X: (1, 0), Y: (0, 1), O: (0, 0)]
Window2 [X: (2, 0), Y: (0, 2), O: (0, 0)]
Window3 [X: (1, 0), Y: (0, 1), O: (0, 0)]

The problem becomes apparent for Window2, which misses the vertical translation for the upper black bar.

Steps to reproduce

Load and run MRP

Minimal reproduction project

BugWindowFinalTransform.zip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants