| OLD | NEW |
| 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 |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 109 MOCK_METHOD1(OnDiscardedPacketsUpdated, void(int discarded_packets)); | 109 MOCK_METHOD1(OnDiscardedPacketsUpdated, void(int discarded_packets)); |
| 110 MOCK_METHOD1(OnFrameCountsUpdated, void(const FrameCounts& frame_counts)); | 110 MOCK_METHOD1(OnFrameCountsUpdated, void(const FrameCounts& frame_counts)); |
| 111 MOCK_METHOD7(OnFrameBufferTimingsUpdated, | 111 MOCK_METHOD7(OnFrameBufferTimingsUpdated, |
| 112 void(int decode_ms, | 112 void(int decode_ms, |
| 113 int max_decode_ms, | 113 int max_decode_ms, |
| 114 int current_delay_ms, | 114 int current_delay_ms, |
| 115 int target_delay_ms, | 115 int target_delay_ms, |
| 116 int jitter_buffer_ms, | 116 int jitter_buffer_ms, |
| 117 int min_playout_delay_ms, | 117 int min_playout_delay_ms, |
| 118 int render_delay_ms)); | 118 int render_delay_ms)); |
| 119 MOCK_METHOD1(OnTimingFrameInfoUpdated, void(const TimingFrameInfo& info)); |
| 119 }; | 120 }; |
| 120 | 121 |
| 121 class TestFrameBuffer2 : public ::testing::Test { | 122 class TestFrameBuffer2 : public ::testing::Test { |
| 122 protected: | 123 protected: |
| 123 static constexpr int kMaxReferences = 5; | 124 static constexpr int kMaxReferences = 5; |
| 124 static constexpr int kFps1 = 1000; | 125 static constexpr int kFps1 = 1000; |
| 125 static constexpr int kFps10 = kFps1 / 10; | 126 static constexpr int kFps10 = kFps1 / 10; |
| 126 static constexpr int kFps20 = kFps1 / 20; | 127 static constexpr int kFps20 = kFps1 / 20; |
| 127 | 128 |
| 128 TestFrameBuffer2() | 129 TestFrameBuffer2() |
| (...skipping 405 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 534 // TODO(philipel): implement more unittests related to invalid references. | 535 // TODO(philipel): implement more unittests related to invalid references. |
| 535 TEST_F(TestFrameBuffer2, InvalidReferences) { | 536 TEST_F(TestFrameBuffer2, InvalidReferences) { |
| 536 EXPECT_EQ(-1, InsertFrame(0, 0, 1000, false, 2)); | 537 EXPECT_EQ(-1, InsertFrame(0, 0, 1000, false, 2)); |
| 537 EXPECT_EQ(1, InsertFrame(1, 0, 2000, false)); | 538 EXPECT_EQ(1, InsertFrame(1, 0, 2000, false)); |
| 538 ExtractFrame(); | 539 ExtractFrame(); |
| 539 EXPECT_EQ(2, InsertFrame(2, 0, 3000, false, 1)); | 540 EXPECT_EQ(2, InsertFrame(2, 0, 3000, false, 1)); |
| 540 } | 541 } |
| 541 | 542 |
| 542 } // namespace video_coding | 543 } // namespace video_coding |
| 543 } // namespace webrtc | 544 } // namespace webrtc |
| OLD | NEW |