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.
Inherited Members
Namespace: Microsoft.MixedReality.Toolkit.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 its 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 |