mrtk_developmentreleases/2.0.0releases/2.1.0releases/2.2.0

    Show / Hide Table of Contents

    Class ProximityEffect

    ProximityEffect scales and switches out materials for registered objects whenever a pointer is in proximity. Scaling is done on three different stages: far / medium and close proximity whereas material switching will only be done on close proximity.

    Inheritance
    Object
    ProximityEffect
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Microsoft.MixedReality.Toolkit.Experimental.UI.BoundsControl
    Assembly: cs.temp.dll.dll
    Syntax
    public class ProximityEffect

    Methods

    ClearObjects()

    Clears all registered objects in the proximity effect

    Declaration
    public void ClearObjects()

    RegisterObjectProvider(IProximityEffectObjectProvider)

    register objects for proximity effect via a IProximityEffectObjectProvider

    Declaration
    public void RegisterObjectProvider(IProximityEffectObjectProvider provider)
    Parameters
    Type Name Description
    IProximityEffectObjectProvider provider

    ResetProximityScale()

    Resets all objects that had a proximity effect applied. This will reset them to their default size and reset to the base material

    Declaration
    public void ResetProximityScale()

    UpdateScaling(Vector3, Vector3)

    Updates proximity effect and it's registered objects. Highlights and scales objects in proximity according to the pointer distance

    Declaration
    public void UpdateScaling(Vector3 boundsCenter, Vector3 boundsExtents)
    Parameters
    Type Name Description
    Vector3 boundsCenter

    gameobject position the proximity effect is attached to

    Vector3 boundsExtents

    extents of the gameobject the proximity effect is attached to

    In This Article
    • Methods
      • ClearObjects()
      • RegisterObjectProvider(IProximityEffectObjectProvider)
      • ResetProximityScale()
      • UpdateScaling(Vector3, Vector3)
    Back to top Generated by DocFX