private void MainCamera_StateChanged(Camera sender, StateEventID eventID, int parameter)
 {
     try { if (eventID == StateEventID.Shutdown && IsInit)
           {
               Dispatcher.Invoke((Action) delegate { CloseSession(); });
           }
     }
     catch (Exception ex) { ReportError(ex.Message, false); }
 }
Example #2
0
 private void Camera_StateChanged(Camera sender, StateEventID eventID, int parameter)
 {
     try { if (eventID == StateEventID.Shutdown && IsInit)
           {
               CloseSession();
           }
     }
     catch (Exception ex) { ReportError(ex.Message, false); }
 }
Example #3
0
 void _currentCamera_StateChanged(Camera sender, StateEventID eventId, int parameter)
 {
     try
     {
         if (eventId == StateEventID.Shutdown && _isInitCanonApi)
         {
             Invoke((Action)StopSession);
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message);
     }
 }
Example #4
0
 private void MainCamera_StateChanged(Camera sender, StateEventID eventID, int parameter)
 {
     if (sendToUnity != null)
     {
         sendToUnity.Invoke("{\"CameraState\":\"" + eventID.ToString() + "\"}");
     }
     try
     {
         //if (eventID == StateEventID.WillSoonShutDown && IsInit)
         //{
         //    CloseCamera();
         //}
     }
     catch (Exception ex) { ReportError(ex.Message, false); }
 }
        private static void MainCamera_StateChanged(Camera sender, StateEventID eventID, uint parameter)
        {
            LogMessage("StateChanged " + eventID);

            if (eventID == StateEventID.CaptureError)
            {
                CaptureSuccess = false;
                DownloadReadyWaiter.Set();
            }

            if (eventID == StateEventID.Shutdown)
            {
                MainCamera = null;
            }
        }
Example #6
0
 private void MainCamera_StateChanged(EOSDigital.API.Camera sender, StateEventID eventID, int parameter)
 {
 }