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

Unified Diff: services/ui/ws/display_client_compositor_frame_sink.cc

Issue 2888043004: [cc] Add and plumb CFS::DidNotProduceFrame. (Closed)
Patch Set: Created 3 years, 7 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: services/ui/ws/display_client_compositor_frame_sink.cc
diff --git a/services/ui/ws/display_client_compositor_frame_sink.cc b/services/ui/ws/display_client_compositor_frame_sink.cc
index a7972df07a4d47e9945caa21eeee7fcfd4ad8499..18b64f0070ce30ae8b0765af4bb4f4f5692a64e4 100644
--- a/services/ui/ws/display_client_compositor_frame_sink.cc
+++ b/services/ui/ws/display_client_compositor_frame_sink.cc
@@ -48,6 +48,7 @@ void DisplayClientCompositorFrameSink::SubmitCompositorFrame(
if (!compositor_frame_sink_)
return;
+ DCHECK(frame.metadata.begin_frame_ack.has_damage);
DCHECK_LE(cc::BeginFrameArgs::kStartingFrameNumber,
frame.metadata.begin_frame_ack.sequence_number);
@@ -65,6 +66,13 @@ void DisplayClientCompositorFrameSink::SubmitCompositorFrame(
last_submitted_frame_size_ = frame_size;
}
+void DisplayClientCompositorFrameSink::BeginFrameDidNotProduceFrame(
+ const cc::BeginFrameAck& ack) {
+ DCHECK(!ack.has_damage);
+ DCHECK_LE(cc::BeginFrameArgs::kStartingFrameNumber, ack.sequence_number);
+ compositor_frame_sink_->BeginFrameDidNotProduceFrame(ack);
+}
+
void DisplayClientCompositorFrameSink::DidReceiveCompositorFrameAck(
const cc::ReturnedResourceArray& resources) {
DCHECK(thread_checker_->CalledOnValidThread());
@@ -95,11 +103,7 @@ void DisplayClientCompositorFrameSink::OnNeedsBeginFrames(
}
void DisplayClientCompositorFrameSink::OnDidFinishFrame(
- const cc::BeginFrameAck& ack) {
- // If there was damage, the submitted CompositorFrame includes the ack.
- if (!ack.has_damage)
- compositor_frame_sink_->BeginFrameDidNotSwap(ack);
-}
+ const cc::BeginFrameAck& ack) {}
} // namespace ws
} // namespace ui

Powered by Google App Engine
This is Rietveld 408576698