blob: d4c8c21613856af441bfc0beefc9923f4fa94d5b [file] [log] [blame]
Zeke Chin71f6f442015-06-29 14:34:58 -07001/*
2 * Copyright (c) 2015 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 */
11
Mirko Bonadei92ea95e2017-09-15 06:47:31 +020012#ifndef MODULES_VIDEO_CODING_CODECS_H264_INCLUDE_H264_H_
13#define MODULES_VIDEO_CODING_CODECS_H264_INCLUDE_H264_H_
Zeke Chin71f6f442015-06-29 14:34:58 -070014
Mirko Bonadei92ea95e2017-09-15 06:47:31 +020015#include "media/base/codec.h"
16#include "modules/video_coding/include/video_codec_interface.h"
Zeke Chin71f6f442015-06-29 14:34:58 -070017
18namespace webrtc {
19
hbos9dc59282016-02-03 05:09:37 -080020// Set to disable the H.264 encoder/decoder implementations that are provided if
21// |rtc_use_h264| build flag is true (if false, this function does nothing).
22// This function should only be called before or during WebRTC initialization
23// and is not thread-safe.
24void DisableRtcUseH264();
25
Zeke Chin71f6f442015-06-29 14:34:58 -070026class H264Encoder : public VideoEncoder {
27 public:
magjedceecea42016-11-28 07:20:21 -080028 static H264Encoder* Create(const cricket::VideoCodec& codec);
hbosbab934b2016-01-27 01:36:03 -080029 // If H.264 is supported (any implementation).
Zeke Chin71f6f442015-06-29 14:34:58 -070030 static bool IsSupported();
31
32 ~H264Encoder() override {}
33};
34
35class H264Decoder : public VideoDecoder {
36 public:
37 static H264Decoder* Create();
38 static bool IsSupported();
39
40 ~H264Decoder() override {}
41};
42
43} // namespace webrtc
44
Mirko Bonadei92ea95e2017-09-15 06:47:31 +020045#endif // MODULES_VIDEO_CODING_CODECS_H264_INCLUDE_H264_H_