Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
This script allows for dynamically blending out a target after it has been looked at for a certain amount of time.
public ref class BlendOut : UnityEngine::MonoBehaviour
[UnityEngine.AddComponentMenu("Scripts/MRTK/Examples/BlendOut")] public class BlendOut : UnityEngine.MonoBehaviour
[<UnityEngine.AddComponentMenu("Scripts/MRTK/Examples/BlendOut")>] type BlendOut = class inherit MonoBehaviour
Public Class BlendOut Inherits MonoBehaviour
Once the user looks away from the hologram, determine whether the user has dwelled at it before. If yes, start blending it out and destroy it if that option was selected. If not, we can still blend it out a little, but keep it alive and visible.
Once the target is looked at, set it to its full "look at transparency" and let's prevent its destruction when being looked at.