blob: 75b07272c0bee4446fd5de1b04c9537c236c5343 [file] [log] [blame]
niklase@google.com470e71d2011-07-07 08:21:25 +00001/*
2 * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
3 *
4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
mflodman@webrtc.orgd5a4d9b2012-01-02 13:04:05 +000011#ifndef WEBRTC_VIDEO_ENGINE_INCLUDE_VIE_EXTERNAL_CODEC_H_
12#define WEBRTC_VIDEO_ENGINE_INCLUDE_VIE_EXTERNAL_CODEC_H_
niklase@google.com470e71d2011-07-07 08:21:25 +000013
14#include "common_types.h"
15
mflodman@webrtc.orgd5a4d9b2012-01-02 13:04:05 +000016namespace webrtc {
17
niklase@google.com470e71d2011-07-07 08:21:25 +000018class VideoDecoder;
mflodman@webrtc.orgd5a4d9b2012-01-02 13:04:05 +000019class VideoEncoder;
20class VideoEngine;
niklase@google.com470e71d2011-07-07 08:21:25 +000021
mflodman@webrtc.orgd5a4d9b2012-01-02 13:04:05 +000022class WEBRTC_DLLEXPORT ViEExternalCodec {
23 public:
24 static ViEExternalCodec* GetInterface(VideoEngine* video_engine);
niklase@google.com470e71d2011-07-07 08:21:25 +000025
mflodman@webrtc.orgd5a4d9b2012-01-02 13:04:05 +000026 virtual int Release() = 0;
niklase@google.com470e71d2011-07-07 08:21:25 +000027
mflodman@webrtc.orgd5a4d9b2012-01-02 13:04:05 +000028 virtual int RegisterExternalSendCodec(const int video_channel,
29 const unsigned char pl_type,
stefan@webrtc.orgfcd85852013-01-09 08:35:40 +000030 VideoEncoder* encoder,
31 bool internal_source) = 0;
niklase@google.com470e71d2011-07-07 08:21:25 +000032
mflodman@webrtc.orgd5a4d9b2012-01-02 13:04:05 +000033 virtual int DeRegisterExternalSendCodec(const int video_channel,
34 const unsigned char pl_type) = 0;
niklase@google.com470e71d2011-07-07 08:21:25 +000035
mflodman@webrtc.orgd5a4d9b2012-01-02 13:04:05 +000036 virtual int RegisterExternalReceiveCodec(const int video_channel,
37 const unsigned int pl_type,
38 VideoDecoder* decoder,
39 bool decoder_render = false,
40 int render_delay = 0) = 0;
niklase@google.com470e71d2011-07-07 08:21:25 +000041
mflodman@webrtc.orgd5a4d9b2012-01-02 13:04:05 +000042 virtual int DeRegisterExternalReceiveCodec(const int video_channel,
43 const unsigned char pl_type) = 0;
niklase@google.com470e71d2011-07-07 08:21:25 +000044
mflodman@webrtc.orgd5a4d9b2012-01-02 13:04:05 +000045 protected:
46 ViEExternalCodec() {}
47 virtual ~ViEExternalCodec() {}
niklase@google.com470e71d2011-07-07 08:21:25 +000048};
mflodman@webrtc.orgd5a4d9b2012-01-02 13:04:05 +000049
50} // namespace webrtc
51
52#endif // WEBRTC_VIDEO_ENGINE_INCLUDE_VIE_EXTERNAL_CODEC_H_