-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[gltf] Support camera and fix hierarchy #772
Conversation
da044d7
to
ef79809
Compare
ef79809
to
24f44a2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
crates/bevy_gltf/src/loader.rs
Outdated
projection_matrix: projection.get_projection_matrix(), | ||
..Default::default() | ||
}, | ||
transform: Transform::from_matrix(Mat4::from_cols_array_2d( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the transform creation is shared across both projections and the else
statement. can we move this to a variable on line 217?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Job done 😁
I will take some time to check punctual lights import in a next PR. I think actually bevy only have a point light. |
I give a quick look at the file, and it looks similar of what I did to fix the gltf to load the bones hierarchy. *One note: first spawn the empty node and use the |
@lassade Thanks for the advice i didn't know how to do this. I will be glad to merge our efforts. |
Add support to camera import from a gltf scene