Revive: Model Rotation in Medium

Created on 30 Dec 2016  路  30Comments  路  Source: LibreVR/Revive

When using the grip to rotate a model in Medium upon passing about 60degrees or more of rotation the model whips around violently.

This doesn't appear to be related to tracking. Observing the controller model it remains smooth and stationary while the model in Medium is whipping around.

I think it's probably related to revive but can't confirm as I have no access to an Oculus setup.

If necessary I can probably record a video of it happening as it's kind of hard to describe.. Hope someone else can confirm.

hotfix

Most helpful comment

I'll be on a much needed vacation next week, but once I'm back I plan to devote a lot more time to fixing Revive issues again including this one.

All 30 comments

I can confirm this is happening as well. It's really odd, sometimes the world just sort of.... flips around. Exremely annoying, and definitely not related to my controller tracking.

There is a known jitter issue that I'm still working on fixing. I'll also see if I can reproduce the rotation issue.

I can probably work on this on Monday.

I can't reproduce the problem unfortunately.

I'll create a video later tonight showing the exact issue (assuming I remember). Hopefully that can help.
The nature of how it snap-flips 180 degrees at an exact point of rotation every time makes me think it is some kinda bug.

Also, if it's relevant this is on the Nvidia 1070.

Can you reproduce it with every sculpt?

I can. I did a fresh sculpt here just to demonstrate, tried to keep it short:
https://www.youtube.com/watch?v=b_nLCW5QMYI

Note: those "errors" popping up on my tool hand are related to screenshots I've deleted since closing Medium last time. It just gripes that they're no longer where it left them. Unrelated.

I get the same error, but every time I use one hand to rotate the model and it flips out, I can switch to the other hand. This works fine for a while until it starts flipping out, but then I switch back to the first hand. After a while, it seems like the error accumulates, and it becomes harder and harder to move the objects around without making them spin. Will try to reproduce today.

I am seeing similar behavior in Quill as well as medium. When using both hands to move or scale, the model would occasionally flip 180 or 90 degrees. Could it have something to do with the way it's calculating pose/vectors when both hands are being used? I'm not seeing these issues when using one hand for moving.

I see the issue at specific rotation point and when using only a single hand to grip. In the video posted above I am rotating with a single grip button held.

I made a sculpture and saved it when it started behaving weird. Problem persists after restarting Medium, and reloading the file.
Download here: https://drive.google.com/file/d/0B-qY04DzmKsebDRrYmF2TDBCMUk/view?usp=sharing

It seems like there's a rounding error with rotation. Example; if you grab the object, and rotate your hand 0 - 361 degrees. Instead of looking like a seamless rotation, the model "lerps" from 0 to 360 the opposite way/rotation until it reaches the correct value, and then continues like normal to 361.

I have an exact same issue. While rotating model it sometimes starts jumping and flipping and moving uncontrollably, to an extend that afterwards it is sometimes hard to find it and get back to desired position. I would love to see that fixed as you really can't work effectively this way.
What @makerboost wrote applies to me in exact same way:

every time I use one hand to rotate the model and it flips out, I can switch to the other hand. This works fine for a while until it starts flipping out, but then I switch back to the first hand. After a while, it seems like the error accumulates, and it becomes harder and harder to move the objects around without making them spin.

Still experiencing this issue. It seems to happen at certain degree points of rotation as if it's crossing some threshold and then doing some bad math for a second and flipping out, then getting it back together and having the model as it should be again. Left-handed one-handed grip rotation is the easiest way to reproduce the problem in my experiences.

Can confirm, still seeing the issue.

I'll be on a much needed vacation next week, but once I'm back I plan to devote a lot more time to fixing Revive issues again including this one.

Not sure if this is still on your plate or not. Just thought I'd mention I'm still interested in a fix.

This is a bit more difficult than fixing a few tracking latency and controller detection issues. But I'll attach a milestone to make sure I won't forget about it in the next large release.

I haven't been able to reproduce this in time for the 1.1 release.

How large does your model need to be before this starts happening?

I updated revive and medium to the latest versions and tested fresh.
On a new project file with the tiniest model I could think to make (just a quick single stroke of the basic brush tool). Rotating it in the fashion shown in the video before (and posted again here) still does the flippy thing.

Seems like an issue reporting the rotation of the controller or something. Note it always happens at the same relative point of rotation.

Previous video:
https://www.youtube.com/watch?v=b_nLCW5QMYI

I see, it's probably a continuity problem in the angle, that's probably the point where -180 changes to 180.

If I can reproduce it tomorrow I'll release a hotfix.

Okay I was able to reproduce it, the cause seems to be the w component (essentially the angle) of the quaternion changing the sign (positive/negative) at that exact angle.

Fixed in commit 1655efedd418f6da2e01322069aa466868d6d5cb.

Just tested, Is still flipping around for me. Checked and revive version shows as 1.1.1. Not sure if I've messed anything else up

just quit steam and revive and steamvr and reopened. still happening

Damn, this is so hard to reproduce, but it shouldn't happen as often at least. I'll see if I can improve the detection of when the angle flipped.

Hotfixed in commit 94dda1f0ffc20a7f311d11c8be86d1a727e4f77a. For real this time.

I replaced the original 1.1.1 release, so just re-download it or use the update checker.

Let me give a little explanation of what went wrong for people who like quaternion math (do those people exist?). I corrected the angle of the rotation flipping around, but I didn't account for the fact that the axis could also flip and still represent the same rotation.

I don't really like the fact that I have to rely on remembering the previous orientation to detect when the flip happens. So I'll probably try detecting this condition in a different way in the next version.

you sir are amazing! I was just about to comment, that I have been using medium for 3 hours straight now, with no flipping. Then it suddently happened, it seemed to have to do with either the time passed or the sculpt size. I then saved, reopened the same, it persisted. Saved, opened new, it persisted.
Restarted the complete steamvr, revive overlay etc., opened the same sculpt, no problem for about 30 minutes.
Now I see you found the culprit, I'll be sure to test this and let u know.

Fantastic! it works. So nice to be confident when moving the sculpture. Thank you so much for your work!

I don't really like the fact that I have to rely on remembering the previous orientation to detect when the flip happens. So I'll probably try detecting this condition in a different way in the next version.

In the end I decided to keep relying on the previous orientation and use that data to also calculate the missing acceleration values that were not implemented yet.

So there won't be any more changes to this fix, you can see the final result in commit 1eaeda61cfb61869af47a785aa54b2b87134805a.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

roblaplante picture roblaplante  路  4Comments

GTGeoff picture GTGeoff  路  12Comments

GAMEDRIX picture GAMEDRIX  路  4Comments

KrisSchier picture KrisSchier  路  4Comments

newend picture newend  路  5Comments