cancel
Showing results for 
Search instead for 
Did you mean: 

reset view/origin for roomscale relocates whole play area for current session

voidroom
Protege

When I reset view/origin for roomscale for Oculus (PC), it seems that the whole play area is relocated, ie. instead of being wherever I was relative to my boundary, OpenXR gives pose just like I would be in the centre of the play area. And there is no way to learn where play area should be.

As my game relies heavily on actual location within the boundary, resetting view/origin breaks a lot. One could argue that the player should not reset view. Or that's it not consistent with other APIs.

If I do the same thing with Oculus SDK or VRAPI, I get still results against the play area. Well, that's not entirely true, as the origin might be offset, ie. not at 0,0,0 but there's enough information to know where I am relative to the actual boundary. With OpenXR, there's no play area anchoring and resetting moves us around.

I use resetting view for the menu to show stuff in front of the player, works especially well on Quest where resetting happens without any popups.

Some details: I have two reference spaces, one is XR_REFERENCE_SPACE_TYPE_VIEW to be view/head. The other is XR_REFERENCE_SPACE_TYPE_STAGE for roomscale.

Is that the intended behaviour? I suspect it might be a bug?

What I'd expect, one of two:
1. When reset happens, comes XrEventDataReferenceSpaceChangePending event, it should only indicate that something like that happened but the pose should be still relative to original play area and it's up to the programmer to handle resetting inside the game.
2. Or xrGetReferenceSpaceBoundsRect should return not only the size of the play area but also location and orientation of its centre.

9 REPLIES 9

voidroom
Protege

There is an information relative pose of the new centre, so it is possible to map it to the actual play area. It's a part of XrEventDataReferenceSpaceChangePending struct.

But this event may get called in two situations:
1. when the boundary gets updated
2. when the view is reset
I need to check how exactly this works (ie. if poseValid is set to true or false for both cases).

Maybe the "reset view" should have a different event? Or there should be a way to not relocate reference space?

Well, I finally checked it and it is not possible to map new centre to the actual play area as poseValid is set to false.

Hi. I currently also encounter this problem. My application needs to place the virtual object in the same position as the physical one. But when the user is still in the application, but take off the headset for a while and then put it on again. The origin will automatically reset so the calibration mess up. I am also finding the solution to solve it. I think we can have a discussion.

Recently I got the issue confirmed by Oculus support and I hope that it will be fixed soon.

 

Until then I have a working hack-around solution. When I receive event XR_TYPE_EVENT_DATA_REFERENCE_SPACE_CHANGE_PENDING, I store info that I need to reinit OpenXR. After all events are processed I do the reinit, ie. I close OpenXR system, create it again. Then it is set properly again.

 

This is not a good solution as it introduces a visible judder due to the reinitialisation. And I do it for all platforms ATM. It's not elegant but it works. At least for recenter request. I haven't checked the issue you mentioned - taking off the headset and putting it on again. But I had a similar issue happening. I just didn't connect the dots.

 

Oh, mind that this solution is how I implemented it in my own engine but I think that it should be still possible with Unity/Unreal (if they don't handle it). It should be possible to catch that event and to reinit at other time.

Thanks so much for your help! But I can not find the access in Unity to manipulate the event you mentioned. Maybe Unity didn't support this access. I am still finding the solution. 

I currently found oculus spatial anchor may perform this experience, but it is only provided in Oculus integration.

I understand Oculus integration as Oculus SDK / VRAPI. Yes, this works fine.

 

If there's no way in Unity to catch that event you may want to switch to Oculus integration or wait till it is fixed. For time being I'd suggest switching and waiting.

 

There are other issues as well. One is that Fixed Foveated Rendering does not work properly (it works in 2020.3 AFAIR) but in later versions it doesn't. And it doesn't work at all in native implementation. Also was reported, recently (August/September) I confirmed with the latest version available at the time.

 

I really hope that these issues will be resolved.

Hi, we are having exactly the same issue with XR_REFERENCE_SPACE_TYPE_STAGE coordinates shifting or being relative to the users initial position rather than locked to the center of the xrGetReferenceSpaceBoundsRect.

Has there been any update from Oculus support around a timeframe for this to be solved?

voidroom
Protege

Sadly, no information. Now I see that also my other tickets have been closed without providing any info or solution.

The way I handle this particular problem is still the same: I recreate the whole thing. This ends with some lagged frames but at least it works.