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

Side by Side Diff: cc/output/renderer.h

Issue 14092003: Add compositor support for the LatencyInfo. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | Annotate | Revision Log
« no previous file with comments | « cc/output/gl_renderer_unittest.cc ('k') | cc/output/software_renderer.h » ('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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 #ifndef CC_OUTPUT_RENDERER_H_ 5 #ifndef CC_OUTPUT_RENDERER_H_
6 #define CC_OUTPUT_RENDERER_H_ 6 #define CC_OUTPUT_RENDERER_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "cc/base/cc_export.h" 9 #include "cc/base/cc_export.h"
10 #include "cc/debug/latency_info.h"
10 #include "cc/quads/render_pass.h" 11 #include "cc/quads/render_pass.h"
11 #include "cc/resources/managed_memory_policy.h" 12 #include "cc/resources/managed_memory_policy.h"
12 #include "cc/trees/layer_tree_host.h" 13 #include "cc/trees/layer_tree_host.h"
13 14
14 namespace cc { 15 namespace cc {
15 16
16 class CompositorFrameAck; 17 class CompositorFrameAck;
17 class CompositorFrameMetadata; 18 class CompositorFrameMetadata;
18 class ScopedResource; 19 class ScopedResource;
19 20
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 // This passes ownership of the render passes to the renderer. It should 57 // This passes ownership of the render passes to the renderer. It should
57 // consume them, and empty the list. 58 // consume them, and empty the list.
58 virtual void DrawFrame(RenderPassList* render_passes_in_draw_order) = 0; 59 virtual void DrawFrame(RenderPassList* render_passes_in_draw_order) = 0;
59 60
60 // Waits for rendering to finish. 61 // Waits for rendering to finish.
61 virtual void Finish() = 0; 62 virtual void Finish() = 0;
62 63
63 virtual void DoNoOp() {} 64 virtual void DoNoOp() {}
64 65
65 // Puts backbuffer onscreen. 66 // Puts backbuffer onscreen.
66 virtual bool SwapBuffers() = 0; 67 virtual bool SwapBuffers(const LatencyInfo& latency_info) = 0;
67 68
68 virtual void GetFramebufferPixels(void* pixels, gfx::Rect rect) = 0; 69 virtual void GetFramebufferPixels(void* pixels, gfx::Rect rect) = 0;
69 70
70 virtual bool IsContextLost(); 71 virtual bool IsContextLost();
71 72
72 virtual void SetVisible(bool visible) = 0; 73 virtual void SetVisible(bool visible) = 0;
73 74
74 virtual void SendManagedMemoryStats(size_t bytes_visible, 75 virtual void SendManagedMemoryStats(size_t bytes_visible,
75 size_t bytes_visible_and_nearby, 76 size_t bytes_visible_and_nearby,
76 size_t bytes_allocated) = 0; 77 size_t bytes_allocated) = 0;
77 78
78 protected: 79 protected:
79 explicit Renderer(RendererClient* client) 80 explicit Renderer(RendererClient* client)
80 : client_(client) {} 81 : client_(client) {}
81 82
82 RendererClient* client_; 83 RendererClient* client_;
83 84
84 DISALLOW_COPY_AND_ASSIGN(Renderer); 85 DISALLOW_COPY_AND_ASSIGN(Renderer);
85 }; 86 };
86 87
87 } // namespace cc 88 } // namespace cc
88 89
89 #endif // CC_OUTPUT_RENDERER_H_ 90 #endif // CC_OUTPUT_RENDERER_H_
OLDNEW
« no previous file with comments | « cc/output/gl_renderer_unittest.cc ('k') | cc/output/software_renderer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698