imagingandcamerafws/camerafw/Include/ecamconst.h
changeset 0 40261b775718
equal deleted inserted replaced
-1:000000000000 0:40261b775718
       
     1 // Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 /**
       
    17  @file
       
    18  @publishedPartner
       
    19  @released
       
    20 */
       
    21 #ifndef ECAM__CONST_H
       
    22 #define ECAM__CONST_H
       
    23 
       
    24 #ifdef SYMBIAN_ENABLE_SPLIT_HEADERS
       
    25 #include <ecamuidsconst.hrh>
       
    26 #endif
       
    27 /** 
       
    28 Event indicating continuous zoom progess. This event is used for StartContinuousZoomL feature. This is a part of class 
       
    29 CCamera::CCameraAdvancedSettings. This event should be packed in TECAMEvent2 class. 
       
    30 
       
    31 This TUid is available from the following methods only to the API clients using CCamera::New2L() or CCamera::
       
    32 NewDuplicate2L():
       
    33 void CCamera::CCameraAdvancedSettings::GetSupportedSettingsL(RArray<TUid>& aSettings) const;
       
    34 void CCamera::CCameraAdvancedSettings::GetActiveSettingsL(RArray<TUid>& aActiveSettings) const;
       
    35 void CCamera::CCameraAdvancedSettings::GetDisabledSettingsL(RArray<TUid>& aDisabledSettings) const;
       
    36 
       
    37 Note: TECAMEvent2::iParam represents percentage continuous zoom completion.
       
    38 
       
    39 @note  If zoom direction is EZoomDirectionWide, percentage completion will target minimum possible value as 100%.
       
    40 @note  If zoom direction is EZoomDirectionTele, percentage completion will target maximum possible value as 100%.
       
    41 
       
    42 @publishedPartner
       
    43 @prototype
       
    44 */
       
    45 static const TUid  KUidECamEvent2CameraSettingContinuousZoomPercentageCompletion  = {KUidECamEvent2CameraSettingContinuousZoomPercentageCompletionUidValue};
       
    46 
       
    47 /**
       
    48 Notifies that unrequested feature changes have occurred. The method GetIndirectFeatureChangesL() is called to
       
    49 retrieve the list of unrequested feature changes. The unrequested feature changes are ECAM component wide.
       
    50 
       
    51 This TUid is available from the following methods only to the API clients using CCamera::New2L() or CCamera::NewDuplicate2L():
       
    52 void CCamera::CCameraAdvancedSettings::GetSupportedSettingsL(RArray<TUid>& aSettings) const;
       
    53 void CCamera::CCameraAdvancedSettings::GetActiveSettingsL(RArray<TUid>& aActiveSettings) const;
       
    54 void CCamera::CCameraAdvancedSettings::GetDisabledSettingsL(RArray<TUid>& aDisabledSettings) const;
       
    55 
       
    56 Note: TECAMEvent2::iParam represents the TInt used to obtain a uid which represents the requested feature change.
       
    57 
       
    58 @publishedPartner
       
    59 @prototype
       
    60 */
       
    61 static const TUid KUidECamEvent2IndirectFeatureChange  = {KUidECamEvent2IndirectFeatureChangeUidValue};
       
    62 
       
    63 /**
       
    64 Event indicating auto aperture is being used.
       
    65 This event should be packed in TECAMEvent2 class.
       
    66 
       
    67 This TUid is available from the following methods only to the API clients using CCamera::New2L() or CCamera::
       
    68 NewDuplicate2L():
       
    69 void CCamera::CCameraAdvancedSettings::GetSupportedSettingsL(RArray<TUid>& aSettings) const;
       
    70 void CCamera::CCameraAdvancedSettings::GetActiveSettingsL(RArray<TUid>& aActiveSettings) const;
       
    71 void CCamera::CCameraAdvancedSettings::GetDisabledSettingsL(RArray<TUid>& aDisabledSettings) const;
       
    72 
       
    73 Note: TECAMEvent2::iParam represents actual value of aperture being used if camera is capable of. Otherwise, KErrNotFound will be retrieved.
       
    74 Note: This event is also used if exposure is set to CCamera::EExposureAuto or CCamera::EExposureShutterPriority.
       
    75 
       
    76 
       
    77 @publishedPartner
       
    78 @prototype
       
    79 */
       
    80 static const TUid  KUidECamEvent2CameraSettingAutoAperture  = {KUidECamEvent2CameraSettingAutoApertureUidValue};
       
    81 
       
    82 /** Specifies whether the camera is reserved or not.
       
    83 	The enumeration list may be extended in future.
       
    84 	
       
    85 @publishedPartner
       
    86 @prototype
       
    87 */
       
    88 enum TECamReserveStatus
       
    89 	{
       
    90 	/** Camera Status unknown */
       
    91 	ECameraStatusUnknown,
       
    92 	/** Camera is reserved */
       
    93 	ECameraReserved,
       
    94 	/** Camera is unreserved */
       
    95 	ECameraUnReserved
       
    96 	};
       
    97 
       
    98 /** Mixin base class for camera clients to handle the notification of Reserve status.
       
    99 
       
   100 Client must implement MReserveObserver in order to handle the notifications and take appropriate steps accordingly. 
       
   101 
       
   102 @note  By the time client gets unreserved status via callback, the camera may be on its way getting reserved by another client who 
       
   103 	   might be continuously polling for it.
       
   104 	   So, there is no guarantee that the client will be able to reserve it. But it is guaranteed that the client will
       
   105 	   receive the notification about change in reserve status. 
       
   106 
       
   107 @publishedPartner
       
   108 @prototype
       
   109 */
       
   110 class MReserveObserver
       
   111 	{
       
   112 public:
       
   113 	/**
       
   114 	This notification is send to provide the reserve status for the camera. 
       
   115 	
       
   116 	@param aCameraIndex
       
   117 		   The camera index for which the Reserve status has to be provided.
       
   118 		   
       
   119 	@param aReserveStatus
       
   120 		   The reserve status for the camera.
       
   121 		   
       
   122 	@param aErrorCode
       
   123 		   The error value. 
       
   124 		   
       
   125 	@note  If error is not KErrNone, then the client is expected to destroy the CCameraStatusWatch retrieved through 
       
   126 		   TReservedInfo::SubscribeReserveInfoL and re-subscribe if desired.
       
   127 	*/
       
   128 	virtual void ReserveStatus(TInt iCameraIndex, TECamReserveStatus aReserveStatus, TInt aErrorCode) =0;
       
   129 	};
       
   130 
       
   131 class CCameraStatusWatch;
       
   132 
       
   133 /**
       
   134 @publishedPartner
       
   135 @prototype
       
   136 
       
   137 Client uses it to asynchronously receive the reserve status of a camera index through MReserveObserver
       
   138 */
       
   139 class TReservedInfo
       
   140 	{
       
   141 public:
       
   142 	IMPORT_C static void SubscribeReserveInfoL(MReserveObserver& aReserveObserver, TInt aCameraIndex, CCameraStatusWatch*& aCameraStatusWatch); 
       
   143 	};
       
   144 
       
   145 /**
       
   146 This class is used to provide extra buffer informations through a custom interface.
       
   147 
       
   148 @see MCameraImageBuffer
       
   149 
       
   150 @publishedPartner
       
   151 @prototype
       
   152 */
       
   153 class MCameraBuffer2 : public MCameraBuffer
       
   154 	{
       
   155 public:
       
   156 	/**
       
   157 	Retrieves an array of uids which represents the class identifier used for buffer extension.
       
   158 	
       
   159 	@param aInterfaceUids
       
   160 		   An array of uids which represents the class identifier.
       
   161 		   
       
   162 	@return The error code.
       
   163 	*/
       
   164 	virtual TInt GetInterfaceUids(RArray<TUid>& aInterfaceUids) = 0;
       
   165 	
       
   166 	/**
       
   167 	Gets a custom interface for extra buffer information. 
       
   168 
       
   169 	@param aInterface
       
   170 		   The Uid of the particular interface function required for buffer information.
       
   171 		   
       
   172 	@param aPtrInterface
       
   173 		   The client has to cast the custom interface pointer to the appropriate type.	
       
   174 
       
   175 	@return The error code.
       
   176 	*/
       
   177 	virtual TInt CustomInterface(TUid aInterface, TAny*& aPtrInterface) = 0;
       
   178 	};
       
   179 	
       
   180 #endif // ECAM__CONST_H