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

Unified Diff: cc/surfaces/display.cc

Issue 2693723002: cc: Move output color space from DrawingFrame to RenderPass (Closed)
Patch Set: Fix typo Created 3 years, 10 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: cc/surfaces/display.cc
diff --git a/cc/surfaces/display.cc b/cc/surfaces/display.cc
index 5136fc573a725fd53fac2dcc7089a3f542c2997c..0e2c932b38a1bc78fae4a0dacde58621d4885d9e 100644
--- a/cc/surfaces/display.cc
+++ b/cc/surfaces/display.cc
@@ -159,6 +159,8 @@ void Display::Resize(const gfx::Size& size) {
void Display::SetColorSpace(const gfx::ColorSpace& color_space) {
device_color_space_ = color_space;
+ if (aggregator_)
+ aggregator_->SetOutputColorSpace(device_color_space_);
}
void Display::SetOutputIsSecure(bool secure) {
@@ -215,6 +217,7 @@ void Display::InitializeRenderer() {
aggregator_.reset(new SurfaceAggregator(
surface_manager_, resource_provider_.get(), output_partial_list));
aggregator_->set_output_is_secure(output_is_secure_);
+ aggregator_->SetOutputColorSpace(device_color_space_);
}
void Display::UpdateRootSurfaceResourcesLocked() {
@@ -314,7 +317,7 @@ bool Display::DrawAndSwap() {
renderer_->DecideRenderPassAllocationsForFrame(frame.render_pass_list);
renderer_->DrawFrame(&frame.render_pass_list, device_scale_factor_,
- device_color_space_, current_surface_size_);
+ current_surface_size_);
} else {
TRACE_EVENT_INSTANT0("cc", "Draw skipped.", TRACE_EVENT_SCOPE_THREAD);
}

Powered by Google App Engine
This is Rietveld 408576698