Screen content simulcast layers should not be downscaled.
Fix config so, size isn't downscaled, add unit test coverage. BUG=webrtc:7171, webrtc:4172 Review-Url: https://codereview.webrtc.org/2692343007 Cr-Commit-Position: refs/heads/master@{#16648}
This commit is contained in:
@ -230,8 +230,10 @@ std::vector<webrtc::VideoStream> GetSimulcastConfig(size_t max_streams,
|
||||
streams[s].max_framerate = max_framerate;
|
||||
}
|
||||
|
||||
if (!is_screencast) {
|
||||
width /= 2;
|
||||
height /= 2;
|
||||
}
|
||||
if (s == 0)
|
||||
break;
|
||||
}
|
||||
|
||||
@ -4124,6 +4124,13 @@ class WebRtcVideoChannel2SimulcastTest : public testing::Test {
|
||||
expected_streams = GetSimulcastConfig(
|
||||
num_configured_streams, capture_width, capture_height, 0,
|
||||
kDefaultQpMax, kDefaultVideoMaxFramerate, screenshare);
|
||||
if (screenshare) {
|
||||
for (const webrtc::VideoStream& stream : expected_streams) {
|
||||
// Never scale screen content.
|
||||
EXPECT_EQ(stream.width, capture_width);
|
||||
EXPECT_EQ(stream.height, capture_height);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
webrtc::VideoStream stream;
|
||||
stream.width = capture_width;
|
||||
|
||||
Reference in New Issue
Block a user