AR Design
UBC EML collab with UBC SALA - visualizing IoT data in AR
InputPositionEventData.cs
Go to the documentation of this file.
1 // Copyright (c) Microsoft Corporation. All rights reserved.
2 // Licensed under the MIT License. See LICENSE in the project root for license information.
3 
4 using UnityEngine;
5 using UnityEngine.EventSystems;
6 
7 namespace HoloToolkit.Unity.InputModule
8 {
10  {
14  public Vector2 Position;
15 
16  public InputPositionEventData(EventSystem eventSystem) : base(eventSystem)
17  {
18  }
19 
20  public void Initialize(IInputSource inputSource, uint sourceId, object tag, InteractionSourcePressInfo pressType, Vector2 position)
21  {
22  Initialize(inputSource, sourceId, tag, pressType);
23  Position = position;
24  }
25  }
26 }
Vector2 Position
Two values, from -1.0 to 1.0 in the X-axis and Y-axis, representing where the input control is positi...
void Initialize(IInputSource inputSource, uint sourceId, object tag, InteractionSourcePressInfo pressType, Vector2 position)
Interface for an input source. An input source can be anything that a user can use to interact with a...
Definition: IInputSource.cs:12
Describes an input event that has a source id and a press kind.