Ejemplo n.º 1
0
        bool DoesObjectExist(VuMarkIdentifier markerId, string objectId)
        {
            ActiveObject activeObject = null;

            if (m_activeResourceObjects.TryGetValue(objectId, out activeObject))
            {
                return(activeObject.MarkerObjects.ContainsKey(markerId));
            }

            return(false);
        }
Ejemplo n.º 2
0
        protected virtual void ResetState()
        {
            m_identifier = null;

            IsTracking = false;

            var instances = GetComponentsInChildren <VuMarkTrackableInstance>();

            foreach (var instance in instances)
            {
                instance.gameObject.SetActive(false);
            }
        }
Ejemplo n.º 3
0
 void AttachMediaObject(VuMarkIdentifier identifier, GameObject parent, string objectId, MediaElement mediaElement, Action onOpen, Action onSelect, Action onComplete)
 {
     /*
      * AttachMediaObject(
      *  identifier,
      *  parent,
      *  objectId,
      *  mediaElement.MediaUrl,
      *  mediaElement.MediaItem.MediaType,
      *  mediaElement.Layout,
      *  onOpen,
      *  onSelect,
      *  onComplete);*/
 }
        protected virtual void OnTrackingLost()
        {
            m_identifier = null;

            IsTracking = false;

            var instances = GetComponentsInChildren <VuMarkTrackableInstance>();

            foreach (var instance in instances)
            {
                instance.gameObject.SetActive(false);
            }

            VuforiaWorld.Instance.StopTracking(this);
        }
        protected virtual void OnTrackingFound()
        {
            IsTracking = true;

            // Reset the identifier
            m_identifier = null;

            /*
             * var instanceId = m_trackableBehaviour.VuMarkTarget.InstanceId.StringValue;
             *
             * var instances = GetComponentsInChildren<VuMarkTrackableInstance>(true).Where(i => i.InstanceId == instanceId);
             *
             * foreach (var instance in instances)
             * {
             * instance.gameObject.SetActive(true);
             * }
             *
             * InstanceId = m_trackableBehaviour.VuMarkTarget.InstanceId.StringValue;
             */

            Debug.Log("Trackable " + Identifier.ToString() + " found");

            VuforiaWorld.Instance.StartTracking(this);
        }
 public virtual void ResetIdentifier()
 {
     m_identifier = null;
 }