Skip to main content

IManipulationHandler

Interface to handle object Manipulation interaction. Manipulation is done by long-pressing the select button. In Manipulation, you can grab an object and then perform actions like rotating, scaling, or dragging it from one place to another.

MethodDescription
OnManipulationCompletedCalled when the manipulation is completed
OnManipulationStartedCalled when the manipulation is started
OnManipulationUpdatedCalled when the manipulation is updated
using JMRSDK.InputModule;
using UnityEngine;
public class InterfaceExample: MonoBehaviour, IManipulationHandler
{
public void OnManipulationCompleted(ManipulationEventData eventData) {
Debug.Log("OnManipulationCompleted");
}
public void OnManipulationStarted(ManipulationEventData eventData) {
Debug.Log("OnManipulationStarted");
}
public void OnManipulationUpdated(ManipulationEventData eventData) {
Debug.Log("OnManipulationUpdated");
}
}

ManipulationEventData

DatatypeVariableDescription
EventSystems.BaseInputModulecurrentInputModuleGet the currently active Input Module
GameObjectselectedObjectGet the currently selected object
Vector3CumulativeDeltaCumulative manipulation distance since manipulation started