英語で読む 編集

次の方法で共有


ManipulationHandler Class

Definition

This script allows for an object to be movable, scalable, and rotatable with one or two hands. You may also configure the script on only enable certain manipulations. The script works with both HoloLens' gesture input and immersive headset's motion controller input.

C++
public ref class ManipulationHandler : UnityEngine::MonoBehaviour, Microsoft::MixedReality::Toolkit::Input::IMixedRealityFocusChangedHandler, Microsoft::MixedReality::Toolkit::Input::IMixedRealityPointerHandler, UnityEngine::EventSystems::IEventSystemHandler
Inheritance
UnityEngine.MonoBehaviour
ManipulationHandler
Attributes
UnityEngine.AddComponentMenuAttribute UnityEngine.HelpURLAttribute
Implements
IMixedRealityFocusChangedHandler IMixedRealityPointerHandler UnityEngine.EventSystems.IEventSystemHandler

Constructors

Properties

Methods

ForceEndManipulation()

Releases the object that is currently manipulated

GetPointerGrabPoint(UInt32)

Gets the grab point for the given pointer id. Only use if you know that your given pointer id corresponds to a pointer that has grabbed this component.

OnBeforeFocusChange(FocusEventData)
OnFocusChanged(FocusEventData)
OnPointerClicked(MixedRealityPointerEventData)

When a pointer clicked event is raised, this method is used to pass along the event data to the input handler.

OnPointerDown(MixedRealityPointerEventData)

When a pointer down event is raised, this method is used to pass along the event data to the input handler.

OnPointerDragged(MixedRealityPointerEventData)
OnPointerUp(MixedRealityPointerEventData)

When a pointer up event is raised, this method is used to pass along the event data to the input handler.

Applies to

製品 バージョン
MRTK2 Unity 2018 2.5.0, 2.5.1, 2.5.2, 2.5.3, 2.5.4, 2.6.0, 2.7.0
MRTK2 Unity 2019 2.5.0, 2.5.1, 2.5.2, 2.5.3, 2.5.4, 2.6.0, 2.7.0, 2.8.0
MRTK2 Unity 2020 2.5.2, 2.5.3, 2.5.4, 2.6.0, 2.7.0, 2.8.0