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 __FRAMETAKER_H |
|
21 #define __FRAMETAKER_H |
|
22 |
|
23 #include <vedmovie.h> |
|
24 |
|
25 class MVeiFrameTakerObserver |
|
26 { |
|
27 |
|
28 public: |
|
29 |
|
30 virtual void NotifyFramesCompleted( CFbsBitmap* aFirstFrame, CFbsBitmap* aLastFrame, |
|
31 CFbsBitmap* aTimelineFrame, TInt aError ) = 0; |
|
32 }; |
|
33 |
|
34 |
|
35 NONSHARABLE_CLASS( CVeiFrameTaker ): public CActive, |
|
36 public MVedVideoClipFrameObserver |
|
37 |
|
38 { |
|
39 public: |
|
40 IMPORT_C static CVeiFrameTaker* NewL( MVeiFrameTakerObserver& aObserver ); |
|
41 ~CVeiFrameTaker(); |
|
42 |
|
43 public: |
|
44 IMPORT_C void GetFramesL(CVedVideoClipInfo& aInfo, |
|
45 TInt const aFirstFrame, TSize* const aFirstResolution, |
|
46 TInt const aLastFrame, TSize* const aLastResolution, |
|
47 TInt const aTimelineFrame, TSize* const aTimelineResolution, |
|
48 TInt aPriority); |
|
49 |
|
50 private: |
|
51 CVeiFrameTaker( MVeiFrameTakerObserver& aObserver ); |
|
52 void ConstructL(); |
|
53 |
|
54 void DoCancel(); |
|
55 void RunL(); |
|
56 |
|
57 virtual void NotifyVideoClipFrameCompleted(CVedVideoClipInfo& aInfo, |
|
58 TInt aError, |
|
59 CFbsBitmap* aFrame); |
|
60 private: |
|
61 CActiveSchedulerWait *iWaitScheduler; |
|
62 CFbsBitmap* iFirstFrame; |
|
63 CFbsBitmap* iLastFrame; |
|
64 CFbsBitmap* iTimelineFrame; |
|
65 |
|
66 TInt iFrameCount; |
|
67 TInt iError; |
|
68 |
|
69 MVeiFrameTakerObserver& iObserver; |
|
70 }; |
|
71 #endif |
|