void Awake() { //TODO: Singleton Implementation? this.level = Application.loadedLevel; // Scene Cameras Init this.cameras = new List<Camera>(); this.maincamera = GetComponent<Camera>(); this.cameras.Add(maincamera); this.recorder = GetComponent<KinectOneRecording>(); this.minimap = FindObjectOfType<MinimapColorRendering>(); this.kinectPrefab = Resources.Load<GameObject>(KinectPrefabLocation); this.InitKinectContext(); this.AssignKinectControllers(); DontDestroyOnLoad(this.gameObject); }
void Awake() { // get kinect specific behaviours this.capturer = GetComponent<ScanImageCapturing>(); this.tracker = GetComponent<BodyTracking>(); this.recorder = GetComponent<ScanImageRecording>(); this.exporter = GetComponent<SkeletonOneExporting>(); this.settings = GetComponent<KinectOneSettings>(); // model renderer this.kinectRenderer = GetComponentInChildren<MeshRenderer>(); // gui minimap video renderer this.colorMinimap = FindObjectOfType<MinimapColorRendering>(); this.skin = Resources.Load<GUISkin>(GuiSkinLocation); DontDestroyOnLoad(this.gameObject); }