Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(370)

Side by Side Diff: webrtc/modules/video_coding/codecs/vp9/vp9_noop.cc

Issue 1970343002: Make sure WebRTC works without libvpx VP9 support. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: add test to make sure VP9 support isn't announced Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2016 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 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 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 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 *
9 */ 10 */
10 #include "webrtc/modules/rtp_rtcp/source/rtp_packet_received.h" 11
12 #if !defined(RTC_DISABLE_VP9)
13 #error
14 #endif // !defined(RTC_DISABLE_VP9)
15
16 #include "webrtc/base/checks.h"
17 #include "webrtc/modules/video_coding/codecs/vp9/include/vp9.h"
11 18
12 namespace webrtc { 19 namespace webrtc {
13 20
14 void FuzzOneInput(const uint8_t* data, size_t size) { 21 bool VP9Encoder::IsSupported() {
15 RtpPacketReceived packet; 22 return false;
23 }
16 24
17 packet.Parse(data, size); 25 VP9Encoder* VP9Encoder::Create() {
26 RTC_NOTREACHED();
27 return nullptr;
28 }
18 29
19 // Call packet accessors because they have extra checks. 30 bool VP9Decoder::IsSupported() {
20 packet.Marker(); 31 return false;
21 packet.PayloadType(); 32 }
22 packet.SequenceNumber(); 33
23 packet.Timestamp(); 34 VP9Decoder* VP9Decoder::Create() {
24 packet.Ssrc(); 35 RTC_NOTREACHED();
25 packet.Csrcs(); 36 return nullptr;
26 } 37 }
27 38
28 } // namespace webrtc 39 } // namespace webrtc
29
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698