-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Fixes the problem with accumulating teleportation heights #1400
Conversation
#1181 The MixedRealityCameraParent changed heights based on a raycast from the head to the floor. Depending on where the camera is in relation to the parent, the parent's base height shrank or grew. The head raycast howere is not needed and removed since the relative distance to the cameraParent is always controlled via HDM and the target teleport position for the parent is always known.
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.
This change seems to assume a couple things:
- The app will have a RoomScale tracking space type.
- The initial floor will be placed at Y = 0.
Apps setting their tracking space type to Stationary won't have the camera height offset from the parent like you're expecting, so you'll teleport the camera into the teleport spot.
Although a floor at Y = 0 in RoomScale should be the desired state most of the time, there may be scenarios where that isn't the case.
The second assumption is probably less important to handle, but this should take the different tracking space types into account at least.
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.
I agree with Kev here.
I have a question about the stationary space type then. Why is the camera not getting the same height data like it gets when in Room Scale mode? The MR Portal seems to keep the head above the floor just fine, no matter the type, why is the camera tracking data passed to Unity differing? |
@Alexees That's by definition of Stationary vs RoomScale. https://developer.microsoft.com/en-us/windows/mixed-reality/Coordinate_systems_in_Unity.html#building_an_orientation-only_or_seated-scale_experience |
I am experiencing the Teleport Marker comming off the floor at times. Is this issue the same? Theoretically the position of the marker should be based on a trajectory calculation where the end point (target) would be on a mostly flat surface that would allow for "targeting" and the beginning of the trajectory is the pointer or the camera. Based on the angle of elevation the target position can be calculated using velocity, gravity and time. |
We need fixes here so removing pending for release tag. Not blocking for this release. |
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.
Note, this PR is now stale due to the Namespace updates in the Dev_Working branch. Please refresh or create a new PR against Dev_Working with these changes please.
Teleport system has been rewritten. |
Overview
The MixedRealityCameraParent changed heights based on a raycast from the head to the floor. Depending on where the camera is in relation to the parent, the parent's base height shrank or grew. The head raycast howere is not needed and removed since the relative distance to the cameraParent is always controlled via IHDM and the target teleport position for the parent is always known.
Changes