equal
deleted
inserted
replaced
|
1 /* |
|
2 * Copyright (c) 2010 Ixonos Plc. |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of the "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 * Ixonos Plc |
|
14 * |
|
15 * Description: |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 #ifndef __MIMAGEFILTER_H__ |
|
21 #define __MIMAGEFILTER_H__ |
|
22 |
|
23 #include <e32base.h> |
|
24 |
|
25 class TBlock |
|
26 { |
|
27 public: |
|
28 |
|
29 TBlock() {}; |
|
30 |
|
31 TBlock (const TRect & aRect) |
|
32 { |
|
33 iRect = aRect; |
|
34 iWidth = aRect.iBr.iX - aRect.iTl.iX; |
|
35 iHeight = aRect.iBr.iY - aRect.iTl.iY; |
|
36 iDataLength = iWidth * iHeight; |
|
37 iData = new (ELeave) TUint32 [iDataLength]; |
|
38 Mem::FillZ(iData, iDataLength * sizeof(TUint32)); |
|
39 }; |
|
40 ~TBlock() {delete[] iData;}; |
|
41 public: |
|
42 TRect iRect; |
|
43 TInt iWidth; |
|
44 TInt iHeight; |
|
45 TInt iDataLength; |
|
46 TUint32 * iData; |
|
47 |
|
48 protected: |
|
49 |
|
50 }; |
|
51 |
|
52 class MImageFilter |
|
53 { |
|
54 public: |
|
55 virtual ~MImageFilter() {} |
|
56 virtual TRect Rect() = 0; |
|
57 virtual TReal Scale() = 0; |
|
58 virtual TSize ViewPortSize() = 0; |
|
59 virtual TBlock * GetBlockL ( const TRect & aRect ) = 0; |
|
60 virtual void SetParent( MImageFilter* aParent ) = 0; |
|
61 virtual void SetChild( MImageFilter* aChild ) = 0; |
|
62 virtual TInt CmdL( const TDesC16& aCmd ) = 0; |
|
63 virtual const char* Type() = 0; |
|
64 MImageFilter* iParent; |
|
65 MImageFilter* iChild; |
|
66 }; |
|
67 |
|
68 #endif |