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

Unified Diff: modules/video_coding/codecs/test/videoprocessor_integrationtest_openh264.cc

Issue 3015703002: Splitting cl https://codereview.webrtc.org/3011373002 into two: updating v1.7 and adding unit tests… (Closed)
Patch Set: Created 3 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: modules/video_coding/codecs/test/videoprocessor_integrationtest_openh264.cc
diff --git a/modules/video_coding/codecs/test/videoprocessor_integrationtest_openh264.cc b/modules/video_coding/codecs/test/videoprocessor_integrationtest_openh264.cc
index e6db027e1d8d22e4a251e37053f42a61173eda3c..eac27a7317d99804f9045cf3e45c8b56f93ae058 100644
--- a/modules/video_coding/codecs/test/videoprocessor_integrationtest_openh264.cc
+++ b/modules/video_coding/codecs/test/videoprocessor_integrationtest_openh264.cc
@@ -67,8 +67,33 @@ TEST_F(VideoProcessorIntegrationTestOpenH264, Process0PercentPacketLossH264) {
QualityThresholds quality_thresholds(35.0, 25.0, 0.93, 0.70);
- ProcessFramesAndMaybeVerify(rate_profile, &rc_thresholds, &quality_thresholds,
- kNoVisualizationParams);
+ ProcessFramesAndMaybeVerify(rate_profile, &rc_thresholds,
+ &quality_thresholds, nullptr, kNoVisualizationParams);
+}
+
+// H264: Enable SingleNalUnit packetization mode. Encoder should split
+// large frames into multiple slices and limit length of NAL units.
+TEST_F(VideoProcessorIntegrationTestOpenH264, ProcessNoLossSingleNalUnitH264) {
+ config_.packetization_mode = H264PacketizationMode::SingleNalUnit;
+ config_.networking_config.max_payload_size_in_bytes = 500;
+ SetCodecSettings(&config_, kVideoCodecH264, 1, false, false, true, false,
+ kResilienceOn, kCifWidth, kCifHeight);
+
+ RateProfile rate_profile;
+ SetRateProfile(&rate_profile, 0, 500, 30, 0);
+ rate_profile.frame_index_rate_update[1] = kNumFrames + 1;
+ rate_profile.num_frames = kNumFrames;
+
+ std::vector<RateControlThresholds> rc_thresholds;
+ AddRateControlThresholds(2, 60, 30, 10, 20, 0, 1, &rc_thresholds);
+
+ QualityThresholds quality_thresholds(35.0, 25.0, 0.93, 0.70);
+
+ BitstreamThresholds bs_thresholds(
+ config_.networking_config.max_payload_size_in_bytes);
+
+ ProcessFramesAndMaybeVerify(rate_profile, &rc_thresholds,
+ &quality_thresholds, &bs_thresholds, kNoVisualizationParams);
}
#endif // defined(WEBRTC_USE_H264)

Powered by Google App Engine
This is Rietveld 408576698