Tap to Place MRTK#7188
Conversation
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/TapToPlace.cs
Outdated
Show resolved
Hide resolved
...ts/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/HideTapToPlaceLabel.cs
Outdated
Show resolved
Hide resolved
...ts/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/HideTapToPlaceLabel.cs
Outdated
Show resolved
Hide resolved
...ts/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/HideTapToPlaceLabel.cs
Outdated
Show resolved
Hide resolved
...ts/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/HideTapToPlaceLabel.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Inspectors/TapToPlaceInspector.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Experimental/Inspectors/TapToPlaceInspector.cs
Outdated
Show resolved
Hide resolved
Troy-Ferrell
left a comment
There was a problem hiding this comment.
Cool stuff! I know you are only in draft mode but left some initial comments to review before creating pull request
...ts/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/HideTapToPlaceLabel.cs
Outdated
Show resolved
Hide resolved
...ts/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/HideTapToPlaceLabel.cs
Outdated
Show resolved
Hide resolved
...ts/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/HideTapToPlaceLabel.cs
Outdated
Show resolved
Hide resolved
...ts/MixedRealityToolkit.SDK/Experimental/Features/Utilities/TapToPlace/HideTapToPlaceLabel.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Inspectors/Utilities/Solvers/TapToPlaceInspector.cs
Outdated
Show resolved
Hide resolved
julenka
left a comment
There was a problem hiding this comment.
Good progress. I have several smaller comments but have a must-have request: please make it possible to start and stop placement from code. Would also recommend removing the custom inspector
Assets/MixedRealityToolkit.Examples/Demos/Solvers/Scripts/HideTapToPlaceLabel.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
|
|
||
| // Disable ability to edit through the inspector if in play mode | ||
| bool isPlayMode = EditorApplication.isPlaying || EditorApplication.isPaused; | ||
| using (new EditorGUI.DisabledScope(isPlayMode)) |
There was a problem hiding this comment.
Why do we need to disable editing this component if in play mode?
There was a problem hiding this comment.
If the user tries to toggle AutoStart while in play mode, the change will not get registered because the action associated with AutoStart is called only in Start(). I disabled it to remove the potential confusion if someone tried to toggle AutoStart while in play mode through the inspector only to see nothing happen.
There was a problem hiding this comment.
Not sure this is worth building an entire custom inspector for. Asking @Troy-Ferrell for his opinion. I would vote to not make a custom inspector just t support this.
Assets/MixedRealityToolkit.SDK/Inspectors/Utilities/Solvers/TapToPlaceInspector.cs
Outdated
Show resolved
Hide resolved
julenka
left a comment
There was a problem hiding this comment.
Looking better, a couple more comments.
| /// TrackedTargetType (Head by default) at a default distance. StopPlacement() must be called after StartPlacement() to stop the | ||
| /// game object from following the TrackedTargetType. | ||
| /// </summary> | ||
| public void StartPlacement() |
There was a problem hiding this comment.
Would be good to add tests to verify that StartPlacement() and StopPlacement() work when called from code. Good candidate for tests.
There was a problem hiding this comment.
Tests will be added in another PR, but there will be a test with code configurability in mind.
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
…ced check to Start/StopPlacement
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
|
/azp run |
|
Azure Pipelines successfully started running 2 pipeline(s). |
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
Assets/MixedRealityToolkit.SDK/Features/Utilities/Solvers/TapToPlace.cs
Outdated
Show resolved
Hide resolved
|
/azp run |
|
Azure Pipelines successfully started running 2 pipeline(s). |
keveleigh
left a comment
There was a problem hiding this comment.
Sorry I'm super late to the review party, but just a few comments.

Overview
The MRTK version of HoloToolkit's Tap to Place.
Tap to Place enables easy placement of an object on a surface. The default behavior for Tap to Place MRTK mirrors HoloToolkit's Tap to Place, but has some new additions. Tap to Place is a derivation of the Solver class.
To test, open the example scene TapToPlaceExample located in MixedRealityToolkit.Examples/Demos/Solvers/Scenes/.
How to use:
Changes from HoloToolkit to MRTK's Tap to Place:
This work is based on @Troy-Ferrell's tap to place branch found here.
Images/Gifs
Tap to Place Inspector

VR Behavior:

Changes
TO DO
Update PR Description, add gifsVerification