Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-121414

fuzzyQuaternionCompare discards tiny headRotations causing 'jumps' that are visible in XR

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P1: Critical
    • 6.8.0 FF
    • 6.7.0 Beta2, 6.8
    • Quick: 3D
    • None
    • All, Android, Windows
    • 561cc1a2f (dev)

    Description

      First the setup:

      Meta Quest 3

      running the app natively. But this works running locally on the PC with virtual desktop or anything too, makes no difference as far as I can see.

      The issue

      https://www.youtube.com/watch?v=Yp8BRj0bTRA **

      > The image makes tiny 'jumps' whenever you try to hold your head still and only make minute tiny head rotations.

      > It is a motion sickness inducing effect when standing still in VR, because the image is not updating according to your head rotation movement perfectly

      This is due to some fuzzyCompares we do in QtQuick3D. We seem to only mark any 3d node dirty if the position or rotation difference exceeds a certain significance threshold. This is decided by:

      fuzzyQuaternionCompare <- Located in qssgutils_p.h

      If you try to hold your head still, the reported rotation deltas are likely sometimes within the significance threshold of fuzzyQuaternionCompare. Leading to the camera rotation to not be updated for some frames. Only once the rotation exceeds this threshold does the camera update.

      Even though the fuzzyCompare says the rotation is 'insignificant', it is most definitely visible to the user and is therefore erroneously discarded.

      Now if we simply make sure this function allways returns false (indicating the quaternions are significantly different).

      then suddenly this issue is gone.

      The impact is really significant on the stability of objects in AR in the scene. And in general should be really easy to notice. I will attach a video to attempt to show the difference, but it is hard given the resolution of the recording so I recommend you to try this yourself.

      Scenario to reproduce:

      Just hold your head still in AR/VR and you should see whatever is rendered 'stick' or become 'jumpy' whenever you make minute tiny head movements.

      My interpretation of the problem:

      Now I don't know the exact reason why we do these fuzzycompares at all in QtQuick3D. But I suspect it comes from the 'retained GUI' methodology of only wanting to update what has actually changed in the scene. This leads to a problem because these tiny floating point deltas in the rotation matrix/quaternion are actually visible in the headset but deemed 'insignificant' why fyzzyQuaternionCompare. What this leads to is head movement for which the scene does not update and then suddenly when the head rotation displacement is 'significant' the camera node is updated and it manifests itself as little 'shocks' 'jumps' in the apparent position of the object/scene. Perhaps this methodology made sense before when these tiny rotations weren't visible on the screen, but now that we have XR I think this method is not suitable anymore.

      Proposed solution:

      -> Get rid of all fuzzyCompares in QtQuick3D or at least fuzzyQuaternionCompare. But the other fuzzycompares seem similarly unnecessary.

      Please take this with a healthy dose of skepticism as I don't know the exact reason why fuzzyCompares are needed for QtQuick3D in general. They seem unnecessary to me

       

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            qt.team.graphics.and.multimedia Qt Graphics Team
            felixvddonk Felix van de Donk
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes