blob: d61f8c067ec679c303ce53cda189a9f83cb1f635 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
|
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef CSFMEDIAPROVIDER_H_
#define CSFMEDIAPROVIDER_H_
#if __cplusplus
#include <string>
namespace CSF
{
class AudioControl;
class VideoControl;
class AudioTermination;
class VideoTermination;
class MediaProviderObserver;
class MediaProvider
{
public:
static MediaProvider* create( );///factory method for all MediaProvider derived types (ctor is protected).
virtual ~MediaProvider() = 0;
virtual int init() = 0;
virtual void shutdown() = 0;
virtual AudioControl* getAudioControl() = 0;
virtual VideoControl* getVideoControl() = 0;
virtual AudioTermination* getAudioTermination() = 0;
virtual VideoTermination* getVideoTermination() = 0;
virtual void addMediaProviderObserver( MediaProviderObserver* observer ) = 0;
protected:
MediaProvider() {};
};
class MediaProviderObserver
{
public:
virtual void onVideoModeChanged( bool enable ) {}
virtual void onKeyFrameRequested( int callId ) {}
virtual void onMediaLost( int callId ) {}
virtual void onMediaRestored( int callId ) {}
};
} // namespace
#endif // __cplusplus
#endif /* CSFMEDIAPROVIDER_H_ */
|