示例#1
0
 protected override void OnDisable()
 {
     if (feed == null || !feed.isActiveAndEnabled || feed.context.Data != context.Data || feed.Texture == null)
     {
         feed = (RealSense.RealSenseInputFeed)RealSense.RealSenseInputFeed.FindInputFeed(context);
     }
     feed.ShowInfrared(false);
     base.OnDisable();
 }
示例#2
0
        protected override void OnEnable()
        {
            image = GetComponent <RawImage>();

            base.OnEnable();

            if (feed == null || !feed.isActiveAndEnabled || feed.context.Data != context.Data || feed.Texture == null)
            {
                feed = (RealSense.RealSenseInputFeed)RealSense.RealSenseInputFeed.FindInputFeed(context);
            }

            if (feed != null)
            {
                feed.ShowInfrared(true);
            }

            HandleDataChanged();
        }