How to clip through 3D objects in-game with ClippingPlaneControls script in Unity
Scripts required: ClippingPlaneControls
VIMEO link: https://vimeo.com/730610533/41177a6ee2
Step by step (preparation):
- Ensure that the OVRPlayerController is installed (full instructions here).
- Use the GenericLoader script to load a dataset into Unity (full instructions here).
- Add controller functionality and dataset grab capabilities (full instructions for SelectionManager and OVR Grabbable Extended).
Step by step (attach the components and script):
- With the dataset highlighted in the project hierarchy, click the Add Component button and search for ClippingPlaneControls (fig. 1). Hit enter to add.
- To attach the Tracking Space, open the OVRPlayerController in the project hierarchy, then OVR Camera Rig. Then find Tracking Space (fig. 2).
- Make sure that your dataset is highlighted in the hierarchy, then click and drag the TrackingSpace to the OVR Tacking Space field in the Clipping Plane Controls inspector tab (fig. 3). Click the play button to use the controls.
Click Add Component to find the ClippingPlaneControls
Location of TrackingSpace within OVRPlayerController
Drag the TrackingSpace to the OVR Tracking Space field
- Using both controllers, press and hold index triggers, then move hands toward the model with palms facing the direction you’d like to clip away.