camerauis/cameraapp/generic/camerauiconfigmanager/inc/CameraUiConfigManager.h
changeset 19 d9aefe59d544
parent 3 8b2d6d0384b0
child 21 fa6d9f75d6a6
child 28 3075d9b614e6
equal deleted inserted replaced
3:8b2d6d0384b0 19:d9aefe59d544
     1 /*
       
     2 * Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies). 
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  CameraUiConfigManager API header.
       
    15  *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef CAMERAUICONFIGMANAGER_H
       
    20 #define CAMERAUICONFIGMANAGER_H
       
    21 
       
    22 // INCLUDES
       
    23 
       
    24 #include <eikenv.h>
       
    25 
       
    26 
       
    27 // Photo/Video scene information
       
    28 struct TSceneSettings
       
    29   {
       
    30   // Used for both image and video scene configuration.
       
    31   TInt iSupported;
       
    32   TInt iIdentifier;
       
    33   TInt iExposureMode;
       
    34   TInt iWhiteBalance;
       
    35   TInt iFlash;
       
    36   TInt iContrastMode;
       
    37   TInt iFocalDistance;
       
    38   /*
       
    39   * The following 3 only used for image mode. In Video mode, we ignore this
       
    40   */
       
    41   TInt iSharpnessMode; 
       
    42   TInt iLightSensitivityMode;
       
    43   TInt iExposureCompensationValue;
       
    44   /*
       
    45   * 0 -> Read from ICM or else.. take the frame rate defined here into use
       
    46   * only used in video. Ingored in image mode.
       
    47   */
       
    48   TInt iFrameRate;  
       
    49   };
       
    50 
       
    51 
       
    52 class CCameraUiConfigManagerImp;
       
    53 
       
    54 // CCameraUiConfigManager API 
       
    55 
       
    56 class CCameraUiConfigManager : public CBase
       
    57   {
       
    58   // =========================================================================
       
    59   public: // Constructors and destructor
       
    60   
       
    61         /**
       
    62         * Symbian two-phased constructor.
       
    63         * @since 2.8
       
    64         * @param aConfiguration    
       
    65         * engine changes.
       
    66         */
       
    67         IMPORT_C static CCameraUiConfigManager* NewLC();
       
    68       
       
    69         /**
       
    70         * Symbian two-phased constructor.
       
    71         * @since 2.8
       
    72         * @param aConfiguration    
       
    73         * engine changes.
       
    74         */
       
    75         IMPORT_C static CCameraUiConfigManager* NewL();
       
    76         
       
    77         /*
       
    78         * Constructor
       
    79         */
       
    80         CCameraUiConfigManager();
       
    81         
       
    82         /**
       
    83         * Destructor.
       
    84         */
       
    85         ~CCameraUiConfigManager();
       
    86     
       
    87  public:
       
    88  
       
    89         /*
       
    90         * Checking for Color feature support
       
    91         */
       
    92         IMPORT_C TBool IsColorToneFeatureSupported() const;
       
    93         
       
    94         /*
       
    95         * To check for sharpness feature support
       
    96         */
       
    97         IMPORT_C TBool IsSharpnessFeatureSupported() const;
       
    98         
       
    99         /*
       
   100         * To check for white balance feature support
       
   101         */
       
   102         IMPORT_C TBool IsWhiteBalanceFeatureSupported() const;
       
   103         
       
   104         /*
       
   105         * Secondary camera support
       
   106         */
       
   107         IMPORT_C TBool IsSecondaryCameraSupported() const;
       
   108         
       
   109         /*
       
   110         * Direct Screen View Finder feature support
       
   111         * aPrimaryCamera = ETrue ( Direct screen access support for primary camera )
       
   112         * aPrimaryCamera = EFalse ( Direct screen access support for secondary camera )
       
   113         */
       
   114         IMPORT_C TBool IsDSAViewFinderSupported( TBool aPrimaryCamera = ETrue ) const;
       
   115         
       
   116         /*
       
   117         * Lens cover feature support
       
   118         */
       
   119         IMPORT_C TBool IsLensCoverSupported() const;
       
   120         
       
   121         /*
       
   122         * Xenon flash feature support
       
   123         */
       
   124         IMPORT_C TBool IsXenonFlashSupported() const;
       
   125         
       
   126         /*
       
   127          * Light sensitivity feature support
       
   128         */
       
   129         IMPORT_C TBool IsISOSupported() const;
       
   130             
       
   131         /*
       
   132         * EV feature support
       
   133         */
       
   134         IMPORT_C TBool IsEVSupported() const;
       
   135         
       
   136         /*
       
   137         * Flash mode feature support
       
   138         */
       
   139         IMPORT_C TBool IsFlashModeSupported() const;
       
   140     
       
   141         
       
   142         /*
       
   143         * Contrast feature support
       
   144         */
       
   145         IMPORT_C TBool IsContrastSupported() const;
       
   146         
       
   147         /*
       
   148         * Brightness feature support
       
   149         */
       
   150         IMPORT_C TBool IsBrightnessSupported() const;
       
   151         
       
   152         
       
   153         /*
       
   154         * Flash mode feature support
       
   155         */
       
   156         IMPORT_C TBool IsExtendedLightSensitivitySupported() const;
       
   157         
       
   158         
       
   159         /*
       
   160         * One click upload feature support
       
   161         */
       
   162         IMPORT_C TBool IsOneClickUploadSupported() const;
       
   163         
       
   164         
       
   165         /*
       
   166         * Video Light feature support
       
   167         */
       
   168         IMPORT_C TBool IsVideoLightSupported() const;
       
   169         
       
   170         
       
   171         /*
       
   172         * Auto focus feature support
       
   173         */
       
   174         IMPORT_C TBool IsAutoFocusSupported() const;
       
   175     
       
   176         /*
       
   177         * Video Stabilization feature support
       
   178         */
       
   179         IMPORT_C TBool IsVideoStabilizationSupported() const;
       
   180         
       
   181         /*
       
   182         * Orientation sensor feature support
       
   183         */
       
   184         IMPORT_C TBool IsOrientationSensorSupported() const;
       
   185         
       
   186         /*
       
   187         * Face-tracking feature support
       
   188         */
       
   189         IMPORT_C TBool IsFaceTrackingSupported() const;
       
   190         
       
   191         /*
       
   192         * Optical joy stick feature support
       
   193         */
       
   194         IMPORT_C TBool IsOpticalJoyStickSupported() const;
       
   195 
       
   196         /*
       
   197         * location feature support
       
   198         */
       
   199         IMPORT_C TBool IsLocationSupported() const;
       
   200         
       
   201         /*
       
   202         * keywatcher feature support
       
   203         */
       
   204         IMPORT_C TBool IsKeyLockWatcherSupported() const;
       
   205         
       
   206         /*
       
   207         * Extended Digital Zoom feature support
       
   208         */
       
   209         IMPORT_C TBool IsExtendedDigitalZoomSupported() const;
       
   210 
       
   211         /*
       
   212         * MC photos support available
       
   213         */
       
   214         IMPORT_C TBool IsPhotosSupported() const;
       
   215 
       
   216         /*
       
   217         * Publish Zoom State support available
       
   218         */
       
   219         IMPORT_C TBool IsPublishZoomStateSupported() const;
       
   220         
       
   221         /*
       
   222         * EFalse = HW/Adapation sets AF to Hyperfocal during startup
       
   223         * ETrue  = Should be handled in UI
       
   224         */
       
   225         IMPORT_C TBool IsAutofocusSetInHyperfocalAtStartup() const;
       
   226 
       
   227         /*
       
   228         * Capture tone delay support available
       
   229         */
       
   230         IMPORT_C TBool IsCaptureToneDelaySupported() const;
       
   231 
       
   232         /*
       
   233         * UI Orientation Override feature support
       
   234         */
       
   235         IMPORT_C TBool IsUIOrientationOverrideSupported() const;
       
   236         
       
   237         /*
       
   238         * ThumbnailManager API feature support
       
   239         */
       
   240         IMPORT_C TBool IsThumbnailManagerAPISupported() const;
       
   241         
       
   242         /*
       
   243         * Capture tone delay in milliseconds.
       
   244         */
       
   245         IMPORT_C TInt CaptureToneDelay() const;
       
   246 
       
   247         /*
       
   248         * Required RAM memory for CameraApp
       
   249         */
       
   250         IMPORT_C TInt RequiredRamMemory() const;
       
   251         
       
   252         /*
       
   253         * Critical Level RAM memory for CameraApp
       
   254         */
       
   255         IMPORT_C TInt CriticalLevelRamMemory() const;
       
   256 
       
   257         /*
       
   258         * Required RAM memory for CameraApp when focus gained
       
   259         */
       
   260         IMPORT_C TInt RequiredRamMemoryFocusGained() const;
       
   261         
       
   262         /*
       
   263         * Critical Level RAM memory for CameraApp when focus gained
       
   264         */
       
   265         IMPORT_C TInt CriticalLevelRamMemoryFocusGained() const;
       
   266 
       
   267         /*
       
   268         *  To get all supported color tone setting items
       
   269         * aParam: aSupportedValues contain colortone setting enums supported by camera ui
       
   270         * check camsettings.hrh for supported enums in camera ui
       
   271         */
       
   272         IMPORT_C void SupportedColorToneSettingsL( RArray<TInt>& aSupportedValues );
       
   273         
       
   274         /*
       
   275         * To get all supported white balance setting items
       
   276         * aParam: aSupportedValues contain white balance setting enums supported by camera ui
       
   277         * check camsettings.hrh for supported enums in camera ui
       
   278         */
       
   279         IMPORT_C void SupportedWhiteBalanceSettingsL( 
       
   280                                     RArray<TInt>& aSupportedValues );
       
   281         
       
   282         /*
       
   283         * To get all supported Sharpness setting items
       
   284         * @aSupportedValues contains values ranging from MIN to MAX
       
   285         */
       
   286         IMPORT_C void SupportedSharpnessSettingsL( RArray<TInt>& aSupportedValues );
       
   287 
       
   288         /*
       
   289         * Primary Camera Zoom-In Keys
       
   290         * aParam: aSupportedValues will have key scan codes configured via cenrep
       
   291         */
       
   292         IMPORT_C void SupportedPrimaryCameraZoomInKeysL( RArray<TInt>& aSupportedValues );
       
   293     
       
   294         /*
       
   295         * Primary Camera Zoom-Out Keys
       
   296         * aParam: aSupportedValues will have key scan codes configured via cenrep
       
   297         */
       
   298         IMPORT_C void SupportedPrimaryCameraZoomOutKeysL( RArray<TInt>& aSupportedValues );
       
   299     
       
   300         /*
       
   301         * Secondary Camera Zoom-In Keys
       
   302         * aParam: aSupportedValues will have key scan codes configured via cenrep
       
   303         */
       
   304         IMPORT_C void SupportedSecondaryCameraZoomInKeysL( RArray<TInt>& aSupportedValues );
       
   305     
       
   306         /*
       
   307         * Secondary Camera Zoom-Out Keys
       
   308         * aParam: aSupportedValues will have key scan codes configured via cenrep
       
   309         */
       
   310         IMPORT_C void SupportedSecondaryCameraZoomOutKeysL( RArray<TInt>& aSupportedValues );
       
   311         
       
   312         /*
       
   313         * EV compensation supported settings
       
   314         * aSupportedValues contains the complete range of EV settings from MIN to MAX
       
   315         * @e.g. -2,2,10 ( aSupportedValues[0] = MIN,
       
   316         *                 aSupportedValues[1] = MAX,
       
   317         *                 aSupportedValues[2] = Steps )
       
   318         */
       
   319         IMPORT_C void SupportedEVSettingsL( RArray<TInt>& aSupportedValues );
       
   320     
       
   321     
       
   322         /*
       
   323         * Flash mode setting items
       
   324         * aParam: aSupportedValues contain flash mode enums supported by camera ui
       
   325         * check camsettings.hrh for supported enums in camera ui
       
   326         */
       
   327         IMPORT_C void SupportedFlashModeSettingsL( RArray<TInt>& aSupportedValues );
       
   328 
       
   329         
       
   330         /*
       
   331         * Primary camera capture key
       
   332         * aParam: aSupportedValues will have key mappings for capture key
       
   333         */
       
   334         IMPORT_C void SupportedPrimaryCameraCaptureKeyL( RArray<TInt>& aSupportedValues );
       
   335     
       
   336         /*
       
   337         * Secondary camera capture key
       
   338         * aParam: aSupportedValues will have key mappings for capture key
       
   339         */
       
   340         IMPORT_C void SupportedSecondaryCameraCaptureKeyL( RArray<TInt>& aSupportedValues );
       
   341         
       
   342         /*
       
   343         * Primary camera AF key
       
   344         * aParam: aSupportedValues will have key mappings for Autofocus key
       
   345         */
       
   346         IMPORT_C void SupportedPrimaryCameraAutoFocusKeyL( RArray<TInt>& aSupportedValues );
       
   347     
       
   348         /*
       
   349         * Secondary camera AutoFocus key
       
   350         * aParam: aSupportedValues will have key mappings for Autofocus key
       
   351         */
       
   352         IMPORT_C void SupportedSecondaryCameraAutoFocusKeyL( RArray<TInt>& aSupportedValues );
       
   353         
       
   354         /*
       
   355         * Supported contrast setting range values
       
   356         * aParam: aSupportedValues will have contrast values ranging 
       
   357         * from MIN - MAX and step size
       
   358         * aSupportedValues[0] -> MIN value
       
   359         * aSupportedValues[1] -> MAX value
       
   360         * aSupportedValues[2] -> Steps
       
   361         */
       
   362         IMPORT_C void SupportedContrastRangeL( RArray<TInt>& aSupportedValues );
       
   363         
       
   364         /*
       
   365         * Supported brightness setting range values
       
   366         * aParam: aSupportedValues will have brightness values ranging 
       
   367         * from MIN - MAX and step size
       
   368         * aSupportedValues[0] -> MIN value
       
   369         * aSupportedValues[1] -> MAX value
       
   370         * aSupportedValues[2] -> Steps
       
   371         */
       
   372         IMPORT_C void SupportedBrightnessRangeL( RArray<TInt>& aSupportedValues );
       
   373         
       
   374         /*
       
   375         *  To get all supported Max Zoom steps for all Image, Video resoultions for
       
   376         *  primary and second camera
       
   377         *  @ aSupportedValues[ 0] -> KMaxPhoto8MPZoomStep
       
   378         *  @ aSupportedValues[ 1] -> KMaxPhoto5MPZoomStep
       
   379         *  @ aSupportedValues[ 2] -> KMaxPhoto3MPZoomStep
       
   380         *  @ aSupportedValues[ 3] -> KMaxPhoto2MPZoomStep
       
   381         *  @ aSupportedValues[ 4] -> KMaxPhoto1_3MPZoomStep
       
   382         *  @ aSupportedValues[ 5] -> KMaxPhoto1MPZoomStep
       
   383         *  @ aSupportedValues[ 6] -> KMaxPhoto08MPZoomStep
       
   384         *  @ aSupportedValues[ 7] -> ?? no constant in UI
       
   385         *  @ aSupportedValues[ 8] -> KMaxPhotoVGAZoomStep
       
   386         *  @ aSupportedValues[ 9] -> KMaxVideoZoomStepHD
       
   387         *  @ aSupportedValues[10] -> KMaxVideoZoomStepWVGA
       
   388         *  @ aSupportedValues[11] -> KMaxVideoZoomStepNHD
       
   389         *  @ aSupportedValues[12] -> KMaxVideoZoomStepVGA
       
   390         *  @ aSupportedValues[13] -> KMaxVideoZoomStepQVGA
       
   391         *  @ aSupportedValues[14] -> KMaxVideoZoomStepCIF
       
   392         *  @ aSupportedValues[15] -> KMaxVideoZoomStepQCIF
       
   393         *  @ aSupportedValues[16] -> iMaxVideoStepSQCIF
       
   394         *  @ aSupportedValues[17] -> KMax2ndCamPhotoStep
       
   395         *  @ aSupportedValues[18] -> KMax2ndCamVideoStepCIF
       
   396         *  @ aSupportedValues[19] -> KMax2ndCamVideoStepQCIF
       
   397         *  @ aSupportedValues[20] -> iMax2ndCamVideoStepSQCIF
       
   398         */
       
   399         IMPORT_C void SupportedMaxZoomStepsL( RArray<TInt>& aSupportedValues );
       
   400         
       
   401         /*
       
   402         * To get all supported photo specific MAX extended zoom steps w.r.t all photo
       
   403         * resoultions ( only for main camera for now )
       
   404         * aSupportedValues[0] -> 5MP max ext-zoom step
       
   405         * aSupportedValues[n] -> lowest resolution for main camera MAX ext-zoom step
       
   406         */
       
   407         IMPORT_C void SupportedMaxExtendedZoomStepsL( 
       
   408                                     RArray<TInt>& aSupportedValues );
       
   409         /*
       
   410         * Supported zoom bar Look and Feel ( LAF ) values
       
   411         * @aSupportedValues[0] -> Time per zoom tick in milliseconds
       
   412         * @aSupportedValues[1] -> Time per extended zoom tick in milliseconds 
       
   413         * @aSupportedValues[2] -> No of zoom steps per tick
       
   414         * @aSupportedValues[3] -> No of extended zoom steps per tick 
       
   415         * @aSupportedValues[4] -> Secondary camera zoom steps per tick
       
   416         */
       
   417         IMPORT_C void SupportedLAFZoomBarL( 
       
   418                                     RArray<TInt>& aSupportedValues );
       
   419         
       
   420         /*
       
   421         * Supported Image Scene modes and Scene specific settings
       
   422         */
       
   423         IMPORT_C void SupportedSceneModesAndSettingsL( 
       
   424                                RArray<TSceneSettings>& aSupportedValues,
       
   425                                TBool aPhotoScene = ETrue );
       
   426 
       
   427         /*
       
   428         * Determines device qwerty-mode state.
       
   429         * This method is meant to be used with secondary camera.
       
   430         * @return ETrue if qwerty keyboard is open
       
   431         */
       
   432         IMPORT_C TInt IsQwerty2ndCamera() const;  
       
   433 
       
   434         /*
       
   435         * Burst file size estimate correction factor
       
   436         * in percent (100 = 100%).
       
   437         * @return correction factor in percent
       
   438         */        
       
   439         IMPORT_C TInt BurstFileSizeEstimateFactor() const;       
       
   440         
       
   441         /*
       
   442         * @aSupportedValues[0] -> Value for iCamZoomCooldown
       
   443         * @aSupportedValues[1] -> Value for iCamMaxZoomCooldown
       
   444         */
       
   445         IMPORT_C void SupportedZoomDelaysL( 
       
   446                                     RArray<TInt>& aSupportedValues );
       
   447         /*
       
   448          * BurstMode Support
       
   449          */
       
   450         IMPORT_C TBool IsBurstModeSupported() const; 
       
   451 		
       
   452 		 /*
       
   453         * Continuous autofocus. 
       
   454         * @return ETrue if continuous autofocus feature is enabled
       
   455         */
       
   456         IMPORT_C TBool IsContinuosAutofocusSupported() const; 
       
   457         /*
       
   458         * @aSupportedValues[0] -> Value for iLandscapeScreenMode
       
   459         * @aSupportedValues[1] -> Value for iPortraitScreenmode
       
   460         */
       
   461         IMPORT_C void SupportedScreenModesL( 
       
   462                                     RArray<TInt>& aSupportedValues );
       
   463 
       
   464  private:
       
   465         void ConstructL();
       
   466   
       
   467  private:
       
   468  
       
   469         CCameraUiConfigManagerImp* iConfigManagerImp;
       
   470 };
       
   471 
       
   472 #endif // CAMERAUICONFIGMANAGER_H
       
   473 
       
   474 // End of File