Class FocusProvider
The focus provider handles the focused objects per input source.
Inheritance
FocusProvider
Implements
IDisposable
IEventSystemHandler
Assembly: cs.temp.dll.dll
public class FocusProvider : BaseCoreSystem, IMixedRealityEventSystem, IMixedRealityFocusProvider, IMixedRealityService, IDisposable, IMixedRealitySourceStateHandler, IMixedRealitySpeechHandler, IMixedRealityBaseInputHandler, IEventSystemHandler, IPointerPreferences
Constructors
Declaration
public FocusProvider(IMixedRealityServiceRegistrar registrar, MixedRealityInputSystemProfile profile)
Parameters
Declaration
public FocusProvider(IMixedRealityServiceRegistrar registrar, MixedRealityInputSystemProfile profile)
Parameters
Declaration
public FocusProvider(MixedRealityInputSystemProfile profile)
Parameters
Declaration
public FocusProvider(MixedRealityInputSystemProfile profile)
Parameters
Properties
Declaration
public LayerMask[] FocusLayerMasks { get; }
Property Value
Type |
Description |
LayerMask[] |
|
Declaration
public LayerMask[] FocusLayerMasks { get; }
Property Value
Type |
Description |
LayerMask[] |
|
Declaration
public PointerBehavior GazePointerBehavior { get; set; }
Property Value
Declaration
public PointerBehavior GazePointerBehavior { get; set; }
Property Value
Declaration
public override string Name { get; protected set; }
Property Value
Overrides
Declaration
public override string Name { get; protected set; }
Property Value
Overrides
The number of pointers that support far interaction (like motion controller rays, hand rays) that
are active (IsInteractionEnabled == true), excluding the gaze cursor
Declaration
public int NumFarPointersActive { get; }
Property Value
The number of pointers that support far interaction (like motion controller rays, hand rays) that
are active (IsInteractionEnabled == true), excluding the gaze cursor
Declaration
public int NumFarPointersActive { get; }
Property Value
Number of IMixedRealityNearPointers that are active (IsInteractionEnabled == true).
Declaration
public int NumNearPointersActive { get; }
Property Value
Number of IMixedRealityNearPointers that are active (IsInteractionEnabled == true).
Declaration
public int NumNearPointersActive { get; }
Property Value
Declaration
public IReadOnlyDictionary<uint, IMixedRealityPointerMediator> PointerMediators { get; }
Property Value
Declaration
public IReadOnlyDictionary<uint, IMixedRealityPointerMediator> PointerMediators { get; }
Property Value
Declaration
public IMixedRealityPointer PrimaryPointer { get; }
Property Value
Declaration
public IMixedRealityPointer PrimaryPointer { get; }
Property Value
Declaration
public override uint Priority { get; }
Property Value
Overrides
Declaration
public override uint Priority { get; }
Property Value
Overrides
Declaration
public Camera UIRaycastCamera { get; }
Property Value
Declaration
public Camera UIRaycastCamera { get; }
Property Value
Methods
Declaration
public override void Destroy()
Overrides
Declaration
public override void Destroy()
Overrides
Declaration
public uint GenerateNewPointerId()
Returns
Declaration
public uint GenerateNewPointerId()
Returns
Declaration
public GameObject GetFocusedObject(IMixedRealityPointer pointingSource)
Parameters
Returns
Type |
Description |
GameObject |
|
Declaration
public GameObject GetFocusedObject(IMixedRealityPointer pointingSource)
Parameters
Returns
Type |
Description |
GameObject |
|
Declaration
public PointerBehavior GetPointerBehavior(IMixedRealityPointer pointer)
Parameters
Returns
Declaration
public PointerBehavior GetPointerBehavior(IMixedRealityPointer pointer)
Parameters
Returns
Gets the behavior for the given pointer type.
Declaration
public PointerBehavior GetPointerBehavior<T>(Handedness handedness, InputSourceType sourceType)
where T : class, IMixedRealityPointer
Parameters
Type |
Name |
Description |
Handedness |
handedness |
Handedness to query
|
InputSourceType |
sourceType |
|
Returns
Type |
Description |
PointerBehavior |
PointerBehavior for the given pointer type and handedness. If right hand is enabled, left
hand is not enabled, and Handedness.Any is passed, returns value for the right hand.
|
Type Parameters
Gets the behavior for the given pointer type.
Declaration
public PointerBehavior GetPointerBehavior<T>(Handedness handedness, InputSourceType sourceType)
where T : class, IMixedRealityPointer
Parameters
Type |
Name |
Description |
Handedness |
handedness |
Handedness to query
|
InputSourceType |
sourceType |
|
Returns
Type |
Description |
PointerBehavior |
PointerBehavior for the given pointer type and handedness. If right hand is enabled, left
hand is not enabled, and Handedness.Any is passed, returns value for the right hand.
|
Type Parameters
Declaration
public IEnumerable<T> GetPointers<T>()
where T : class, IMixedRealityPointer
Returns
Type |
Description |
IEnumerable<T> |
|
Type Parameters
Declaration
public IEnumerable<T> GetPointers<T>()
where T : class, IMixedRealityPointer
Returns
Type |
Description |
IEnumerable<T> |
|
Type Parameters
Declaration
public override void Initialize()
Overrides
Declaration
public override void Initialize()
Overrides
Declaration
public bool IsPointerRegistered(IMixedRealityPointer pointer)
Parameters
Returns
Declaration
public bool IsPointerRegistered(IMixedRealityPointer pointer)
Parameters
Returns
Declaration
public void OnSourceDetected(SourceStateEventData eventData)
Parameters
Declaration
public void OnSourceDetected(SourceStateEventData eventData)
Parameters
Declaration
public void OnSourceLost(SourceStateEventData eventData)
Parameters
Declaration
public void OnSourceLost(SourceStateEventData eventData)
Parameters
Declaration
public void OnSpeechKeywordRecognized(SpeechEventData eventData)
Parameters
Declaration
public void OnSpeechKeywordRecognized(SpeechEventData eventData)
Parameters
Declaration
public bool RegisterPointer(IMixedRealityPointer pointer)
Parameters
Returns
Declaration
public bool RegisterPointer(IMixedRealityPointer pointer)
Parameters
Returns
Declaration
public void SetPointerBehavior<T>(Handedness handedness, InputSourceType inputType, PointerBehavior pointerBehavior)
where T : class, IMixedRealityPointer
Parameters
Type Parameters
Declaration
public void SetPointerBehavior<T>(Handedness handedness, InputSourceType inputType, PointerBehavior pointerBehavior)
where T : class, IMixedRealityPointer
Parameters
Type Parameters
Declaration
public void SubscribeToPrimaryPointerChanged(PrimaryPointerChangedHandler handler, bool invokeHandlerWithCurrentPointer)
Parameters
Declaration
public void SubscribeToPrimaryPointerChanged(PrimaryPointerChangedHandler handler, bool invokeHandlerWithCurrentPointer)
Parameters
Declaration
public bool TryGetFocusDetails(IMixedRealityPointer pointer, out FocusDetails focusDetails)
Parameters
Returns
Declaration
public bool TryGetFocusDetails(IMixedRealityPointer pointer, out FocusDetails focusDetails)
Parameters
Returns
Declaration
public bool TryOverrideFocusDetails(IMixedRealityPointer pointer, FocusDetails focusDetails)
Parameters
Returns
Declaration
public bool TryOverrideFocusDetails(IMixedRealityPointer pointer, FocusDetails focusDetails)
Parameters
Returns
Declaration
public bool UnregisterPointer(IMixedRealityPointer pointer)
Parameters
Returns
Declaration
public bool UnregisterPointer(IMixedRealityPointer pointer)
Parameters
Returns
Declaration
public void UnsubscribeFromPrimaryPointerChanged(PrimaryPointerChangedHandler handler)
Parameters
Declaration
public void UnsubscribeFromPrimaryPointerChanged(PrimaryPointerChangedHandler handler)
Parameters
Declaration
public override void Update()
Overrides
Declaration
public override void Update()
Overrides
Explicit Interface Implementations
Declaration
float IMixedRealityFocusProvider.GlobalPointingExtent { get; }
Returns
Declaration
float IMixedRealityFocusProvider.GlobalPointingExtent { get; }
Returns
Implements
IDisposable
IEventSystemHandler