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

Side by Side Diff: webrtc/modules/video_coding/video_receiver_unittest.cc

Issue 1853813002: Add support for writing raw encoder output to .ivf files. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Rebase Created 4 years, 8 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) 2013 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2013 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
(...skipping 15 matching lines...) Expand all
26 namespace vcm { 26 namespace vcm {
27 namespace { 27 namespace {
28 28
29 class TestVideoReceiver : public ::testing::Test { 29 class TestVideoReceiver : public ::testing::Test {
30 protected: 30 protected:
31 static const int kUnusedPayloadType = 10; 31 static const int kUnusedPayloadType = 10;
32 32
33 TestVideoReceiver() : clock_(0) {} 33 TestVideoReceiver() : clock_(0) {}
34 34
35 virtual void SetUp() { 35 virtual void SetUp() {
36 receiver_.reset(new VideoReceiver(&clock_, &event_factory_)); 36 receiver_.reset(new VideoReceiver(&clock_, &event_factory_, nullptr));
37 receiver_->RegisterExternalDecoder(&decoder_, kUnusedPayloadType); 37 receiver_->RegisterExternalDecoder(&decoder_, kUnusedPayloadType);
38 const size_t kMaxNackListSize = 250; 38 const size_t kMaxNackListSize = 250;
39 const int kMaxPacketAgeToNack = 450; 39 const int kMaxPacketAgeToNack = 450;
40 receiver_->SetNackSettings(kMaxNackListSize, kMaxPacketAgeToNack, 0); 40 receiver_->SetNackSettings(kMaxNackListSize, kMaxPacketAgeToNack, 0);
41 41
42 VideoCodingModule::Codec(kVideoCodecVP8, &settings_); 42 VideoCodingModule::Codec(kVideoCodecVP8, &settings_);
43 settings_.plType = kUnusedPayloadType; // Use the mocked encoder. 43 settings_.plType = kUnusedPayloadType; // Use the mocked encoder.
44 EXPECT_EQ(0, receiver_->RegisterReceiveCodec(&settings_, 1, true)); 44 EXPECT_EQ(0, receiver_->RegisterReceiveCodec(&settings_, 1, true));
45 } 45 }
46 46
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
200 TEST_F(TestVideoReceiver, ReceiverDelay) { 200 TEST_F(TestVideoReceiver, ReceiverDelay) {
201 EXPECT_EQ(0, receiver_->SetMinReceiverDelay(0)); 201 EXPECT_EQ(0, receiver_->SetMinReceiverDelay(0));
202 EXPECT_EQ(0, receiver_->SetMinReceiverDelay(5000)); 202 EXPECT_EQ(0, receiver_->SetMinReceiverDelay(5000));
203 EXPECT_EQ(-1, receiver_->SetMinReceiverDelay(-100)); 203 EXPECT_EQ(-1, receiver_->SetMinReceiverDelay(-100));
204 EXPECT_EQ(-1, receiver_->SetMinReceiverDelay(10010)); 204 EXPECT_EQ(-1, receiver_->SetMinReceiverDelay(10010));
205 } 205 }
206 206
207 } // namespace 207 } // namespace
208 } // namespace vcm 208 } // namespace vcm
209 } // namespace webrtc 209 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/video_coding/video_receiver.cc ('k') | webrtc/modules/video_coding/video_sender.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698