|
1 /* |
|
2 * Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "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 * |
|
14 * Description: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef MUSHENGLIVESESSION_H |
|
20 #define MUSHENGLIVESESSION_H |
|
21 |
|
22 // USER |
|
23 #include "musengmceoutsession.h" |
|
24 |
|
25 // SYSTEM |
|
26 #include <ecam.h> |
|
27 |
|
28 // FORWARD DECLARATIONS |
|
29 class MMusEngLiveSessionObserver; |
|
30 |
|
31 |
|
32 class CMusEngLiveSession : public CMusEngMceOutSession |
|
33 { |
|
34 |
|
35 public: |
|
36 |
|
37 /** |
|
38 * Creates new MultimediaSharing Live session. |
|
39 * |
|
40 * @since S60 v3.2 |
|
41 * @param aFileName Media filename |
|
42 * @param aRect UI drawing area. It is allowed handle from engine |
|
43 * @param aSessionObserver Session specific callbacks |
|
44 * @param aSipProfileId SIP profile to be used, 0 is default profile |
|
45 * @return CMusEngLiveSession* New instanse of specified class |
|
46 */ |
|
47 IMPORT_C static CMusEngLiveSession* NewL( |
|
48 const TDesC& aFileName, |
|
49 const TRect& aRect, |
|
50 MMusEngLiveSessionObserver* aSessionObserver, |
|
51 TUint aSipProfileId = 0); |
|
52 |
|
53 /** |
|
54 * Creates new MultimediaSharing Live session. |
|
55 * |
|
56 * @since S60 v3.2 |
|
57 * @param aRect UI drawing area. It is allowed handle from engine |
|
58 * @param aSessionObserver Session specific callbacks |
|
59 * @param aSipProfileId SIP profile to be used, 0 is default profile |
|
60 * @return CMusEngLiveSession* New instanse of specified class |
|
61 */ |
|
62 IMPORT_C static CMusEngLiveSession* NewL( |
|
63 const TRect& aRect, |
|
64 MMusEngLiveSessionObserver* aSessionObserver, |
|
65 TUint aSipProfileId = 0 ); |
|
66 |
|
67 public: |
|
68 |
|
69 /** |
|
70 * Destructor |
|
71 * |
|
72 * @since S60 v3.2 |
|
73 */ |
|
74 ~CMusEngLiveSession(); |
|
75 |
|
76 |
|
77 |
|
78 public: // NEW API FUNCTIONS live session specific |
|
79 |
|
80 /** |
|
81 * Sets callback interface pointer |
|
82 * |
|
83 * @since S60 v3.2 |
|
84 * @param aSessionObserver Pointer to class which implements interface |
|
85 */ |
|
86 IMPORT_C void SetSessionObserver( |
|
87 MMusEngLiveSessionObserver* aSessionObserver ); |
|
88 |
|
89 /** |
|
90 * Gets current zoom factor |
|
91 * |
|
92 * @pre Session is established |
|
93 * @leave KErrNotReady if precondition not fullfilled |
|
94 * @since S60 v3.2 |
|
95 */ |
|
96 IMPORT_C TInt CurrentZoomL() const; |
|
97 |
|
98 /** |
|
99 * Gets maximum zoom factor |
|
100 * |
|
101 * @pre Session is established |
|
102 * @leave KErrNotReady if precondition not fullfilled |
|
103 * @since S60 v3.2 |
|
104 */ |
|
105 IMPORT_C TInt MaxZoomL() const; |
|
106 |
|
107 IMPORT_C TInt MinZoomL() const; |
|
108 |
|
109 /** |
|
110 * Increases zoom factor by one. |
|
111 * |
|
112 * @pre Session is established |
|
113 * @leave KErrNotReady if precondition not fullfilled |
|
114 * @since S60 v3.2 |
|
115 */ |
|
116 IMPORT_C void ZoomInL(); |
|
117 |
|
118 /** |
|
119 * Decreases zoom factor by one. |
|
120 * |
|
121 * @pre Session is established |
|
122 * @leave KErrNotReady if precondition not fullfilled |
|
123 * @since S60 v3.2 |
|
124 */ |
|
125 IMPORT_C void ZoomOutL(); |
|
126 |
|
127 /** |
|
128 * Sets zoom factor to default. |
|
129 * |
|
130 * @pre Session is established |
|
131 * @leave KErrNotReady if precondition not fullfilled |
|
132 * @since S60 v3.2 |
|
133 */ |
|
134 IMPORT_C void ZoomDefaultL(); |
|
135 |
|
136 public: // implementation of virtual API from CMusEngMceOutSession |
|
137 |
|
138 /** |
|
139 * Resumes previously paused session. |
|
140 * Continues using viewfinder and enables streaming video. |
|
141 * |
|
142 * @since S60 v3.2 |
|
143 */ |
|
144 IMPORT_C void PlayL(); |
|
145 |
|
146 /** |
|
147 * Pauses session. |
|
148 * Holds display and disables streaming video to network. |
|
149 * |
|
150 * @since S60 v3.2 |
|
151 */ |
|
152 IMPORT_C void PauseL(); |
|
153 |
|
154 |
|
155 protected: // inherited from CMusEngMceOutSession |
|
156 |
|
157 /** |
|
158 * |
|
159 * @since S60 v3.2 |
|
160 */ |
|
161 void CompleteSessionStructureL(); |
|
162 |
|
163 |
|
164 private: |
|
165 |
|
166 /** |
|
167 * Constructor |
|
168 |
|
169 * @since S60 v3.2 |
|
170 */ |
|
171 CMusEngLiveSession( MMusEngLiveSessionObserver* aSessionObserver, |
|
172 const TRect& aRect, |
|
173 TUint aSipProfileId = 0 ); |
|
174 |
|
175 /** |
|
176 * Second-phase constructor |
|
177 * |
|
178 * @since S60 v3.2 |
|
179 */ |
|
180 void ConstructL(); |
|
181 |
|
182 |
|
183 public: |
|
184 |
|
185 /** |
|
186 * |
|
187 * @since S60 v3.2 |
|
188 */ |
|
189 //TCameraInfo iCameraInfo; |
|
190 |
|
191 /** |
|
192 * |
|
193 * @since S60 v3.2 |
|
194 */ |
|
195 TInt iDefaultZoomFactor; |
|
196 TInt iPlaying; |
|
197 TInt iCurrentZoom; |
|
198 |
|
199 |
|
200 }; |
|
201 |
|
202 #endif |
|
203 |