sl@0: // Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). sl@0: // All rights reserved. sl@0: // This component and the accompanying materials are made available sl@0: // under the terms of "Eclipse Public License v1.0" sl@0: // which accompanies this distribution, and is available sl@0: // at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: // sl@0: // Initial Contributors: sl@0: // Nokia Corporation - initial contribution. sl@0: // sl@0: // Contributors: sl@0: // sl@0: // Description: sl@0: // sl@0: sl@0: /** sl@0: @file sl@0: @publishedAll sl@0: @released sl@0: */ sl@0: #ifndef ECAMIMAGEPROCESSING_H sl@0: #define ECAMIMAGEPROCESSING_H sl@0: sl@0: #include <e32base.h> sl@0: #include <gdi.h> sl@0: #include <ecam.h> sl@0: #include <ecamadvsettingsuids.hrh> sl@0: #include <ecam/ecamconstants.h> sl@0: sl@0: #ifndef SYMBIAN_ENABLE_SPLIT_HEADERS sl@0: #include <ecamimageprocessingconst.h> sl@0: #include <ecamimageprocessingdef.h> sl@0: #endif sl@0: sl@0: sl@0: class MCameraImageProcessing; sl@0: class MCameraImageProcessing2; sl@0: class MCameraImageProcessing3; sl@0: sl@0: class MImplementationFactory; sl@0: sl@0: /** sl@0: The current Version of the TColorOperationCapabilities class. sl@0: sl@0: */ sl@0: static const TUint KECamColorOperationCapabilitiesCurrentVersion = 1; sl@0: sl@0: /** sl@0: The current Version of the TBitsIgnore class. sl@0: sl@0: */ sl@0: static const TUint KECamBitsIgnoreCurrentVersion = 1; sl@0: sl@0: /** sl@0: The current Version of the TColorOperationEntry class. sl@0: sl@0: */ sl@0: static const TUint KECamColorOperationEntryCurrentVersion = 1; sl@0: sl@0: sl@0: /* General purpose constants */ sl@0: sl@0: /** sl@0: Uid used to identify the CCamera Post Processing API. sl@0: Such image operations are performed on the acquired image by the camera itself. sl@0: @see CCamera::CCameraPresets sl@0: */ sl@0: static const TUid KECamImageProcessingUid = {KECamImageProcessingUidValue}; sl@0: sl@0: /** Transformations */ sl@0: /* Adjustments */ sl@0: /** Brightness adjustment - recognized range [-100:100] */ sl@0: static const TUid KUidECamEventImageProcessingAdjustBrightness = {KUidECamEventImageProcessingAdjustBrightnessUidValue}; sl@0: /** Contrast adjustment - recognized range [-100:100] */ sl@0: static const TUid KUidECamEventImageProcessingAdjustContrast = {KUidECamEventImageProcessingAdjustContrastUidValue}; sl@0: /** Gamma adjustment - recognized range [0:1000] */ sl@0: static const TUid KUidECamEventImageProcessingAdjustGamma = {KUidECamEventImageProcessingAdjustGammaUidValue}; sl@0: /** Sharpness adjustment - recognized range [-100:100] */ sl@0: static const TUid KUidECamEventImageProcessingAdjustSharpness = {KUidECamEventImageProcessingAdjustSharpnessUidValue}; sl@0: /** Saturation adjustment - recognized range [-100:100] */ sl@0: static const TUid KUidECamEventtImageProcessingAdjustSaturation = {KUidECamEventtImageProcessingAdjustSaturationUidValue}; sl@0: static const TUid KUidECamEventImageProcessingAdjustSaturation = {KUidECamEventtImageProcessingAdjustSaturationUidValue}; sl@0: /** Hue adjustment - recognized range [-100:100] */ sl@0: static const TUid KUidECamEventtImageProcessingAdjustHue = {KUidECamEventtImageProcessingAdjustHueUidValue}; sl@0: static const TUid KUidECamEventImageProcessingAdjustHue = {KUidECamEventtImageProcessingAdjustHueUidValue}; sl@0: sl@0: sl@0: /** Effect value */ sl@0: static const TUid KUidECamEventImageProcessingEffect = {KUidECamEventImageProcessingEffectUidValue}; sl@0: sl@0: /* Transforms */ sl@0: /** Crop */ sl@0: static const TUid KUidECamEventImageProcessingTransformCrop = {KUidECamEventImageProcessingTransformCropUidValue}; sl@0: /** Rotation */ sl@0: static const TUid KUidECamEventImageProcessingTransformRotate = {KUidECamEventImageProcessingTransformRotateUidValue}; sl@0: /** Mirroring */ sl@0: static const TUid KUidECamEventImageProcessingTransformMirror = {KUidECamEventImageProcessingTransformMirrorUidValue}; sl@0: /** Rescale */ sl@0: static const TUid KUidECamEventImageProcessingTransformScale = {KUidECamEventImageProcessingTransformScaleUidValue}; sl@0: /** origin subset */ sl@0: static const TUid KUidECamEventImageProcessingSourceRect = {KUidECamEventImageProcessingSourceRectUidValue}; sl@0: /** Noise reduction */ sl@0: static const TUid KUidECamEventImageProcessingNoiseReduction = {KUidECamEventImageProcessingNoiseReductionUidValue}; sl@0: /** Glare removal */ sl@0: static const TUid KUidECamEventImageProcessingGlareRemoval = {KUidECamEventImageProcessingGlareRemovalUidValue}; sl@0: sl@0: /** Default value for image processing */ sl@0: static const TInt KECamImageProcessingDefaultValue = 0; sl@0: sl@0: /** sl@0: Uid used to indicate completion of StartColorSwap sl@0: sl@0: */ sl@0: static const TUid KUidECamEventCIPStartColorSwap = {KUidECamEventCIPStartColorSwapUidValue}; sl@0: sl@0: /** sl@0: Uid used to indicate completion of StartColorAccent sl@0: sl@0: */ sl@0: static const TUid KUidECamEventCIPStartColorAccent = {KUidECamEventCIPStartColorAccentUidValue}; sl@0: sl@0: sl@0: /** sl@0: This class is used to perform image processing operations on the camera. sl@0: These include brightness, contrast, gamma, hue, sharpness and saturation adjustments. The client is also sl@0: able to perform simple image transformations like cropping, rotation, mirroring, scaling, noise reduction and glare reduction. . sl@0: When an operation selection is complete, all clients are notified with the respective event UID. sl@0: sl@0: As often cameras may support only a subset of discrete values of the allowed range, sl@0: the API allows the client to retrieve those and use them explicitly. sl@0: sl@0: @note This class is not intended for sub-classing and used to standardise existing sl@0: varieties of implementations. sl@0: sl@0: @note it is assumed that setting a new value for a transformations(transform, adjust, effect) effectively sl@0: activates the transformations. Whilst for effects and adjustments there is always a value, transforms sl@0: may have a dependency on other parameters and sl@0: crop - requires setting of source rectangle. sl@0: scale - will use setting of source rectangle, and the magnification factor is sl@0: determined by the source rectangle and the output size. This is always magnification. sl@0: if a value is set, it is assumed to be a scaling factor multiplied by KECamFineResolutionFactor sl@0: and set to integer. sl@0: mirror - values of TMirror type. sl@0: rotation - the angle in degrees. sl@0: noise reduction - TNoiseReduction. sl@0: glare removal - TGlareReduction. sl@0: sl@0: Example sl@0: sl@0: @code sl@0: // Lets assume that an application would need to check whether gamma correction is sl@0: // supported on a particular platform. After obtaining a valid pointer to the interface, sl@0: // it would call GetSupportedTransformationsL() to obtain the list of the supported sl@0: // transformations and check whether KUidECamEventImageProcessingAdjustGamma sl@0: // is in the list. If it is then call SetTranformationValue(KUidECamEventImageProcessingAdjustGamma, 200); sl@0: // to set the new value. A notification will be generated to the client to indicate success. sl@0: sl@0: RArray<TUid> suppTransforms; // array of supported transformations sl@0: CleanupClosePushL(suppTransforms); sl@0: sl@0: imageProcess->GetSupportedTransformationsL(suppTransfUids); sl@0: ... sl@0: // if the gamma is supported sl@0: TInt gammaCorrection = 200; // gamma correction of 2.0 sl@0: imageProcess->SetTranformationValue(KUidECamEventImageProcessingAdjustGamma, gammaCorrection); sl@0: ... sl@0: // pop stack to close the RArray sl@0: @endcode sl@0: sl@0: @note If the class methods leave, the output type parameter value is not guaranteed to be valid. sl@0: sl@0: @publishedAll sl@0: @released sl@0: */ sl@0: class CCamera::CCameraImageProcessing : public CBase sl@0: { sl@0: sl@0: // so can use internal factory functions etc. sl@0: friend class CCamera; sl@0: sl@0: public: sl@0: sl@0: /** Gamma settings */ sl@0: enum TGamma sl@0: { sl@0: /** Sets the gamma adjustment automatically. */ sl@0: EGammaAuto = KMinTInt sl@0: }; sl@0: /** Sharpness Settings */ sl@0: enum TSharpness sl@0: { sl@0: /** Sets the sharpness adjustment automatically. */ sl@0: ESharpnessAuto = KMinTInt sl@0: }; sl@0: /** Saturation Settings */ sl@0: enum TSaturation sl@0: { sl@0: /** Sets the saturation adjustment automatically. */ sl@0: ESaturationAuto = KMinTInt sl@0: }; sl@0: /** Hue Settings */ sl@0: enum THue sl@0: { sl@0: /** Sets the hue adjustment automatically. */ sl@0: EHueAuto = KMinTInt sl@0: }; sl@0: sl@0: /** Settings for the supported effects */ sl@0: enum TEffect sl@0: { sl@0: /** Effects off is default, always supported */ sl@0: EEffectNone = 0x00000000, sl@0: /** Negative visual effect. */ sl@0: EEffectNegative = 0x00000001, sl@0: /** Black and white visual effect. */ sl@0: EEffectMonochrome = 0x00000002, sl@0: /** Solarization visual effect. */ sl@0: EEffectSolarize = 0x00000004, sl@0: /** Sepia visual effect. */ sl@0: EEffectSepia = 0x00000008, sl@0: /** Emboss visual effect. */ sl@0: EEffectEmboss = 0x00000010, sl@0: /** Red eye glare reduction visual effect. */ sl@0: EEffectRedEyeReduction = 0x00000020, sl@0: /** Vivid colour visual effect. */ sl@0: EEffectVivid = 0x00000040, sl@0: /** Neutral colour visual effect. */ sl@0: EEffectNeutral = 0x00000080, sl@0: /** Selective sharpening visual effect. */ sl@0: EEffectLowSharpening = 0x00000100, sl@0: /** sl@0: Natural visual effect. sl@0: sl@0: This enum value is available from the 'supported' or 'getter' methods only to the API clients using CCamera::New2L() or sl@0: CCamera::NewDuplicate2L(). sl@0: sl@0: */ sl@0: EEffectNatural = 0x00000200, sl@0: /** sl@0: Cine visual effect. sl@0: sl@0: This enum value is available from the 'supported' or 'getter' methods only to the API clients using CCamera::New2L() or sl@0: CCamera::NewDuplicate2L(). sl@0: sl@0: */ sl@0: EEffectCine = 0x00000400, sl@0: /** sl@0: Old film visual effect. sl@0: sl@0: This enum value is available from the 'supported' or 'getter' methods only to the API clients using CCamera::New2L() or sl@0: CCamera::NewDuplicate2L(). sl@0: sl@0: */ sl@0: EEffectOldFilm = 0x00000800, sl@0: /** sl@0: Color swap visual effect. sl@0: sl@0: This enum value is available from the 'supported' or 'getter' methods only to the API clients using CCamera::New2L() or sl@0: CCamera::NewDuplicate2L(). sl@0: sl@0: */ sl@0: EEffectColorSwap = 0x00001000, sl@0: /** sl@0: Where a list of color can be kept as they are and the rest converted to gray. sl@0: sl@0: This enum value is available from the 'supported' or 'getter' methods only to the API clients using CCamera::New2L() or sl@0: CCamera::NewDuplicate2L(). sl@0: sl@0: */ sl@0: EEffectColorAccent = 0x00002000 sl@0: }; sl@0: sl@0: /** Mirror settings */ sl@0: enum TMirror sl@0: { sl@0: /** Default value. Mirroring is disabled. */ sl@0: EMirrorNone = 0x00000000, sl@0: /** Mirror along horizontal axis. */ sl@0: EMirrorHorizontal = 0x00000001, sl@0: /** Mirror along vertical axis. */ sl@0: EMirrorVertical = 0x00000002, sl@0: /** Mirror along horizontal and vertical axis. */ sl@0: EMirrorBoth = 0x00000003 sl@0: }; sl@0: sl@0: /** Noise filter settings */ sl@0: enum TNoiseReduction sl@0: { sl@0: /** Default value. Noise reduction disabled. */ sl@0: ENoiseReductionNone = 0x0000, sl@0: /** most basic noise reduction. */ sl@0: ENoiseReductionBasic = 0x0001 sl@0: }; sl@0: sl@0: /** Glare reduction settings */ sl@0: enum TGlareReduction sl@0: { sl@0: /** Default value. Glare reduction disabled. */ sl@0: EGlareReductionNone = 0x0000, sl@0: /** most basic glare reduction. */ sl@0: EGlareReductionBasic = 0x0001 sl@0: }; sl@0: sl@0: /** sl@0: Used for color swap and color accent feature in TEffect. It describes whether the given source sl@0: or target color represents itself or a group of color. sl@0: sl@0: */ sl@0: enum TColorOperationRepresentation sl@0: { sl@0: /** Feature is not supported */ sl@0: ERepresentationNone = 0x00, sl@0: /** The given color is uniquely represented */ sl@0: ERepresentationSingle = 0x01, sl@0: /** The given color represents a group of colors */ sl@0: ERepresentationMultiple = 0x02 sl@0: }; sl@0: sl@0: /** sl@0: Used for color swap and color accent feature in TEffect. It describes the type of grouping for sl@0: source and target colors when they represent a group of color. sl@0: sl@0: */ sl@0: enum TColorOperationRgbGroupingMode sl@0: { sl@0: /** Feature is not supported */ sl@0: ERgbGroupingNone = 0x00, sl@0: /** This means no neighbourhood colors are considered */ sl@0: ERgbGroupingFixed = 0x01, sl@0: /** This means neighbourhood colors are to be automatically decided by the implementation or hardware */ sl@0: ERgbGroupingAutomatic = 0x02, sl@0: /** This means neighbourhood colors for source have to be decided by ignoring few starting bits. Used for source only */ sl@0: ERgbGroupingSignificantBits = 0x04, sl@0: /** This means colors in target are obtained as some uniform proportion using source. Used for target only */ sl@0: ERgbGroupingUniform = 0x08 sl@0: }; sl@0: sl@0: /** sl@0: Used to provide different types of references for orientation of images retrieved. These references are the various sl@0: means by the orientation of an image can be defined. Client needs to choose a particular TOrientationReference and sl@0: specify any relative rotation, mirroring and flipping on top of it. sl@0: sl@0: This enumeration has nothing to do with absolute rotation. Uid KUidECamEventImageProcessingTransformRotate is used sl@0: for absolute rotation purposes. sl@0: sl@0: The enumeration list may be extended in future. sl@0: sl@0: @publishedPartner sl@0: @prototype sl@0: */ sl@0: enum TOrientationReference sl@0: { sl@0: /** The retrieved images will follow the camera sensor orientation. This orientation would be relative sl@0: to the current screen mode as given by the reference screen. */ sl@0: EOrientationReferenceCameraSensorOrientation, sl@0: sl@0: /** The retrieved images will get oriented as per the tilt sensor information. sl@0: So,the orientation would be relative to the current screen mode as given by the reference screen. */ sl@0: EOrientationReferenceTiltOrientation sl@0: }; sl@0: sl@0: /** sl@0: Used to describe the various relative rotation. The term 'relative' means that the rotation is applied after the sl@0: image undergoes orientation as given by TOrientationReference. sl@0: sl@0: The enumeration list may be extended in future. sl@0: sl@0: @publishedPartner sl@0: @prototype sl@0: */ sl@0: enum TRelativeRotation sl@0: { sl@0: /** Zero degree Rotation applied on top of orientation reference and is relative to current reference screen. */ sl@0: ERelativeRotation0Degrees = 0x00, sl@0: /** 90 degree clockwise Rotation applied on top of orientation reference and is relative to current reference screen. */ sl@0: ERelativeRotation90DegreesClockwise = 0x01, sl@0: /** 180 degree clockwise Rotation applied on top of orientation reference and is relative to current reference screen. */ sl@0: ERelativeRotation180DegreesClockwise = 0x02, sl@0: /** 270 degree clockwise Rotation applied on top of orientation reference and is relative to current reference screen. */ sl@0: ERelativeRotation270DegreesClockwise = 0x04 sl@0: }; sl@0: sl@0: /** sl@0: Used to describe the various relative mirroring. The term 'relative' means that the mirroring is applied after the sl@0: image undergoes orientation as given by TOrientationReference. sl@0: sl@0: The enumeration list may be extended in future. sl@0: sl@0: @publishedPartner sl@0: @prototype sl@0: */ sl@0: enum TRelativeMirror sl@0: { sl@0: /** No mirroring. */ sl@0: ERelativeMirrorNone = 0x00, sl@0: /** Used to mirror an image about the horizontal axis. This is applied on top of orientation reference and is sl@0: relative to current reference screen. */ sl@0: ERelativeMirrorHorizontalAxis = 0x10, sl@0: /** Used to mirror an image about the vertical axis. This is applied on top of orientation reference and is sl@0: relative to current reference screen. */ sl@0: ERelativeMirrorVerticalAxis = 0x20 sl@0: }; sl@0: sl@0: /** sl@0: Used to describe the various relative flipping. The term 'relative' means that the flipping is applied after the sl@0: image undergoes orientation as given by TOrientationReference. sl@0: sl@0: The enumeration list may be extended in future. sl@0: sl@0: @publishedPartner sl@0: @prototype sl@0: */ sl@0: enum TRelativeFlipping sl@0: { sl@0: /** No flipping. */ sl@0: ERelativeFlippingNone = 0x00, sl@0: /** Used to flip an image horizontally. This is applied on top of orientation reference and is relative to current sl@0: reference screen. */ sl@0: ERelativeFlippingHorizontal = 0x10, sl@0: /** Used to flip an image vertically. This is applied on top of orientation reference and is relative to current sl@0: reference screen. */ sl@0: ERelativeFlippingVertical = 0x20 sl@0: }; sl@0: sl@0: /** sl@0: Different types of contrast enhancement options. sl@0: The enumeration list may be extended in future. sl@0: sl@0: @publishedPartner sl@0: @prototype sl@0: */ sl@0: enum TContrastEnhancement sl@0: { sl@0: /** Not Supported. */ sl@0: EContrastEnhancementNone =0x00, sl@0: /** Contrast Enhancement switched off. */ sl@0: EContrastEnhancementSwitchOff =0x01, sl@0: /** Contrast Enhacement switched On manually. */ sl@0: EContrastEnhancementManualSwitchOn =0x02, sl@0: /** Contrast Enhancement in auto mode. */ sl@0: EContrastEnhancementSwitchAuto =0x04 sl@0: }; sl@0: sl@0: /** sl@0: Different types of software-based red eye reduction options. sl@0: The enumeration list may be extended in future. sl@0: sl@0: @publishedPartner sl@0: @prototype sl@0: */ sl@0: enum TRedEyeReduction sl@0: { sl@0: /** Not Supported. */ sl@0: ERedEyeReductionNone =0x00, sl@0: /** Software based Red Eye Reduction can be switched off(disabled). */ sl@0: ERedEyeReductionSwitchOff =0x01, sl@0: /** Software based Red Eye Reduction can be switched on (enabled). */ sl@0: ERedEyeReductionManualSwitchOn =0x02, sl@0: /** Software based Red Eye Reduction can be put to auto mode. */ sl@0: ERedEyeReductionSwitchAuto =0x04 sl@0: }; sl@0: sl@0: /** sl@0: Color operation capabilities characterizing both color swap and color accent feature sl@0: sl@0: */ sl@0: class TColorOperationCapabilities sl@0: { sl@0: public: sl@0: /** sl@0: Constructor. sl@0: Sets the size of this class in iSize. sl@0: */ sl@0: IMPORT_C TColorOperationCapabilities(); sl@0: sl@0: IMPORT_C TInt Size() const; sl@0: IMPORT_C TUint Version() const; sl@0: sl@0: private: sl@0: //for future expansion sl@0: TUint iSize:24; sl@0: TUint iVersion:8; sl@0: sl@0: // reserved for future expansion sl@0: TInt iReserved; sl@0: sl@0: public: sl@0: /** The source color representation that the server supports. sl@0: The supported representations are held as a bitwise logical OR of the relevant individual modes sl@0: defined in CCamera::CCameraImageProcessing:: TColorOperationRepresentation. */ sl@0: TUint iSupportedSourceRepresentation; sl@0: sl@0: /** The target color representation that the server supports. sl@0: The supported representations are held as a bitwise logical OR of the relevant individual modes sl@0: defined in CCamera::CCameraImageProcessing:: TColorOperationRepresentation. sl@0: Not applicable for color accent */ sl@0: TUint iSupportedTargetRepresentation; sl@0: sl@0: /** The source color Rgb grouping modes that the server supports. sl@0: The modes are held as a bitwise logical OR of the relevant individual modes sl@0: defined in CCamera::CCameraImageProcessing:: TColorOperationRgbGroupingMode. */ sl@0: TUint iSupportedSourceRgbGroupingMode; sl@0: sl@0: /** The target color Rgb grouping modes that the server supports. sl@0: The modes are held as a bitwise logical OR of the relevant individual modes sl@0: defined in CCamera::CCameraImageProcessing:: TColorOperationRgbGroupingMode. sl@0: Not applicable for color accent */ sl@0: TUint iSupportedTargetRgbGroupingMode; sl@0: sl@0: /** This indicates whether the mapping mode and Rgb grouping mode uniform for every color entry */ sl@0: TBool iIsCapabilityUniform; sl@0: }; sl@0: sl@0: /** sl@0: Class used to control the number of bits to ignore for Red, Green, Blue or Alpha. sl@0: This may be used when deciding for neighbourhood for source color in case of color swap and color accent feature sl@0: sl@0: */ sl@0: class TBitsIgnore sl@0: { sl@0: public: sl@0: /** sl@0: Constructor. sl@0: Sets the size of this class in iSize. sl@0: */ sl@0: IMPORT_C TBitsIgnore(); sl@0: sl@0: IMPORT_C TInt Size() const; sl@0: IMPORT_C TUint Version() const; sl@0: sl@0: private: sl@0: //for future expansion sl@0: TUint iSize:24; sl@0: TUint iVersion:8; sl@0: sl@0: // for future use sl@0: TUint iReservedBits:16; sl@0: sl@0: public: sl@0: /** This gives the no. of bits to ignore for Red color. Varies from 0 to 8. sl@0: Any other value should be an error */ sl@0: TUint iRedBitsIgnore:4; sl@0: sl@0: /** This gives the no. of bits to ignore for Green color. Varies from 0 to 8. sl@0: Any other value should be an error */ sl@0: TUint iGreenBitsIgnore:4; sl@0: sl@0: /** This gives the no. of bits to ignore for Blue color. Varies from 0 to 8. sl@0: Any other value should be an error */ sl@0: TUint iBlueBitsIgnore:4; sl@0: sl@0: /** This gives the no. of bits to ignore for Alpha. Varies from 0 to 8. sl@0: Any other value should be an error */ sl@0: TUint iAlphaBitsIgnore:4; sl@0: }; sl@0: sl@0: /** sl@0: Color operation parameters characterizing both color swap and color accent feature; and for a particular entry. sl@0: sl@0: */ sl@0: class TColorOperationEntry sl@0: { sl@0: public: sl@0: /** sl@0: Constructor. sl@0: Sets the size of this class in iSize. sl@0: */ sl@0: IMPORT_C TColorOperationEntry(); sl@0: sl@0: IMPORT_C TInt Size() const; sl@0: IMPORT_C TUint Version() const; sl@0: sl@0: private: sl@0: //for future expansion sl@0: TUint iSize:24; sl@0: TUint iVersion:8; sl@0: sl@0: // reserved for future expansion sl@0: TInt iReserved; sl@0: sl@0: public: sl@0: /** The source color (rgb triplet) which is changed to target color in case of Color Swap operation sl@0: and remains unaffected in case of Color Accent operation */ sl@0: TRgb iSourceColor; sl@0: sl@0: /** The target color (rgb triplet) which replaces the source color in case of Color Swap operation. sl@0: Redundant for Color Accent operation */ sl@0: TRgb iTargetColor; sl@0: sl@0: /** This defines whether the given source color represents itself or a group of colors */ sl@0: TColorOperationRepresentation iSourceColorRepresentation; sl@0: sl@0: /** This defines whether the given target color represents itself or a group of colors in case of sl@0: Color Swap operation. Redundant for Color Accent operation */ sl@0: TColorOperationRepresentation iTargetColorRepresentation; sl@0: sl@0: /** This defines the type of grouping for multiple representation of source color */ sl@0: TColorOperationRgbGroupingMode iColorOperationSourceRgbGroupingMode; sl@0: sl@0: /** This defines the type of grouping for multiple representation of target color in case of sl@0: Color Swap operation. Redundant for Color Accent operation */ sl@0: TColorOperationRgbGroupingMode iColorOperationTargetRgbGroupingMode; sl@0: sl@0: /** This gives the number of bits to ignore in case ERgbGroupingSignificantBits is used for sl@0: multiple representation of source color. For any other case, no. of bits ignored for red, green, sl@0: blue or alpha should be 0 */ sl@0: TBitsIgnore iNumBitsIgnored; sl@0: sl@0: /** This gives the entry status of every color operation entry. If entry is not set or removed, sl@0: this is ENotActive. And if entry is set, then this is EDiscreteSteps */ sl@0: TValueInfo iEntryStatus; sl@0: }; sl@0: sl@0: public: sl@0: sl@0: IMPORT_C static CCameraImageProcessing* NewL(CCamera& aCamera); sl@0: sl@0: IMPORT_C static CCameraImageProcessing* CreateL(CCamera& aCamera, MImplementationFactory& aImplFactory); sl@0: sl@0: IMPORT_C void GetSupportedTransformationsL(RArray<TUid>& aTransformations) const; sl@0: sl@0: IMPORT_C void GetActiveTransformationsL(RArray<TUid>& aTransformations) const; sl@0: sl@0: IMPORT_C void GetTransformationSupportedValuesL(TUid aTransformation, RArray<TInt>& aValues, TValueInfo& aInfo) const; sl@0: sl@0: IMPORT_C TInt TransformationValue(TUid aTransformation) const; sl@0: sl@0: IMPORT_C TInt GetTransformationValue(TUid aTransformation, TInt& aTransformationValue) const; sl@0: sl@0: IMPORT_C void SetTransformationValue(TUid aTransformation, TInt aValue); sl@0: sl@0: IMPORT_C void GetActiveTransformSequenceL(RArray<TUid>& aTransformSequence) const; sl@0: sl@0: IMPORT_C void SetActiveTransformSequenceL(RArray<TUid>& aTransformSequence); sl@0: sl@0: IMPORT_C void SetSourceRect(const TRect& aRect); sl@0: sl@0: IMPORT_C void GetSourceRect(TRect& aRect) const; sl@0: sl@0: IMPORT_C ~CCameraImageProcessing(); sl@0: sl@0: IMPORT_C void GetConcurrentColorSwappingsSupportedL(TInt& aConcurrentColorSwappingSupported) const; sl@0: sl@0: IMPORT_C void GetColorSwapCapabilitiesL(TInt aIndex, TColorOperationCapabilities& aColorSwapCapabilities) const; sl@0: sl@0: IMPORT_C void SetColorSwapEntryL(TInt aIndex, const TColorOperationEntry& aColorSwapParameters); sl@0: sl@0: IMPORT_C void RemoveColorSwapEntryL(TInt aIndex); sl@0: sl@0: IMPORT_C void GetColorSwapEntryL(TInt aIndex, TColorOperationEntry& aColorSwapParameters) const; sl@0: sl@0: IMPORT_C void StartColorSwappingL(); sl@0: sl@0: IMPORT_C void CancelColorSwappingL(); sl@0: sl@0: IMPORT_C void GetConcurrentColorAccentSupportedL(TInt& aConcurrentColorAccentSupported) const; sl@0: sl@0: IMPORT_C void GetColorAccentCapabilitiesL(TInt aIndex, TColorOperationCapabilities& aColorAccentCapabilities) const; sl@0: sl@0: IMPORT_C void SetColorAccentEntryL(TInt aIndex, const TColorOperationEntry& aColorAccentParameters); sl@0: sl@0: IMPORT_C void RemoveColorAccentEntryL(TInt aIndex); sl@0: sl@0: IMPORT_C void GetColorAccentEntryL(TInt aIndex, TColorOperationEntry& aColorAccentParameters) const; sl@0: sl@0: IMPORT_C void StartColorAccentL(); sl@0: sl@0: IMPORT_C void CancelColorAccentL(); sl@0: sl@0: IMPORT_C void GetSupportedRelativeOrientationOptionsL(TOrientationReference aOrientationReference, sl@0: TUint& aSupportedRelativeRotation, TUint& aSupportedRelativeMirroring, TUint& aSupportedRelativeFlipping) const; sl@0: sl@0: IMPORT_C void GetCurrentRelativeOrientationOptionsL(TOrientationReference& aOrientationReference, sl@0: TRelativeRotation& aRelativeRotation, TRelativeMirror& aRelativeMirror, TRelativeFlipping& aRelativeFlipping) const; sl@0: sl@0: IMPORT_C void SetRelativeOrientationOptionsL(TOrientationReference aOrientationReference, sl@0: TRelativeRotation aRelativeRotation, TRelativeMirror aRelativeMirror, TRelativeFlipping aRelativeFlipping); sl@0: sl@0: private: sl@0: IMPORT_C CCameraImageProcessing(CCamera& aOwner); sl@0: IMPORT_C void ConstructL(); sl@0: IMPORT_C void ConstructL(const MImplementationFactory& aImplFactory); sl@0: sl@0: private: sl@0: CCamera& iOwner; sl@0: MCameraImageProcessing* iImpl; // not owned sl@0: MCameraImageProcessing2* iImpl2; //not owned sl@0: MCameraImageProcessing3* iImpl3; //not owned sl@0: }; sl@0: #endif//ECAMIMAGEPROCESSING_H sl@0: sl@0: sl@0: