Yellow-Dog-Man / Resonite-Issues

Issue repository for Resonite.
https://resonite.com
135 stars 2 forks source link

UserRoot OverrideView Jitters in VR When Set #1520

Open lxw404 opened 6 months ago

lxw404 commented 6 months ago

Describe the bug?

When setting the OverrideView slot on a UserRoot, the user's view jitters considerably. This makes special effects and avatars that use this setting nausea-inducing to use for extended periods of time.

This could possibly be related to: https://github.com/Yellow-Dog-Man/Resonite-Issues/issues/151, https://github.com/Yellow-Dog-Man/Resonite-Issues/issues/1492, and https://github.com/Yellow-Dog-Man/Resonite-Issues/issues/1493.

To Reproduce

Spawn the reproduction item below and grab the box. This sets the OverrideView to be the user's UserRoot Head slot which should transform 1:1 with the original view, however it will jitter very badly.

resrec:///U-LuxKitty/R-544F627B5D721013147CA133FC4F724ECB6F20929FE87BD647EF02D88C53431F

You can alternatively drag the Head slot in the user's UserRoot into the UserRoot OverrideView field and the same behavior will happen.

Expected behavior

The OverrideView should not jitter, and instead update its transform at the same rate as the slot that it is overriding to.

Screenshots

No response

Resonite Version Number

2024.3.12.1169

What Platforms does this occur on?

Windows

What headset if any do you use?

Valve Index

Log Files

OverrideView Jitter Bug - 2024.3.12.1169 - 2024-03-20 20_44_10.log

Additional Context

From some extensive testing, changing the UpdateOrder on any of the components responsible does not seem to affect anything. This issue persists on objects that are detached from the user itself, or parented to the user, whether transforming with components that copy global transforms, or even writing their transforms with ProtoFlux every frame.

Reporters

LuxKitty

shiftyscales commented 6 months ago

Is this issue only observable when placing it under the user's root? or can it also be observed to do the same if using an external slot which is driven by other components/means?

lxw404 commented 6 months ago

This issue can be observed regardless of parenting structure. As noted above, the other method to testing this is to drag the Head slot in the user's user root and put it into the UserRoot component's OverrideView field as shown below:

2024-03-21 21 37 17rz

If you mean if the slot that is overriding is external to the user entirely, then this can easily be observed by creating an empty object that is not parented, then dragging the slot of this into the OverrideView as above. The jitter is still observable in this case as well.

You can even go so far as to copy the head rotation and position to this slot and then do the same view override, and it will jitter. There is another example of this in the same folder:

resrec:///U-LuxKitty/R-544F627B5D721013147CA133FC4F724ECB6F20929FE87BD647EF02D88C53431F

where putting the child slot manually into the OverrideView field will have the same effect.

shiftyscales commented 6 months ago

It is probably an update/rendering order issue as you suspect. Just had a moment to use your replication object.

lxw404 commented 5 months ago

I've changed the title per @epicEaston197 's request, however my suspicion is that it is actually doing the same thing in desktop mode, but you do not have the ability to see the frame offset in time when it's not affecting your vision directly. This would also explain why it is not possible to get a recording of it since a recording will just look the same even if it is time offset, however this is an offset you can feel when it directly affects your sense of spatial awareness.