Forum Discussion
trs70
7 months agoStart Member
Grabbed object with custom pose "wiggles" when moving controller or hands rapidly back and forth
I posted an issue at https://github.com/oculus-samples/Unreal-InteractionSDK-Sample/issues/16 but adding here for visibility also.
I found that if I grabbed an object with a custom pose and moved the controller back and forth quickly the grabbed object doesn't seem to to track my virtual hand quite right. It kind of looks like the object "wiggles" or jiggles/lags behind the hands. This was only happening with pose mode set to "Snap Object to Pose". I tracked it down to CalculateInteractorSnapTransform() in OculusInteraction\Private\Interaction\Grabbable\IsdkGrabTransformerComponent.cpp but I'm not sure the best way to fix. I notice some of the other branches in UIsdkGrabTransformerComponent::UpdateTransform() end up calling TransformTarget->SetRelativeTransform(TargetRelativeTransform); which doesn't exhibit the issue. Hands tracking also seems to have the same issue.
I asked Gemini for a solution and it suggested this code:
FTransform UIsdkGrabTransformerComponent::CalculateInteractorSnapTransform( FTransform& TargetTransformIn, FTransform& InteractorTransformIn) {
const FTransform OffsetInverse = InteractorSnapOffset.Inverse();
const FTransform FinalTransform = OffsetInverse * InteractorTransformIn;
return FinalTransform;
}
It did fix the problem, but I'm not sure what other purposes the original code had as it was more complex. Thanks!
Replies have been turned off for this discussion
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device
Other Meta Support
Related Content
- 2 years ago
- 1 year ago
- 4 years ago