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

Side by Side Diff: components/mus/surfaces/direct_output_surface_ozone.cc

Issue 2102203003: Color: Plumb color profile from ui::Compositor to cc::DirectRenderer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase on top of s/ColorProfile/ColorSpace/ Created 4 years, 5 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/mus/surfaces/direct_output_surface_ozone.h" 5 #include "components/mus/surfaces/direct_output_surface_ozone.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/memory/ptr_util.h" 10 #include "base/memory/ptr_util.h"
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
149 return buffer_queue_->internal_format(); 149 return buffer_queue_->internal_format();
150 } 150 }
151 151
152 // We call this on every frame but changing the size once we've allocated 152 // We call this on every frame but changing the size once we've allocated
153 // backing NativePixmapOzone instances will cause a DCHECK because 153 // backing NativePixmapOzone instances will cause a DCHECK because
154 // Chrome never Reshape(s) after the first one from (0,0). NB: this implies 154 // Chrome never Reshape(s) after the first one from (0,0). NB: this implies
155 // that screen size changes need to be plumbed differently. In particular, we 155 // that screen size changes need to be plumbed differently. In particular, we
156 // must create the native window in the size that the hardware reports. 156 // must create the native window in the size that the hardware reports.
157 void DirectOutputSurfaceOzone::Reshape(const gfx::Size& size, 157 void DirectOutputSurfaceOzone::Reshape(const gfx::Size& size,
158 float scale_factor, 158 float scale_factor,
159 const gfx::ColorSpace& color_space,
159 bool alpha) { 160 bool alpha) {
160 OutputSurface::Reshape(size, scale_factor, alpha); 161 OutputSurface::Reshape(size, scale_factor, color_space, alpha);
161 DCHECK(buffer_queue_); 162 DCHECK(buffer_queue_);
162 buffer_queue_->Reshape(SurfaceSize(), scale_factor); 163 buffer_queue_->Reshape(SurfaceSize(), scale_factor);
163 } 164 }
164 165
165 } // namespace mus 166 } // namespace mus
OLDNEW
« no previous file with comments | « components/mus/surfaces/direct_output_surface_ozone.h ('k') | content/browser/compositor/gpu_process_transport_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698