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

Side by Side Diff: cc/test/fake_output_surface.h

Issue 885443002: Roll Chrome into Mojo. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Rebase to ToT mojo Created 5 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
« no previous file with comments | « cc/test/data/scaled_render_surface_layer_sw.png ('k') | cc/test/fake_output_surface.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_TEST_FAKE_OUTPUT_SURFACE_H_ 5 #ifndef CC_TEST_FAKE_OUTPUT_SURFACE_H_
6 #define CC_TEST_FAKE_OUTPUT_SURFACE_H_ 6 #define CC_TEST_FAKE_OUTPUT_SURFACE_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/time/time.h" 10 #include "base/time/time.h"
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 return surface.Pass(); 89 return surface.Pass();
90 } 90 }
91 91
92 CompositorFrame& last_sent_frame() { return last_sent_frame_; } 92 CompositorFrame& last_sent_frame() { return last_sent_frame_; }
93 size_t num_sent_frames() { return num_sent_frames_; } 93 size_t num_sent_frames() { return num_sent_frames_; }
94 94
95 void SwapBuffers(CompositorFrame* frame) override; 95 void SwapBuffers(CompositorFrame* frame) override;
96 96
97 bool BindToClient(OutputSurfaceClient* client) override; 97 bool BindToClient(OutputSurfaceClient* client) override;
98 98
99 void set_framebuffer(unsigned framebuffer) { framebuffer_ = framebuffer; }
100 void BindFramebuffer() override;
101
99 using OutputSurface::ReleaseGL; 102 using OutputSurface::ReleaseGL;
100 using OutputSurface::InitializeAndSetContext3d; 103 using OutputSurface::InitializeAndSetContext3d;
101 104
102 void SetTreeActivationCallback(const base::Closure& callback); 105 void SetTreeActivationCallback(const base::Closure& callback);
103 106
104 const TransferableResourceArray& resources_held_by_parent() { 107 const TransferableResourceArray& resources_held_by_parent() {
105 return resources_held_by_parent_; 108 return resources_held_by_parent_;
106 } 109 }
107 110
108 void ReturnResource(unsigned id, CompositorFrameAck* ack); 111 void ReturnResource(unsigned id, CompositorFrameAck* ack);
(...skipping 22 matching lines...) Expand all
131 134
132 FakeOutputSurface( 135 FakeOutputSurface(
133 scoped_refptr<ContextProvider> context_provider, 136 scoped_refptr<ContextProvider> context_provider,
134 scoped_ptr<SoftwareOutputDevice> software_device, 137 scoped_ptr<SoftwareOutputDevice> software_device,
135 bool delegated_rendering); 138 bool delegated_rendering);
136 139
137 OutputSurfaceClient* client_; 140 OutputSurfaceClient* client_;
138 CompositorFrame last_sent_frame_; 141 CompositorFrame last_sent_frame_;
139 size_t num_sent_frames_; 142 size_t num_sent_frames_;
140 bool has_external_stencil_test_; 143 bool has_external_stencil_test_;
144 unsigned framebuffer_;
141 TransferableResourceArray resources_held_by_parent_; 145 TransferableResourceArray resources_held_by_parent_;
142 scoped_ptr<ManagedMemoryPolicy> memory_policy_to_set_at_bind_; 146 scoped_ptr<ManagedMemoryPolicy> memory_policy_to_set_at_bind_;
143 gfx::Rect last_swap_rect_; 147 gfx::Rect last_swap_rect_;
144 }; 148 };
145 149
146 } // namespace cc 150 } // namespace cc
147 151
148 #endif // CC_TEST_FAKE_OUTPUT_SURFACE_H_ 152 #endif // CC_TEST_FAKE_OUTPUT_SURFACE_H_
OLDNEW
« no previous file with comments | « cc/test/data/scaled_render_surface_layer_sw.png ('k') | cc/test/fake_output_surface.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698