OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 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 |
11 #include <stdio.h> | 11 #include <stdio.h> |
12 | 12 |
13 #include <memory> | 13 #include <memory> |
14 | 14 |
| 15 #include "webrtc/api/optional.h" |
15 #include "webrtc/api/video/i420_buffer.h" | 16 #include "webrtc/api/video/i420_buffer.h" |
16 #include "webrtc/common_video/libyuv/include/webrtc_libyuv.h" | 17 #include "webrtc/common_video/libyuv/include/webrtc_libyuv.h" |
17 #include "webrtc/modules/video_coding/codecs/test/video_codec_test.h" | 18 #include "webrtc/modules/video_coding/codecs/test/video_codec_test.h" |
18 #include "webrtc/modules/video_coding/codecs/vp8/include/vp8.h" | 19 #include "webrtc/modules/video_coding/codecs/vp8/include/vp8.h" |
19 #include "webrtc/modules/video_coding/codecs/vp8/temporal_layers.h" | 20 #include "webrtc/modules/video_coding/codecs/vp8/temporal_layers.h" |
20 #include "webrtc/rtc_base/checks.h" | 21 #include "webrtc/rtc_base/checks.h" |
21 #include "webrtc/rtc_base/optional.h" | |
22 #include "webrtc/rtc_base/timeutils.h" | 22 #include "webrtc/rtc_base/timeutils.h" |
23 #include "webrtc/test/field_trial.h" | 23 #include "webrtc/test/field_trial.h" |
24 #include "webrtc/test/frame_utils.h" | 24 #include "webrtc/test/frame_utils.h" |
25 #include "webrtc/test/gtest.h" | 25 #include "webrtc/test/gtest.h" |
26 #include "webrtc/test/testsupport/fileutils.h" | 26 #include "webrtc/test/testsupport/fileutils.h" |
27 #include "webrtc/test/video_codec_settings.h" | 27 #include "webrtc/test/video_codec_settings.h" |
28 | 28 |
29 namespace webrtc { | 29 namespace webrtc { |
30 | 30 |
31 namespace { | 31 namespace { |
(...skipping 426 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
458 codec_settings_.VP8()->automaticResizeOn = true; | 458 codec_settings_.VP8()->automaticResizeOn = true; |
459 EXPECT_EQ(WEBRTC_VIDEO_CODEC_OK, | 459 EXPECT_EQ(WEBRTC_VIDEO_CODEC_OK, |
460 encoder_->InitEncode(&codec_settings_, kNumCores, kMaxPayloadSize)); | 460 encoder_->InitEncode(&codec_settings_, kNumCores, kMaxPayloadSize)); |
461 | 461 |
462 VideoEncoder::ScalingSettings settings = encoder_->GetScalingSettings(); | 462 VideoEncoder::ScalingSettings settings = encoder_->GetScalingSettings(); |
463 EXPECT_TRUE(settings.enabled); | 463 EXPECT_TRUE(settings.enabled); |
464 EXPECT_EQ(kMinPixelsPerFrame, settings.min_pixels_per_frame); | 464 EXPECT_EQ(kMinPixelsPerFrame, settings.min_pixels_per_frame); |
465 } | 465 } |
466 | 466 |
467 } // namespace webrtc | 467 } // namespace webrtc |
OLD | NEW |