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

Side by Side Diff: android_webview/browser/parent_output_surface.cc

Issue 2399983003: cc: Make OutputSurface::Reshape abstract (Closed)
Patch Set: reshapeabstract: . Created 4 years, 2 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
« no previous file with comments | « no previous file | blimp/client/support/compositor/blimp_embedder_compositor.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "android_webview/browser/parent_output_surface.h" 5 #include "android_webview/browser/parent_output_surface.h"
6 6
7 #include "android_webview/browser/aw_render_thread_context_provider.h" 7 #include "android_webview/browser/aw_render_thread_context_provider.h"
8 #include "android_webview/browser/scoped_app_gl_state_restore.h" 8 #include "android_webview/browser/scoped_app_gl_state_restore.h"
9 #include "cc/output/output_surface_client.h" 9 #include "cc/output/output_surface_client.h"
10 #include "cc/output/output_surface_frame.h" 10 #include "cc/output/output_surface_frame.h"
(...skipping 20 matching lines...) Expand all
31 context_provider()->ContextGL()->DiscardBackbufferCHROMIUM(); 31 context_provider()->ContextGL()->DiscardBackbufferCHROMIUM();
32 } 32 }
33 33
34 void ParentOutputSurface::BindFramebuffer() { 34 void ParentOutputSurface::BindFramebuffer() {
35 context_provider()->ContextGL()->BindFramebuffer(GL_FRAMEBUFFER, 0); 35 context_provider()->ContextGL()->BindFramebuffer(GL_FRAMEBUFFER, 0);
36 } 36 }
37 37
38 void ParentOutputSurface::Reshape(const gfx::Size& size, 38 void ParentOutputSurface::Reshape(const gfx::Size& size,
39 float scale_factor, 39 float scale_factor,
40 const gfx::ColorSpace& color_space, 40 const gfx::ColorSpace& color_space,
41 bool has_alpha) { 41 bool has_alpha) {}
42 DCHECK_EQ(1.f, scale_factor);
43 surface_size_ = size;
44 }
45 42
46 void ParentOutputSurface::SwapBuffers(cc::OutputSurfaceFrame frame) { 43 void ParentOutputSurface::SwapBuffers(cc::OutputSurfaceFrame frame) {
47 context_provider_->ContextGL()->ShallowFlushCHROMIUM(); 44 context_provider_->ContextGL()->ShallowFlushCHROMIUM();
48 } 45 }
49 46
50 bool ParentOutputSurface::HasExternalStencilTest() const { 47 bool ParentOutputSurface::HasExternalStencilTest() const {
51 return ScopedAppGLStateRestore::Current() 48 return ScopedAppGLStateRestore::Current()
52 ->stencil_state() 49 ->stencil_state()
53 .stencil_test_enabled; 50 .stencil_test_enabled;
54 } 51 }
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 87
91 unsigned ParentOutputSurface::GetOverlayTextureId() const { 88 unsigned ParentOutputSurface::GetOverlayTextureId() const {
92 return 0; 89 return 0;
93 } 90 }
94 91
95 bool ParentOutputSurface::SurfaceIsSuspendForRecycle() const { 92 bool ParentOutputSurface::SurfaceIsSuspendForRecycle() const {
96 return false; 93 return false;
97 } 94 }
98 95
99 } // namespace android_webview 96 } // namespace android_webview
OLDNEW
« no previous file with comments | « no previous file | blimp/client/support/compositor/blimp_embedder_compositor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698