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

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

Issue 14273026: cc: Make async readback path use async glRreadPixels. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: There, I fixed it 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 | « no previous file | cc/output/direct_renderer.cc » ('j') | cc/output/gl_renderer.h » ('J')
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_DIRECT_RENDERER_H_ 5 #ifndef CC_OUTPUT_DIRECT_RENDERER_H_
6 #define CC_OUTPUT_DIRECT_RENDERER_H_ 6 #define CC_OUTPUT_DIRECT_RENDERER_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/callback.h"
9 #include "cc/base/cc_export.h" 10 #include "cc/base/cc_export.h"
10 #include "cc/output/renderer.h" 11 #include "cc/output/renderer.h"
11 #include "cc/resources/resource_provider.h" 12 #include "cc/resources/resource_provider.h"
12 #include "cc/resources/scoped_resource.h" 13 #include "cc/resources/scoped_resource.h"
13 14
14 namespace cc { 15 namespace cc {
15 16
16 class ResourceProvider; 17 class ResourceProvider;
17 18
18 // This is the base class for code shared between the GL and software 19 // This is the base class for code shared between the GL and software
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 virtual void SetDrawViewportSize(gfx::Size viewport_size) = 0; 103 virtual void SetDrawViewportSize(gfx::Size viewport_size) = 0;
103 virtual void SetScissorTestRect(gfx::Rect scissor_rect) = 0; 104 virtual void SetScissorTestRect(gfx::Rect scissor_rect) = 0;
104 virtual void ClearFramebuffer(DrawingFrame* frame) = 0; 105 virtual void ClearFramebuffer(DrawingFrame* frame) = 0;
105 virtual void DoDrawQuad(DrawingFrame* frame, const DrawQuad* quad) = 0; 106 virtual void DoDrawQuad(DrawingFrame* frame, const DrawQuad* quad) = 0;
106 virtual void BeginDrawingFrame(DrawingFrame* frame) = 0; 107 virtual void BeginDrawingFrame(DrawingFrame* frame) = 0;
107 virtual void FinishDrawingFrame(DrawingFrame* frame) = 0; 108 virtual void FinishDrawingFrame(DrawingFrame* frame) = 0;
108 virtual void FinishDrawingQuadList(); 109 virtual void FinishDrawingQuadList();
109 virtual bool FlippedFramebuffer() const = 0; 110 virtual bool FlippedFramebuffer() const = 0;
110 virtual void EnsureScissorTestEnabled() = 0; 111 virtual void EnsureScissorTestEnabled() = 0;
111 virtual void EnsureScissorTestDisabled() = 0; 112 virtual void EnsureScissorTestDisabled() = 0;
112 virtual void CopyCurrentRenderPassToBitmap(DrawingFrame* frame, 113
113 SkBitmap* bitmap) = 0; 114 typedef base::Callback<void(scoped_ptr<SkBitmap>)>
115 CopyRenderPassCallback;
116 virtual void CopyCurrentRenderPassToBitmap(
117 DrawingFrame* frame,
118 const CopyRenderPassCallback& callback) = 0;
114 119
115 ScopedPtrHashMap<RenderPass::Id, CachedResource> render_pass_textures_; 120 ScopedPtrHashMap<RenderPass::Id, CachedResource> render_pass_textures_;
116 ResourceProvider* resource_provider_; 121 ResourceProvider* resource_provider_;
117 122
118 private: 123 private:
119 gfx::Vector2d enlarge_pass_texture_amount_; 124 gfx::Vector2d enlarge_pass_texture_amount_;
120 125
121 DISALLOW_COPY_AND_ASSIGN(DirectRenderer); 126 DISALLOW_COPY_AND_ASSIGN(DirectRenderer);
122 }; 127 };
123 128
124 } // namespace cc 129 } // namespace cc
125 130
126 #endif // CC_OUTPUT_DIRECT_RENDERER_H_ 131 #endif // CC_OUTPUT_DIRECT_RENDERER_H_
OLDNEW
« no previous file with comments | « no previous file | cc/output/direct_renderer.cc » ('j') | cc/output/gl_renderer.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698