using System.Collections; using System.Collections.Generic; using UnityEngine; using easyar; public class ImageTargetManager : MonoBehaviour { public ImageTrackerFrameFilter Tracker; void Start() { Debug.Log("ImageTargetManager Start"); GameObject imageTarget = (GameObject)Resources.Load("ImageTarget");//"Assets/EasyAR/Prefabs/Primitives/ImageTarget.prefab" imageTarget.name="ImageTarget-idback"; imageTarget.transform.position = new Vector3(0.1f,0,0.3f); imageTarget.transform.localScale=new Vector3(0.0856f,0.0856f,0.0856f); ImageTargetController controller = imageTarget.GetComponent(); controller.ActiveControl= easyar.TargetController.ActiveControlStrategy.HideWhenNotTracking; //controller.SourceType //controller.ImageFileSource.PathType controller.ImageFileSource.Path="idback.jpg"; controller.ImageFileSource.Name="idback"; controller.ImageFileSource.Scale=0.0856f; controller.Tracker=Tracker; Instantiate(imageTarget); } }