blob: 5eee788d8fbd0a83e7c2e783354b6aae4495629b [file] [log] [blame]
Magnus Jedvert244ad802017-09-28 21:19:18 +02001/*
2 * Copyright (c) 2017 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#include "media/engine/webrtcvideodecoderfactory.h"
12
13namespace cricket {
14
15webrtc::VideoDecoder* WebRtcVideoDecoderFactory::CreateVideoDecoderWithParams(
16 const VideoCodec& codec,
17 VideoDecoderParams params) {
18 // Default implementation that delegates to old version in order to preserve
19 // backwards-compatability.
20 webrtc::VideoCodecType type = webrtc::PayloadStringToCodecType(codec.name);
21 return CreateVideoDecoderWithParams(type, params);
22}
23
24webrtc::VideoDecoder* WebRtcVideoDecoderFactory::CreateVideoDecoder(
25 webrtc::VideoCodecType type) {
26 RTC_NOTREACHED();
27 return nullptr;
28}
29
30webrtc::VideoDecoder* WebRtcVideoDecoderFactory::CreateVideoDecoderWithParams(
31 webrtc::VideoCodecType type,
32 VideoDecoderParams params) {
33 return CreateVideoDecoder(type);
34}
35
36} // namespace cricket