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

Side by Side Diff: content/browser/renderer_host/compositor_impl_android.cc

Issue 142863008: Revert of [#7] Pass gfx structs by const ref (gfx::Size) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "content/browser/renderer_host/compositor_impl_android.h" 5 #include "content/browser/renderer_host/compositor_impl_android.h"
6 6
7 #include <android/bitmap.h> 7 #include <android/bitmap.h>
8 #include <android/native_window_jni.h> 8 #include <android/native_window_jni.h>
9 #include <map> 9 #include <map>
10 10
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 53
54 // Used for drawing directly to the screen. Bypasses resizing and swaps. 54 // Used for drawing directly to the screen. Bypasses resizing and swaps.
55 class DirectOutputSurface : public cc::OutputSurface { 55 class DirectOutputSurface : public cc::OutputSurface {
56 public: 56 public:
57 DirectOutputSurface( 57 DirectOutputSurface(
58 const scoped_refptr<cc::ContextProvider>& context_provider) 58 const scoped_refptr<cc::ContextProvider>& context_provider)
59 : cc::OutputSurface(context_provider) { 59 : cc::OutputSurface(context_provider) {
60 capabilities_.adjust_deadline_for_parent = false; 60 capabilities_.adjust_deadline_for_parent = false;
61 } 61 }
62 62
63 virtual void Reshape(const gfx::Size& size, float scale_factor) OVERRIDE { 63 virtual void Reshape(gfx::Size size, float scale_factor) OVERRIDE {
64 surface_size_ = size; 64 surface_size_ = size;
65 } 65 }
66 virtual void SwapBuffers(cc::CompositorFrame*) OVERRIDE { 66 virtual void SwapBuffers(cc::CompositorFrame*) OVERRIDE {
67 context_provider_->ContextGL()->ShallowFlushCHROMIUM(); 67 context_provider_->ContextGL()->ShallowFlushCHROMIUM();
68 } 68 }
69 }; 69 };
70 70
71 // Used to override capabilities_.adjust_deadline_for_parent to false 71 // Used to override capabilities_.adjust_deadline_for_parent to false
72 class OutputSurfaceWithoutParent : public cc::OutputSurface { 72 class OutputSurfaceWithoutParent : public cc::OutputSurface {
73 public: 73 public:
(...skipping 414 matching lines...) Expand 10 before | Expand all | Expand 10 after
488 default: 488 default:
489 return GL_UNSIGNED_SHORT_5_6_5; 489 return GL_UNSIGNED_SHORT_5_6_5;
490 } 490 }
491 } 491 }
492 492
493 void CompositorImpl::DidCommit() { 493 void CompositorImpl::DidCommit() {
494 root_window_->OnCompositingDidCommit(); 494 root_window_->OnCompositingDidCommit();
495 } 495 }
496 496
497 } // namespace content 497 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/compositor/software_output_device_win.cc ('k') | content/renderer/gpu/compositor_software_output_device.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698