camerauis/cameraxui/cxengine/src/cxevideocapturecontrolsymbian.cpp
changeset 42 feebad15db8c
parent 41 67457b2ffb33
child 46 c826656d6714
equal deleted inserted replaced
41:67457b2ffb33 42:feebad15db8c
   297     if (state() != Preparing) {
   297     if (state() != Preparing) {
   298         // not valid state to continue prepare.
   298         // not valid state to continue prepare.
   299         return;
   299         return;
   300     }
   300     }
   301 
   301 
   302     OstTrace0(camerax_performance, CXEVIDEOCAPTURECONTROLSYMBIAN_PREPARE, "msg: e_CX_VIDCAPCONT_PREPARE 1");
   302     OstTrace0(camerax_performance, CXEVIDEOCAPTURECONTROL_PREPARE_1, "msg: e_CX_VIDCAPCONT_PREPARE 1");
   303     QSize frameSize(mCurrentVideoDetails.mWidth, mCurrentVideoDetails.mHeight);
   303     QSize frameSize(mCurrentVideoDetails.mWidth, mCurrentVideoDetails.mHeight);
   304 
   304 
   305     int muteSetting = 0; // audio enabled
   305     int muteSetting = 0; // audio enabled
   306     mSettings.get(CxeSettingIds::VIDEO_MUTE_SETTING, muteSetting);
   306     mSettings.get(CxeSettingIds::VIDEO_MUTE_SETTING, muteSetting);
   307 
   307 
   341     } catch (const std::exception &e) {
   341     } catch (const std::exception &e) {
   342         // Handle error.
   342         // Handle error.
   343         handlePrepareFailed();
   343         handlePrepareFailed();
   344     }
   344     }
   345 
   345 
   346     OstTrace0(camerax_performance, DUP1_CXEVIDEOCAPTURECONTROLSYMBIAN_PREPARE, "msg: e_CX_VIDCAPCONT_PREPARE 0");
   346     OstTrace0(camerax_performance, CXEVIDEOCAPTURECONTROL_PREPARE_2, "msg: e_CX_VIDCAPCONT_PREPARE 0");
   347     CX_DEBUG_EXIT_FUNCTION();
   347     CX_DEBUG_EXIT_FUNCTION();
   348 }
   348 }
   349 
   349 
   350 /*!
   350 /*!
   351 * Fetches video qualites details based on video quality setting.
   351 * Fetches video qualites details based on video quality setting.
   352 */
   352 */
   353 void
   353 void
   354 CxeVideoCaptureControlSymbian::getVideoQualityDetails(CxeVideoDetails &videoInfo)
   354 CxeVideoCaptureControlSymbian::getVideoQualityDetails(CxeVideoDetails &videoInfo)
   355 {
   355 {
   356     CX_DEBUG_ENTER_FUNCTION();
   356     CX_DEBUG_ENTER_FUNCTION();
       
   357     OstTrace0( camerax_performance, CXEVIDEOCAPTURECONTROL_GETQUALITYDETAILS_1, "msg: e_CX_GET_QUALITY_DETAILS 1" );
   357 
   358 
   358     int quality(0);
   359     int quality(0);
   359 
   360 
   360     // Get quality index for primary camera. Only one quality for secondary camera.
   361     // Get quality index for primary camera. Only one quality for secondary camera.
   361     if (mCameraDeviceControl.cameraIndex() == Cxe::PrimaryCameraIndex) {
   362     if (mCameraDeviceControl.cameraIndex() == Cxe::PrimaryCameraIndex) {
   367     }
   368     }
   368 
   369 
   369     // get video quality details
   370     // get video quality details
   370     videoInfo = mIcmSupportedVideoResolutions.at(quality);
   371     videoInfo = mIcmSupportedVideoResolutions.at(quality);
   371 
   372 
       
   373     OstTrace0( camerax_performance, CXEVIDEOCAPTURECONTROL_GETQUALITYDETAILS_2, "msg: e_CX_GET_QUALITY_DETAILS 0" );
   372     CX_DEBUG_EXIT_FUNCTION();
   374     CX_DEBUG_EXIT_FUNCTION();
   373 }
   375 }
   374 
   376 
   375 /*!
   377 /*!
   376 * Resets the video snapshot and current video filename
   378 * Resets the video snapshot and current video filename
   798 void CxeVideoCaptureControlSymbian::handleSnapshotReady(CxeError::Id status, const QImage &snapshot)
   800 void CxeVideoCaptureControlSymbian::handleSnapshotReady(CxeError::Id status, const QImage &snapshot)
   799 {
   801 {
   800     CX_DEBUG_ENTER_FUNCTION();
   802     CX_DEBUG_ENTER_FUNCTION();
   801 
   803 
   802     if (mCameraDeviceControl.mode() == Cxe::VideoMode) {
   804     if (mCameraDeviceControl.mode() == Cxe::VideoMode) {
       
   805         OstTrace0(camerax_performance, CXEVIDEOCAPTURECONTROL_HANDLESNAPSHOT_1, "msg: e_CX_HANDLE_SNAPSHOT 1");
       
   806 
   803         // Need to store snapshot for ui to be able to get it also later.
   807         // Need to store snapshot for ui to be able to get it also later.
   804         mSnapshot = QPixmap::fromImage(snapshot);
   808         mSnapshot = QPixmap::fromImage(snapshot);
   805         emit snapshotReady(status, snapshot, filename());
   809         emit snapshotReady(status, snapshot, filename());
       
   810 
       
   811         OstTrace0(camerax_performance, CXEVIDEOCAPTURECONTROL_HANDLESNAPSHOT_2, "msg: e_CX_HANDLE_SNAPSHOT 0");
   806     }
   812     }
   807 
   813 
   808     CX_DEBUG_EXIT_FUNCTION();
   814     CX_DEBUG_EXIT_FUNCTION();
   809 }
   815 }
   810 
   816