equal
deleted
inserted
replaced
121 TPckgBuf<TCamParamsImage>* ptr = |
121 TPckgBuf<TCamParamsImage>* ptr = |
122 static_cast<TPckgBuf<TCamParamsImage>*>( aParamData ); |
122 static_cast<TPckgBuf<TCamParamsImage>*>( aParamData ); |
123 CheckNonNullL( ptr, KErrNotFound ); |
123 CheckNonNullL( ptr, KErrNotFound ); |
124 TCamParamsImage& params( (*ptr)() ); |
124 TCamParamsImage& params( (*ptr)() ); |
125 CCamAppUiBase* appUi = static_cast<CCamAppUiBase*>( CEikonEnv::Static()->AppUi() ); |
125 CCamAppUiBase* appUi = static_cast<CCamAppUiBase*>( CEikonEnv::Static()->AppUi() ); |
126 if ( appUi->ActiveCamera() == ECamActiveCameraSecondary ) |
126 |
127 { |
127 // Both primary and secondary camera use Exif format |
128 params.iFormat = CCamera::EFormatJpeg; |
128 params.iFormat = CCamera::EFormatExif; |
129 } |
129 |
130 else // primary camera |
|
131 { |
|
132 params.iFormat = CCamera::EFormatExif; |
|
133 } |
|
134 TCamPhotoSizeId PhotoSizeIndex = iSettingsModel->CurrentPhotoResolution(); |
130 TCamPhotoSizeId PhotoSizeIndex = iSettingsModel->CurrentPhotoResolution(); |
135 TSize PhotoSize = iSettingsModel->ImageResolutionFromIndex( PhotoSizeIndex ); |
131 TSize PhotoSize = iSettingsModel->ImageResolutionFromIndex( PhotoSizeIndex ); |
136 params.iSize = PhotoSize; |
132 params.iSize = PhotoSize; |
137 params.iQualityFactor = iSettingsModel->CurrentPhotoCompression(); |
133 params.iQualityFactor = iSettingsModel->CurrentPhotoCompression(); |
138 break; |
134 break; |
225 TDisplayMode displayMode = |
221 TDisplayMode displayMode = |
226 CEikonEnv::Static()->ScreenDevice()->DisplayMode(); |
222 CEikonEnv::Static()->ScreenDevice()->DisplayMode(); |
227 CCamera::TFormat viewfinderFormat = |
223 CCamera::TFormat viewfinderFormat = |
228 CCamSettingConversion::Map2CameraFormat( displayMode ); |
224 CCamSettingConversion::Map2CameraFormat( displayMode ); |
229 |
225 |
230 const TCamCameraMode cameraMode = iController.CurrentMode(); |
226 const TCamCameraMode cameraMode = |
|
227 ( appUi->TargetMode() != ECamControllerIdle) |
|
228 ? appUi->TargetMode() |
|
229 : iController.CurrentMode(); |
231 const TInt resolution = (cameraMode == ECamControllerVideo) |
230 const TInt resolution = (cameraMode == ECamControllerVideo) |
232 ? iController.GetCurrentVideoResolution() |
231 ? iController.GetCurrentVideoResolution() |
233 : iController.GetCurrentImageResolution(); |
232 : iController.GetCurrentImageResolution(); |
234 params.iRect = CamUtility::ViewfinderLayout( cameraMode, resolution ); |
233 params.iRect = CamUtility::ViewfinderLayout( cameraMode, resolution ); |
235 |
234 |