internal void CreateCaptureImageObject(string name, string cameraName, string layerName) { AdvGraphicLayer layer = this.FindLayer(layerName); if (layer == null) { Debug.LogError(layerName + " is not layer name"); } else { CameraRoot root = this.Engine.CameraManager.FindCameraRoot(cameraName); if (root == null) { Debug.LogError(cameraName + " is not camera name"); } else { AdvGraphicInfo grapic = new AdvGraphicInfo("Capture", name, "2D"); layer.GetObjectCreateIfMissing(name, grapic).InitCaptureImage(grapic, root.LetterBoxCamera.CachedCamera); } } }
//指定のカメラのキャプチャ画像を撮って、それを表示するオブジェクトを作成 internal void CreateCaptureImageObject(string name, string cameraName, string layerName) { AdvGraphicLayer layer = FindLayer(layerName); if (layer == null) { Debug.LogError(layerName + " is not layer name"); return; } CameraRoot cameraRoot = Engine.CameraManager.FindCameraRoot(cameraName); if (cameraRoot == null) { Debug.LogError(cameraName + " is not camera name"); return; } AdvGraphicInfo grapic = new AdvGraphicInfo(AdvGraphicInfo.TypeCapture, name, AdvGraphicInfo.FileType2D); AdvGraphicObject obj = layer.GetObjectCreateIfMissing(name, grapic); obj.InitCaptureImage(grapic, cameraRoot.LetterBoxCamera.CachedCamera); }