OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/renderer/media_recorder/video_track_recorder.h" | 5 #include "content/renderer/media_recorder/video_track_recorder.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <memory> | 9 #include <memory> |
10 #include <string> | 10 #include <string> |
(...skipping 29 matching lines...) Expand all Loading... |
40 namespace content { | 40 namespace content { |
41 | 41 |
42 ACTION_P(RunClosure, closure) { | 42 ACTION_P(RunClosure, closure) { |
43 closure.Run(); | 43 closure.Run(); |
44 } | 44 } |
45 | 45 |
46 const VideoTrackRecorder::CodecId kTrackRecorderTestCodec[] = { | 46 const VideoTrackRecorder::CodecId kTrackRecorderTestCodec[] = { |
47 VideoTrackRecorder::CodecId::VP8, | 47 VideoTrackRecorder::CodecId::VP8, |
48 VideoTrackRecorder::CodecId::VP9 | 48 VideoTrackRecorder::CodecId::VP9 |
49 #if BUILDFLAG(RTC_USE_H264) | 49 #if BUILDFLAG(RTC_USE_H264) |
| 50 // This test case can't be enabled in Android because there is no software |
| 51 // OpenH264 fallback nor render thread to enumerate the hardware encoders. |
50 , VideoTrackRecorder::CodecId::H264 | 52 , VideoTrackRecorder::CodecId::H264 |
51 #endif | 53 #endif |
52 }; | 54 }; |
53 const gfx::Size kTrackRecorderTestSize[] = { | 55 const gfx::Size kTrackRecorderTestSize[] = { |
54 gfx::Size(kVEAEncoderMinResolutionWidth / 2, | 56 gfx::Size(kVEAEncoderMinResolutionWidth / 2, |
55 kVEAEncoderMinResolutionHeight / 2), | 57 kVEAEncoderMinResolutionHeight / 2), |
56 gfx::Size(kVEAEncoderMinResolutionWidth, kVEAEncoderMinResolutionHeight)}; | 58 gfx::Size(kVEAEncoderMinResolutionWidth, kVEAEncoderMinResolutionHeight)}; |
57 static const int kTrackRecorderTestSizeDiff = 20; | 59 static const int kTrackRecorderTestSizeDiff = 20; |
58 | 60 |
59 class VideoTrackRecorderTest | 61 class VideoTrackRecorderTest |
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
324 Mock::VerifyAndClearExpectations(this); | 326 Mock::VerifyAndClearExpectations(this); |
325 } | 327 } |
326 | 328 |
327 INSTANTIATE_TEST_CASE_P(, | 329 INSTANTIATE_TEST_CASE_P(, |
328 VideoTrackRecorderTest, | 330 VideoTrackRecorderTest, |
329 ::testing::Combine(ValuesIn(kTrackRecorderTestCodec), | 331 ::testing::Combine(ValuesIn(kTrackRecorderTestCodec), |
330 ValuesIn(kTrackRecorderTestSize), | 332 ValuesIn(kTrackRecorderTestSize), |
331 ::testing::Bool())); | 333 ::testing::Bool())); |
332 | 334 |
333 } // namespace content | 335 } // namespace content |
OLD | NEW |