コード例 #1
0
        /// <summary>
        /// Creates or resets a data handler object as child of the given transform.
        /// </summary>
        /// <param name="parentTransform"></param> The parent transform.
        /// <returns></returns> The data handler object.
        public static DataHandler CreateOrResetDataHandler(Transform parentTransform = null)
        {
            DataHandler existingDataHandler = GeneralToolkit.GetOrCreateChildComponent <DataHandler>(parentTransform);

            existingDataHandler.Reset();
            return(existingDataHandler);
        }
コード例 #2
0
        /// <summary>
        /// Creates or resets a camera setup object as a child of the given transform.
        /// </summary>
        /// <param name="parentTransform"></param> The parent transform.
        /// <returns></returns> The camera setup object.
        public static CameraSetup CreateOrResetCameraSetup(Transform parentTransform = null)
        {
            CameraSetup existingSetup = GeneralToolkit.GetOrCreateChildComponent <CameraSetup>(parentTransform);

            existingSetup.Reset();
            return(existingSetup);
        }
コード例 #3
0
 /// <summary>
 /// Resets the camera parameters and geometry processing parameters.
 /// </summary>
 void Reset()
 {
     // Reset the processing object.
     processing = GeneralToolkit.GetOrCreateChildComponent <Processing.Processing>(transform);
     processing.Reset();
     // Reset the geometry processing parameters.
     _geometryProcessingMethod = (Processing.PerViewMeshesQSTR)processing.processingMethods[ProcessingMethod.indexPerViewMeshesQSTR];
 }
コード例 #4
0
 /// <summary>
 /// Resets the camera parameters and geometry processing parameters.
 /// </summary>
 void Reset()
 {
     // Reset the camera parameters.
     if (cameraModel == null)
     {
         cameraModel = CameraModel.CreateCameraModel(transform);
     }
     cameraModel.Reset();
     // Reset the geometry processing parameters.
     _geometryProcessingMethod = GeneralToolkit.GetOrCreateChildComponent <COLIBRIVR.Processing.PerViewMeshesQSTR>(transform);
     _geometryProcessingMethod.Reset();
     // Get the preview camera manager.
     _previewCameraManager = GeneralToolkit.GetOrCreateChildComponent <PreviewCameraManager>(transform);
     // Update the displayed preview.
     previewIndex = -1;
     Selected();
 }