summaryrefslogtreecommitdiff
path: root/video_engine/vie_impl.h
blob: 290a67e5afcdd485a9e6f551d7646a4795bb5b87 (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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
/*
 *  Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
 *
 *  Use of this source code is governed by a BSD-style license
 *  that can be found in the LICENSE file in the root of the source
 *  tree. An additional intellectual property rights grant can be found
 *  in the file PATENTS.  All contributing project authors may
 *  be found in the AUTHORS file in the root of the source tree.
 */

#ifndef WEBRTC_VIDEO_ENGINE_VIE_IMPL_H_
#define WEBRTC_VIDEO_ENGINE_VIE_IMPL_H_

#include "webrtc/common.h"
#include "webrtc/engine_configurations.h"
#include "webrtc/system_wrappers/interface/scoped_ptr.h"
#include "webrtc/video_engine/vie_defines.h"

#include "webrtc/video_engine/vie_base_impl.h"

#ifdef WEBRTC_VIDEO_ENGINE_CAPTURE_API
#include "webrtc/video_engine/vie_capture_impl.h"
#endif
#ifdef WEBRTC_VIDEO_ENGINE_CODEC_API
#include "webrtc/video_engine/vie_codec_impl.h"
#endif
#ifdef WEBRTC_VIDEO_ENGINE_ENCRYPTION_API
#include "webrtc/video_engine/vie_encryption_impl.h"
#endif
#ifdef WEBRTC_VIDEO_ENGINE_FILE_API
#include "webrtc/video_engine/vie_file_impl.h"
#endif
#ifdef WEBRTC_VIDEO_ENGINE_IMAGE_PROCESS_API
#include "webrtc/video_engine/vie_image_process_impl.h"
#endif
#include "webrtc/video_engine/vie_network_impl.h"
#ifdef WEBRTC_VIDEO_ENGINE_RENDER_API
#include "webrtc/video_engine/vie_render_impl.h"
#endif
#ifdef WEBRTC_VIDEO_ENGINE_RTP_RTCP_API
#include "webrtc/video_engine/vie_rtp_rtcp_impl.h"
#endif
#ifdef WEBRTC_VIDEO_ENGINE_EXTERNAL_CODEC_API
#include "webrtc/video_engine/vie_external_codec_impl.h"
#endif

namespace webrtc {

class VideoEngineImpl
    : public ViEBaseImpl,
#ifdef WEBRTC_VIDEO_ENGINE_CODEC_API
      public ViECodecImpl,
#endif
#ifdef WEBRTC_VIDEO_ENGINE_CAPTURE_API
      public ViECaptureImpl,
#endif
#ifdef WEBRTC_VIDEO_ENGINE_ENCRYPTION_API
      public ViEEncryptionImpl,
#endif
#ifdef WEBRTC_VIDEO_ENGINE_FILE_API
      public ViEFileImpl,
#endif
#ifdef WEBRTC_VIDEO_ENGINE_IMAGE_PROCESS_API
      public ViEImageProcessImpl,
#endif
      public ViENetworkImpl,
#ifdef WEBRTC_VIDEO_ENGINE_RENDER_API
      public ViERenderImpl,
#endif
#ifdef WEBRTC_VIDEO_ENGINE_RTP_RTCP_API
      public ViERTP_RTCPImpl,
#endif
#ifdef WEBRTC_VIDEO_ENGINE_EXTERNAL_CODEC_API
      public ViEExternalCodecImpl,
#endif
      public VideoEngine
{  // NOLINT
 public:
  VideoEngineImpl(const Config* config, bool owns_config)
      : ViEBaseImpl(*config),
#ifdef WEBRTC_VIDEO_ENGINE_CODEC_API
        ViECodecImpl(ViEBaseImpl::shared_data()),
#endif
#ifdef WEBRTC_VIDEO_ENGINE_CAPTURE_API
        ViECaptureImpl(ViEBaseImpl::shared_data()),
#endif
#ifdef WEBRTC_VIDEO_ENGINE_ENCRYPTION_API
        ViEEncryptionImpl(ViEBaseImpl::shared_data()),
#endif
#ifdef WEBRTC_VIDEO_ENGINE_FILE_API
        ViEFileImpl(ViEBaseImpl::shared_data()),
#endif
#ifdef WEBRTC_VIDEO_ENGINE_IMAGE_PROCESS_API
        ViEImageProcessImpl(ViEBaseImpl::shared_data()),
#endif
        ViENetworkImpl(ViEBaseImpl::shared_data()),
#ifdef WEBRTC_VIDEO_ENGINE_RENDER_API
        ViERenderImpl(ViEBaseImpl::shared_data()),
#endif
#ifdef WEBRTC_VIDEO_ENGINE_RTP_RTCP_API
        ViERTP_RTCPImpl(ViEBaseImpl::shared_data()),
#endif
#ifdef WEBRTC_VIDEO_ENGINE_EXTERNAL_CODEC_API
        ViEExternalCodecImpl(ViEBaseImpl::shared_data()),
#endif
        own_config_(owns_config ? config : NULL)
  {}
  virtual ~VideoEngineImpl() {}

 private:
  // Placeholder for the case where this owns the config.
  scoped_ptr<const Config> own_config_;
};

}  // namespace webrtc

#endif  // WEBRTC_VIDEO_ENGINE_VIE_IMPL_H_