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

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

Issue 1900993002: Move SharedMemoryLimits out of WebGraphicsContext3DCommandBufferImpl. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@limits
Patch Set: move-limits: types Created 4 years, 8 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 "cc/output/compositor_frame.h" 10 #include "cc/output/compositor_frame.h"
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 } 89 }
90 90
91 bool DirectOutputSurfaceOzone::BindToClient(cc::OutputSurfaceClient* client) { 91 bool DirectOutputSurfaceOzone::BindToClient(cc::OutputSurfaceClient* client) {
92 if (!cc::OutputSurface::BindToClient(client)) 92 if (!cc::OutputSurface::BindToClient(client))
93 return false; 93 return false;
94 94
95 client->SetBeginFrameSource(synthetic_begin_frame_source_.get()); 95 client->SetBeginFrameSource(synthetic_begin_frame_source_.get());
96 96
97 if (capabilities_.uses_default_gl_framebuffer) { 97 if (capabilities_.uses_default_gl_framebuffer) {
98 capabilities_.flipped_output_surface = 98 capabilities_.flipped_output_surface =
99 context_provider()->ContextCapabilities().gpu.flips_vertically; 99 context_provider()->ContextCapabilities().flips_vertically;
100 } 100 }
101 return true; 101 return true;
102 } 102 }
103 103
104 void DirectOutputSurfaceOzone::OnUpdateVSyncParametersFromGpu( 104 void DirectOutputSurfaceOzone::OnUpdateVSyncParametersFromGpu(
105 base::TimeTicks timebase, 105 base::TimeTicks timebase,
106 base::TimeDelta interval) { 106 base::TimeDelta interval) {
107 DCHECK(HasClient()); 107 DCHECK(HasClient());
108 synthetic_begin_frame_source_->OnUpdateVSyncParameters(timebase, interval); 108 synthetic_begin_frame_source_->OnUpdateVSyncParameters(timebase, interval);
109 } 109 }
(...skipping 29 matching lines...) Expand all
139 // must create the native window in the size that the hardware reports. 139 // must create the native window in the size that the hardware reports.
140 void DirectOutputSurfaceOzone::Reshape(const gfx::Size& size, 140 void DirectOutputSurfaceOzone::Reshape(const gfx::Size& size,
141 float scale_factor, 141 float scale_factor,
142 bool alpha) { 142 bool alpha) {
143 OutputSurface::Reshape(size, scale_factor, alpha); 143 OutputSurface::Reshape(size, scale_factor, alpha);
144 DCHECK(output_surface_); 144 DCHECK(output_surface_);
145 output_surface_->Reshape(SurfaceSize(), scale_factor); 145 output_surface_->Reshape(SurfaceSize(), scale_factor);
146 } 146 }
147 147
148 } // namespace mus 148 } // namespace mus
OLDNEW
« no previous file with comments | « components/mus/surfaces/direct_output_surface.cc ('k') | components/mus/surfaces/surfaces_context_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698