williamr@4: // Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). williamr@4: // All rights reserved. williamr@4: // This component and the accompanying materials are made available williamr@4: // under the terms of "Eclipse Public License v1.0" williamr@4: // which accompanies this distribution, and is available williamr@4: // at the URL "http://www.eclipse.org/legal/epl-v10.html". williamr@4: // williamr@4: // Initial Contributors: williamr@4: // Nokia Corporation - initial contribution. williamr@4: // williamr@4: // Contributors: williamr@4: // williamr@4: // Description: williamr@4: // This is Image Transform extension for Rotate/Flip Transformations williamr@4: // williamr@4: // williamr@4: williamr@4: /** williamr@4: @file williamr@4: @publishedAll williamr@4: @released williamr@4: */ williamr@4: williamr@4: #ifndef __ORIENTATIONTRANFORMEEXTENSION_H__ williamr@4: #define __ORIENTATIONTRANFORMEEXTENSION_H__ williamr@4: williamr@4: #include williamr@4: #include williamr@4: #include williamr@4: williamr@4: /** williamr@4: @publishedAll williamr@4: @released williamr@4: williamr@4: The Orientation Extension to the ImageTransform plugin. williamr@4: williamr@4: The class provides the methods to set the image orientation and is intended to be implemented williamr@4: by the plugins supporting the rotation of the image based on the orientation. The plugin williamr@4: supporting this extension must use the opaque_data v2 format in RSS file and also the orientation flag williamr@4: must be set in the opaque_data. The client must retrieve this extension implementation from williamr@4: the plugin using its extension UID. williamr@4: */ williamr@4: class COrientationTransformExtension : public CImageTransformPluginExtension williamr@4: { williamr@4: public: williamr@4: /** williamr@4: The possible orientations of the image. Similar to the EXIF orientation tag williamr@4: */ williamr@4: enum TOrientation williamr@4: { williamr@4: /** williamr@4: No rotation done williamr@4: */ williamr@4: ERotationNone = 1, williamr@4: /** williamr@4: Rotate the image clockwise through 90 degrees. williamr@4: */ williamr@4: ERotation90DegreesClockwise = 6, williamr@4: /** williamr@4: Rotate the image clockwise through 180 degrees. williamr@4: */ williamr@4: ERotation180DegreesClockwise = 3, williamr@4: /** williamr@4: Rotate the image clockwise through 270 degrees. williamr@4: */ williamr@4: ERotation270DegreesClockwise = 8, williamr@4: /** williamr@4: Mirror the image over its vertical axis williamr@4: */ williamr@4: EMirrorVerticalAxis = 2, williamr@4: /** williamr@4: Mirror the image over its horizontal axis williamr@4: */ williamr@4: EMirrorHorizontalAxis = 4, williamr@4: /** williamr@4: Transpose (or mirror) the image across a diagonal running from top-left to lower-right. williamr@4: */ williamr@4: ETransposeOverMainDiagonal = 5, williamr@4: /** williamr@4: Transpose (or mirror) the image across a diagonal running from top-right to lower-left. williamr@4: */ williamr@4: ETransposeOverMinorDiagonal = 7 williamr@4: }; williamr@4: williamr@4: IMPORT_C void SetOrientationL(TOrientation aOrientation ) ; williamr@4: williamr@4: protected: williamr@4: virtual void DoSetOrientationL(TOrientation aOrientation) = 0; williamr@4: williamr@4: private: williamr@4: IMPORT_C virtual void ReservedVirtual5(); williamr@4: williamr@4: private: williamr@4: // Future proofing williamr@4: TAny* iPad; williamr@4: }; williamr@4: williamr@4: #endif // __ORIENTATIONTRANFORMEEXTENSION_H__