Commit 13eae200 authored by Yuri Wiitala's avatar Yuri Wiitala Committed by Commit Bot

Add cross-site tab capture test, and fix an OnFrameDamaged() assumption.

Adds a browser test to confirm that tab capture grabs all content and
content updates when cross-site render process isolation is turned on.

The addition of this test revealed a pre-existing bug where the consumer
would not get a video frame for updated content. This happened whenever
OnFrameDamaged() was being called before OnBeginFrame() (which can
happen when Surfaces are changed).

Bug: 808718
Cq-Include-Trybots: master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_mojo
Change-Id: Ic965ece20d4c40eb65cdb78452148283935e5184
Reviewed-on: https://chromium-review.googlesource.com/936661Reviewed-by: default avatarXiangjun Zhang <xjz@chromium.org>
Commit-Queue: Yuri Wiitala <miu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#539806}
parent 5445ad6b
...@@ -366,9 +366,13 @@ void FrameSinkVideoCapturerImpl::OnFrameDamaged(const BeginFrameAck& ack, ...@@ -366,9 +366,13 @@ void FrameSinkVideoCapturerImpl::OnFrameDamaged(const BeginFrameAck& ack,
} }
if (display_time.is_null()) { if (display_time.is_null()) {
// This can sometimes occur for the first few frames when capture starts, // This can sometimes occur for the first few frames when capture starts,
// but should not happen thereafter. // or whenever Surfaces are changed; but should not otherwise happen. If
DLOG(WARNING) << "OnFrameDamaged() called without prior OnBeginFrame()."; // this is too frequent, the oracle will be making suboptimal decisions.
return; VLOG(1)
<< "OnFrameDamaged() called without prior OnBeginFrame() for source_id="
<< ack.source_id << " and sequence_number=" << ack.sequence_number
<< ". Using NOW as a substitute display time.";
display_time = clock_->NowTicks();
} }
if (frame_size == oracle_.source_size()) { if (frame_size == oracle_.source_size()) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment