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

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

Issue 2089753003: cc: Use the correct internal format for glCopyTexImage2D calls. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: copytextureformat: comments Created 4 years, 5 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 | « cc/output/gl_renderer_unittest.cc ('k') | cc/output/output_surface_unittest.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 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_OUTPUT_SURFACE_H_ 5 #ifndef CC_OUTPUT_OUTPUT_SURFACE_H_
6 #define CC_OUTPUT_OUTPUT_SURFACE_H_ 6 #define CC_OUTPUT_OUTPUT_SURFACE_H_
7 7
8 #include <deque> 8 #include <deque>
9 #include <memory> 9 #include <memory>
10 10
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 125
126 virtual void Reshape(const gfx::Size& size, float scale_factor, bool alpha); 126 virtual void Reshape(const gfx::Size& size, float scale_factor, bool alpha);
127 gfx::Size SurfaceSize() const { return surface_size_; } 127 gfx::Size SurfaceSize() const { return surface_size_; }
128 float device_scale_factor() const { return device_scale_factor_; } 128 float device_scale_factor() const { return device_scale_factor_; }
129 129
130 // If supported, this causes a ReclaimResources for all resources that are 130 // If supported, this causes a ReclaimResources for all resources that are
131 // currently in use. 131 // currently in use.
132 virtual void ForceReclaimResources() {} 132 virtual void ForceReclaimResources() {}
133 133
134 virtual void BindFramebuffer(); 134 virtual void BindFramebuffer();
135 // Gives the GL internal format that should be used for calling CopyTexImage2D
136 // when the framebuffer is bound via BindFramebuffer().
137 virtual uint32_t GetFramebufferCopyTextureFormat() = 0;
135 138
136 // The implementation may destroy or steal the contents of the CompositorFrame 139 // The implementation may destroy or steal the contents of the CompositorFrame
137 // passed in (though it will not take ownership of the CompositorFrame 140 // passed in (though it will not take ownership of the CompositorFrame
138 // itself). For successful swaps, the implementation must call 141 // itself). For successful swaps, the implementation must call
139 // OutputSurfaceClient::DidSwapBuffers() and eventually 142 // OutputSurfaceClient::DidSwapBuffers() and eventually
140 // DidSwapBuffersComplete(). 143 // DidSwapBuffersComplete().
141 virtual void SwapBuffers(CompositorFrame* frame) = 0; 144 virtual void SwapBuffers(CompositorFrame* frame) = 0;
142 virtual void OnSwapBuffersComplete(); 145 virtual void OnSwapBuffersComplete();
143 146
144 // Called by subclasses after receiving a response from the gpu process to a 147 // Called by subclasses after receiving a response from the gpu process to a
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
202 bool external_stencil_test_enabled_ = false; 205 bool external_stencil_test_enabled_ = false;
203 206
204 base::WeakPtrFactory<OutputSurface> weak_ptr_factory_; 207 base::WeakPtrFactory<OutputSurface> weak_ptr_factory_;
205 208
206 DISALLOW_COPY_AND_ASSIGN(OutputSurface); 209 DISALLOW_COPY_AND_ASSIGN(OutputSurface);
207 }; 210 };
208 211
209 } // namespace cc 212 } // namespace cc
210 213
211 #endif // CC_OUTPUT_OUTPUT_SURFACE_H_ 214 #endif // CC_OUTPUT_OUTPUT_SURFACE_H_
OLDNEW
« no previous file with comments | « cc/output/gl_renderer_unittest.cc ('k') | cc/output/output_surface_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698