MixedRealityToolkit-Unity icon indicating copy to clipboard operation
MixedRealityToolkit-Unity copied to clipboard

Line gizmos fail when MRTK not configured.

Open Railboy opened this issue 8 years ago • 6 comments

Does this affect the legacy HoloToolkit (master) or the Mixed Reality Toolkit (mrtk_release)? Mixed Reality Toolkit

Describe the bug Clicking and dragging on points in any of the following classes sends the point into the far background, making it impossible to edit them by hand: SimpleLineDataProvider ParabolaConstrainedLineDataProvider SplineDataProvider

To Reproduce

  1. Create new scene.
  2. Add 'SplineDataProvider' component to empty GameObject.
  3. Attempt to modify spline by click-dragging points.
  4. Observe points ending up in unexpected positions.

Expected behavior Click-dragging should move points into a predictable, intuitive position.

Railboy avatar Sep 21 '18 19:09 Railboy

I believe in HTK, the drag points were in screen space. Are they not in vNext?

radicalad avatar Sep 21 '18 19:09 radicalad

Is it all line editors, or just the spline?

StephenHodgson avatar Sep 21 '18 19:09 StephenHodgson

So I opened up and tried to edit the line gallery and it seemed to work fine. I wonder that the difference is.

StephenHodgson avatar Sep 21 '18 19:09 StephenHodgson

After pressing "Configure" to setup a scene with the MixedRealityManager, everything seems to fix this. Might also be related.

StephenHodgson avatar Sep 21 '18 19:09 StephenHodgson

Okay just to clarify I can only repro with these three classes:

ParabolicConstrainedLineDataProvider SimpleLineDataProvider SplineDataProvider

Might have something to do with the set point method using the CameraCache.Main.transform point transformation methods.

StephenHodgson avatar Sep 21 '18 20:09 StephenHodgson

Editor controls should rely on viewport cameras exclusively since there's no guarantee that a MainCamera will even exist in a given scene.

Railboy avatar Sep 21 '18 20:09 Railboy