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

Side by Side Diff: content/browser/compositor/gpu_browser_compositor_output_surface.h

Issue 161413002: Revert of Read compositor VSync information from platform, when possible (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
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 | Annotate | Revision Log
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 #ifndef CONTENT_BROWSER_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ 5 #ifndef CONTENT_BROWSER_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_
6 #define CONTENT_BROWSER_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ 6 #define CONTENT_BROWSER_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_
7 7
8 #include "content/browser/compositor/browser_compositor_output_surface.h" 8 #include "content/browser/compositor/browser_compositor_output_surface.h"
9 9
10 namespace ui {
11 class CompositorVSyncManager;
12 }
13
14 namespace content { 10 namespace content {
15 11
16 // Adapts a WebGraphicsContext3DCommandBufferImpl into a 12 // Adapts a WebGraphicsContext3DCommandBufferImpl into a
17 // cc::OutputSurface that also handles vsync parameter updates 13 // cc::OutputSurface that also handles vsync parameter updates
18 // arriving from the GPU process. 14 // arriving from the GPU process.
19 class GpuBrowserCompositorOutputSurface 15 class GpuBrowserCompositorOutputSurface
20 : public BrowserCompositorOutputSurface { 16 : public BrowserCompositorOutputSurface {
21 public: 17 public:
22 GpuBrowserCompositorOutputSurface( 18 GpuBrowserCompositorOutputSurface(
23 const scoped_refptr<ContextProviderCommandBuffer>& context, 19 const scoped_refptr<ContextProviderCommandBuffer>& context,
24 int surface_id, 20 int surface_id,
25 IDMap<BrowserCompositorOutputSurface>* output_surface_map, 21 IDMap<BrowserCompositorOutputSurface>* output_surface_map,
26 const scoped_refptr<ui::CompositorVSyncManager>& vsync_manager); 22 base::MessageLoopProxy* compositor_message_loop,
23 base::WeakPtr<ui::Compositor> compositor);
27 24
28 virtual ~GpuBrowserCompositorOutputSurface(); 25 virtual ~GpuBrowserCompositorOutputSurface();
29 26
30 private: 27 private:
31 // cc::OutputSurface implementation. 28 // cc::OutputSurface implementation.
32 virtual void SwapBuffers(cc::CompositorFrame* frame) OVERRIDE; 29 virtual void SwapBuffers(cc::CompositorFrame* frame) OVERRIDE;
33 30
34 DISALLOW_COPY_AND_ASSIGN(GpuBrowserCompositorOutputSurface); 31 DISALLOW_COPY_AND_ASSIGN(GpuBrowserCompositorOutputSurface);
35 }; 32 };
36 33
37 } // namespace content 34 } // namespace content
38 35
39 #endif // CONTENT_BROWSER_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_ 36 #endif // CONTENT_BROWSER_COMPOSITOR_GPU_BROWSER_COMPOSITOR_OUTPUT_SURFACE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698