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.Experimental.UI.BoundsControl
Assembly: cs.temp.dll.dll
Syntax
public class ProximityEffect
Methods
AddObjects(IProximityEffectObjectProvider)
register objects for proximity effect via a IProximity
Declaration
public void AddObjects(IProximityEffectObjectProvider provider)
Parameters
Type | Name | Description |
---|---|---|
IProximity |
provider |
ClearObjects()
Clears all registered objects in the proximity effect
Declaration
public void ClearObjects()
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 |