Mir

Merge lp:~kdub/mir/surface-buffer-access into lp:mir

Proposed by Kevin DuBois on 2015-05-13
Status: Merged
Approved by: Alexandros Frantzis on 2015-06-02
Approved revision: 2576
Merged at revision: 2608
Proposed branch: lp:~kdub/mir/surface-buffer-access
Merge into: lp:mir
Diff against target: 353 lines (+31/-105)
12 files modified
include/server/mir/scene/surface.h (+1/-3)
include/server/mir/scene/surface_buffer_access.h (+0/-50)
src/server/scene/application_session.cpp (+14/-4)
src/server/scene/basic_surface.cpp (+0/-7)
src/server/scene/basic_surface.h (+0/-3)
src/server/scene/snapshot_strategy.h (+2/-2)
src/server/scene/threaded_snapshot_strategy.cpp (+3/-3)
src/server/scene/threaded_snapshot_strategy.h (+1/-1)
src/server/symbols.map (+0/-6)
tests/include/mir_test_doubles/null_snapshot_strategy.h (+1/-1)
tests/unit-tests/scene/test_application_session.cpp (+6/-6)
tests/unit-tests/scene/test_threaded_snapshot_strategy.cpp (+3/-19)
To merge this branch: bzr merge lp:~kdub/mir/surface-buffer-access
Reviewer Review Type Date Requested Status
Kevin DuBois (community) Abstain on 2015-06-01
Alan Griffiths Approve on 2015-06-01
PS Jenkins bot continuous-integration Approve on 2015-05-29
Alexandros Frantzis (community) Abstain on 2015-05-29
Robert Carr (community) Approve on 2015-05-27
Review via email: mp+259049@code.launchpad.net

Commit Message

Have the mf::BufferStream interface inherit from the ms::SurfaceBufferAccess interface, as the streams are what have the buffers, not the Surfaces. (previously ms::Surface inherited from the interface). This gets rid of the pass-through function in surface, as well as makes it more obvious about which buffer is being accessed (as surfaces already have some cursor buffers and client buffers, and will soon have more than one stream).

Also rename the interface from "SurfaceBufferAccess" to just BufferAccess.

Description of the Change

Have the mf::BufferStream interface inherit from the ms::SurfaceBufferAccess interface, as the streams are what have the buffers, not the Surfaces. (previously ms::Surface inherited from the interface). This gets rid of the pass-through function in surface, as well as makes it more obvious about which buffer is being accessed (as surfaces already have some cursor buffers and client buffers, and will soon have more than one stream).

Also rename the interface from "SurfaceBufferAccess" to just BufferAccess.

To post a comment you must log in.
Kevin DuBois (kdub) wrote :

IIRC, SurfaceBufferAccess was originally created to avoid the snapshotting code from having access to the full Surface interface just to take a snapshot. Now that the concepts have been teased out a bit, I wouldn't mind just having the snapshotting code take a ptr to mf::BufferStream. mf::BufferStream already has a 'with_most_recent_buffer_do" function on it, so removing the interface would just have the effect of giving the screenshotting code a wider interface.

Removal has been talked about in previous relevant discussions:
https://code.launchpad.net/~kdub/mir/surface-interface-reductions/+merge/258493
https://code.launchpad.net/~vanvugt/mir/no-SurfaceBufferAccess/+merge/238376

So, needs-info from the team on the question "should I just remove BufferAcccess?". The part I need to address in the card I'm working on is the inheritance, but removing the interface altogether seems a nice cleanup.

review: Needs Information
Alexandros Frantzis (afrantzis) wrote :

> So, needs-info from the team on the question "should I just remove BufferAcccess?".
> The part I need to address in the card I'm working on is the inheritance, but
> removing the interface altogether seems a nice cleanup.

If I have understood the plan correctly, a surface is going to consist of potentially multiple bufferstreams for content (plus other bufferstreams for decoration, but we don't care about them here). So if we want a proper snapshot, the snapshotting code will need to access multiple buffers and should be able to perform some kind of basic blending to provide the final image. In order to combine the buffers, it will at least need to know their positions, so passing buffer streams to the snapshotting code is not enough.

If this is indeed the way we are heading, we probably still need some kind of function at the Surface/BufferAcccess level, like with_most_recent_buffers_do(<std::function accepting vector of buffers+positions>) or with_most_recent_renderables_do(...).

Since the snapshotting code is becoming more complicated (need to combine buffers etc), it's worth ensuring that our downstreams still find it useful and there is no easier alternative they can pursue. I will talk to Gerry about this.

review: Needs Information
Alexandros Frantzis (afrantzis) wrote :

> If this is indeed the way we are heading, we probably still need some kind of function at the
> Surface/BufferAcccess level, like with_most_recent_buffers_do(<std::function accepting vector of
> buffers+positions>) or with_most_recent_renderables_do(...).

Even if we drop the wrap-around idiom and opt for a different/direct approach, the function will still need to be at the Surface level, and a separate interface (like BufferAccess) will still be preferable.

Daniel van Vugt (vanvugt) wrote :

This is not a review so I won't block anyone with tangential thoughts... But I would prefer to see us use a design that doesn't have the word "Access" as the primary noun in a class name. "Access" is too vague a word and doesn't give the reader any hint of what the class might be for. It's one of those cases where the class name is so useless you just have to treat the name as opaque and infer meaning from the implementation/context instead.

Kevin DuBois (kdub) wrote :

@Alexandros, (recap of irc discussion)
The goal is to have take a snapshot of the Surface, including all bufferstreams contained. We'll avoid having a Surface::get_all_the_streams() function by shifting the SnapshotStrategy from the ApplicationSession to the Surface. The snapshot strategy will shift from getting one stream to getting all the streams comprising the surface (still via wrap-around).

@Daniel,
I think its a good point that every interface provides access to something, and that tagging Access on the end is about the same as tagging Interface on the end... will see if I can come up with a better name while I'm renaming anyways

lp:~kdub/mir/surface-buffer-access updated on 2015-05-14
2574. By Kevin DuBois on 2015-05-14

use StreamDepiction instead of BufferAccess as the name of the interface

Alan Griffiths (alan-griffiths) wrote :

17 +class BufferStream : public scene::StreamDepiction

It seems the wrong way around for a frontend interface to be extending a scene interface.

Its pre-existing but probably contributes to this oddity that this BufferStream interface is wrong - its isn't specifying the requirements of frontend. Vis:

    virtual void add_observer(std::shared_ptr<scene::SurfaceObserver> const& observer) = 0;
    virtual void remove_observer(std::weak_ptr<scene::SurfaceObserver> const& observer) = 0;

these functions are not needed by frontend.

I don't think we need scene::StreamDepiction (we might need a scene BufferStream : public frontend::BufferStream to fix the existing mess - but that's a separate discussion).

Anything I'm missing in this analysis?

review: Needs Information
Robert Carr (robertcarr) wrote :

"mga::BufferAccess::write"

->

"mga::StreamDepiction::write

I think we've gone from a name that makes sense to one which is obviously wrong in order to placate review suggestions that add nothing besides being hard to prove incorrect.

Robert Carr (robertcarr) wrote :

s/placate/respect/

Robert Carr (robertcarr) wrote :

LGTM though I think mga::BufferAccess was better than mga::StreamDepiction (scene name change is fine I guess...)

review: Approve
Kevin DuBois (kdub) wrote :

@bufferstream analysis, the current structure is a bit funny if you look at it in a vacuum, but given the history, we've at least got all the buffer-stream-ish functionality grouped together now in the "mc::BufferStream : mf::BufferStream : ms::StreamDepiction" structure. a ms::Surface : ms::SurfaceBufferAccess doesn't make much sense ever since we split the streams and the surfaces into different objects.

I did try to "flip it" to "mc::BufferStream : ms::StreamDepiction : mf::BufferStream", but the server api gives has more mf::BufferStreams (eg in the Session), so flipping means that we have shift those interfaces around too (for only the benefit of the snapshotting code, really). I'd be fine collapsing the function into mf::BufferStream (as mf::BufferStream has somewhat become the 'public face' of the streams for the server API).

So, I'd be fine with any of:
1) collapsing the only function into mf::BufferStream
2) renaming to StreamDepiction (or any other clever name)
3) dropping "Surface" from "SurfaceBufferAccess", as the interface doesn't have anything to do with surfaces anymore really
in order to resolve the standing structural question of 'which stream's buffer should SurfaceBufferAccess access?'

Alan Griffiths (alan-griffiths) wrote :

> So, I'd be fine with any of:
> 1) collapsing the only function into mf::BufferStream

That seems least bad to me. It is in line with the preexisting problem with this class hierarchy. (Which I wasn't suggesting you fix for this MP.)

Alexandros Frantzis (afrantzis) wrote :

Ideally I would like us to keep a narrow interface for BufferAccess/StreamDepiction to be used by the snapshotting code. However, I won't block on it, because:

1. I hope the snapshotting code will go away in the short/medium-term (replaced by Qt code in qtmir)
2. *::BufferStream is narrower than Surface, not as hard to mock/stub
3. The hierarchy needs a cleanup, as noted in other comments

review: Abstain
lp:~kdub/mir/surface-buffer-access updated on 2015-05-29
2575. By Kevin DuBois on 2015-05-29

sidestep naming discussion by removing the interface altogether

2576. By Kevin DuBois on 2015-05-29

rollback an overzealous sed command that also changed mga::BufferAccess

Alan Griffiths (alan-griffiths) wrote :

I don't think this gets us to the right place, but it Bob Martin's "boy scouts rule".

review: Approve
Kevin DuBois (kdub) :
review: Abstain

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'include/server/mir/scene/surface.h'
2--- include/server/mir/scene/surface.h 2015-05-19 21:34:34 +0000
3+++ include/server/mir/scene/surface.h 2015-05-29 17:54:05 +0000
4@@ -21,7 +21,6 @@
5
6 #include "mir/graphics/renderable.h"
7 #include "mir/input/surface.h"
8-#include "mir/scene/surface_buffer_access.h"
9 #include "mir/frontend/surface.h"
10
11 #include <vector>
12@@ -39,8 +38,7 @@
13
14 class Surface :
15 public input::Surface,
16- public frontend::Surface,
17- public SurfaceBufferAccess
18+ public frontend::Surface
19 {
20 public:
21 // resolve ambiguous member function names
22
23=== removed file 'include/server/mir/scene/surface_buffer_access.h'
24--- include/server/mir/scene/surface_buffer_access.h 2015-05-11 20:07:43 +0000
25+++ include/server/mir/scene/surface_buffer_access.h 1970-01-01 00:00:00 +0000
26@@ -1,50 +0,0 @@
27-/*
28- * Copyright © 2013-2014 Canonical Ltd.
29- *
30- * This program is free software: you can redistribute it and/or modify it
31- * under the terms of the GNU General Public License version 3,
32- * as published by the Free Software Foundation.
33- *
34- * This program is distributed in the hope that it will be useful,
35- * but WITHOUT ANY WARRANTY; without even the implied warranty of
36- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
37- * GNU General Public License for more details.
38- *
39- * You should have received a copy of the GNU General Public License
40- * along with this program. If not, see <http://www.gnu.org/licenses/>.
41- *
42- * Authored by: Alexandros Frantzis <alexandros.frantzis@canonical.com>
43- */
44-
45-#ifndef MIR_SCENE_SURFACE_BUFFER_ACCESS_H_
46-#define MIR_SCENE_SURFACE_BUFFER_ACCESS_H_
47-
48-#include <functional>
49-
50-namespace mir
51-{
52-namespace graphics
53-{
54-class Buffer;
55-}
56-namespace scene
57-{
58-
59-class SurfaceBufferAccess
60-{
61-public:
62- virtual ~SurfaceBufferAccess() = default;
63-
64- virtual void with_most_recent_buffer_do(
65- std::function<void(graphics::Buffer&)> const& exec) = 0;
66-
67-protected:
68- SurfaceBufferAccess() = default;
69- SurfaceBufferAccess(SurfaceBufferAccess const&) = delete;
70- SurfaceBufferAccess& operator=(SurfaceBufferAccess const&) = delete;
71-};
72-
73-}
74-}
75-
76-#endif /* MIR_SCENE_SURFACE_BUFFER_ACCESS_H_ */
77
78=== modified file 'src/server/scene/application_session.cpp'
79--- src/server/scene/application_session.cpp 2015-05-19 21:34:34 +0000
80+++ src/server/scene/application_session.cpp 2015-05-29 17:54:05 +0000
81@@ -190,10 +190,20 @@
82
83 void ms::ApplicationSession::take_snapshot(SnapshotCallback const& snapshot_taken)
84 {
85- if (auto surface = default_surface())
86- snapshot_strategy->take_snapshot_of(surface, snapshot_taken);
87- else
88- snapshot_taken(Snapshot());
89+ //TODO: taking a snapshot of a session doesn't make much sense. Snapshots can be on surfaces
90+ //or bufferstreams, as those represent some content. A multi-surface session doesn't have enough
91+ //info to cobble together a snapshot buffer without WM info.
92+ for(auto const& surface_it : surfaces)
93+ {
94+ if (default_surface() == surface_it.second)
95+ {
96+ auto id = mf::BufferStreamId(surface_it.first.as_value());
97+ snapshot_strategy->take_snapshot_of(checked_find(id)->second, snapshot_taken);
98+ return;
99+ }
100+ }
101+
102+ snapshot_taken(Snapshot());
103 }
104
105 std::shared_ptr<ms::Surface> ms::ApplicationSession::default_surface() const
106
107=== modified file 'src/server/scene/basic_surface.cpp'
108--- src/server/scene/basic_surface.cpp 2015-05-19 21:34:34 +0000
109+++ src/server/scene/basic_surface.cpp 2015-05-29 17:54:05 +0000
110@@ -361,13 +361,6 @@
111 observers.reception_mode_set_to(mode);
112 }
113
114-void ms::BasicSurface::with_most_recent_buffer_do(
115- std::function<void(mg::Buffer&)> const& exec)
116-{
117- surface_buffer_stream->with_most_recent_buffer_do(exec);
118-}
119-
120-
121 MirSurfaceType ms::BasicSurface::type() const
122 {
123 std::unique_lock<std::mutex> lg(guard);
124
125=== modified file 'src/server/scene/basic_surface.h'
126--- src/server/scene/basic_surface.h 2015-05-19 21:34:34 +0000
127+++ src/server/scene/basic_surface.h 2015-05-29 17:54:05 +0000
128@@ -116,9 +116,6 @@
129 std::unique_ptr<graphics::Renderable> compositor_snapshot(void const* compositor_id) const override;
130 int buffers_ready_for_compositor(void const* compositor_id) const override;
131
132- void with_most_recent_buffer_do(
133- std::function<void(graphics::Buffer&)> const& exec) override;
134-
135 MirSurfaceType type() const override;
136 MirSurfaceState state() const override;
137 int configure(MirSurfaceAttrib attrib, int value) override;
138
139=== modified file 'src/server/scene/snapshot_strategy.h'
140--- src/server/scene/snapshot_strategy.h 2015-05-13 13:07:31 +0000
141+++ src/server/scene/snapshot_strategy.h 2015-05-29 17:54:05 +0000
142@@ -25,9 +25,9 @@
143
144 namespace mir
145 {
146+namespace compositor { class BufferStream; }
147 namespace scene
148 {
149-class SurfaceBufferAccess;
150
151 class SnapshotStrategy
152 {
153@@ -35,7 +35,7 @@
154 virtual ~SnapshotStrategy() = default;
155
156 virtual void take_snapshot_of(
157- std::shared_ptr<SurfaceBufferAccess> const& surface_buffer_access,
158+ std::shared_ptr<compositor::BufferStream> const& surface_buffer_access,
159 SnapshotCallback const& snapshot_taken) = 0;
160
161 protected:
162
163=== modified file 'src/server/scene/threaded_snapshot_strategy.cpp'
164--- src/server/scene/threaded_snapshot_strategy.cpp 2015-05-19 17:17:57 +0000
165+++ src/server/scene/threaded_snapshot_strategy.cpp 2015-05-29 17:54:05 +0000
166@@ -18,7 +18,7 @@
167
168 #include "threaded_snapshot_strategy.h"
169 #include "pixel_buffer.h"
170-#include "mir/scene/surface_buffer_access.h"
171+#include "mir/compositor/buffer_stream.h"
172 #include "mir/thread_name.h"
173
174 #include <deque>
175@@ -35,7 +35,7 @@
176
177 struct WorkItem
178 {
179- std::shared_ptr<SurfaceBufferAccess> const stream;
180+ std::shared_ptr<compositor::BufferStream> const stream;
181 ms::SnapshotCallback const snapshot_taken;
182 };
183
184@@ -123,7 +123,7 @@
185 }
186
187 void ms::ThreadedSnapshotStrategy::take_snapshot_of(
188- std::shared_ptr<SurfaceBufferAccess> const& surface_buffer_access,
189+ std::shared_ptr<compositor::BufferStream> const& surface_buffer_access,
190 SnapshotCallback const& snapshot_taken)
191 {
192 functor->schedule_snapshot(WorkItem{surface_buffer_access, snapshot_taken});
193
194=== modified file 'src/server/scene/threaded_snapshot_strategy.h'
195--- src/server/scene/threaded_snapshot_strategy.h 2015-05-13 13:07:31 +0000
196+++ src/server/scene/threaded_snapshot_strategy.h 2015-05-29 17:54:05 +0000
197@@ -39,7 +39,7 @@
198 ~ThreadedSnapshotStrategy() noexcept;
199
200 void take_snapshot_of(
201- std::shared_ptr<SurfaceBufferAccess> const& surface_buffer_access,
202+ std::shared_ptr<compositor::BufferStream> const& surface_buffer_access,
203 SnapshotCallback const& snapshot_taken);
204
205 private:
206
207=== modified file 'src/server/symbols.map'
208--- src/server/symbols.map 2015-05-21 19:25:51 +0000
209+++ src/server/symbols.map 2015-05-29 17:54:05 +0000
210@@ -106,9 +106,6 @@
211 mir::scene::SessionListener::operator*;
212 mir::scene::SessionListener::?SessionListener*;
213 mir::scene::SessionListener::SessionListener*;
214- mir::scene::SurfaceBufferAccess::operator*;
215- mir::scene::SurfaceBufferAccess::?SurfaceBufferAccess*;
216- mir::scene::SurfaceBufferAccess::SurfaceBufferAccess*;
217 mir::scene::SurfaceConfigurator::operator*;
218 mir::scene::SurfaceConfigurator::?SurfaceConfigurator*;
219 mir::scene::SurfaceConfigurator::SurfaceConfigurator*;
220@@ -302,7 +299,6 @@
221 non-virtual?thunk?to?mir::scene::PromptSessionManager::?PromptSessionManager*;
222 non-virtual?thunk?to?mir::scene::SessionCoordinator::?SessionCoordinator*;
223 non-virtual?thunk?to?mir::scene::SessionListener::?SessionListener*;
224- non-virtual?thunk?to?mir::scene::SurfaceBufferAccess::?SurfaceBufferAccess*;
225 non-virtual?thunk?to?mir::scene::SurfaceConfigurator::?SurfaceConfigurator*;
226 non-virtual?thunk?to?mir::scene::SurfaceCoordinator::?SurfaceCoordinator*;
227 non-virtual?thunk?to?mir::scene::SurfaceObserver::?SurfaceObserver*;
228@@ -391,7 +387,6 @@
229 typeinfo?for?mir::scene::SessionListener;
230 typeinfo?for?mir::scene::Snapshot;
231 typeinfo?for?mir::scene::Surface;
232- typeinfo?for?mir::scene::SurfaceBufferAccess;
233 typeinfo?for?mir::scene::SurfaceConfigurator;
234 typeinfo?for?mir::scene::SurfaceCoordinator;
235 typeinfo?for?mir::scene::SurfaceCreationParameters;
236@@ -449,7 +444,6 @@
237 vtable?for?mir::scene::SessionListener;
238 vtable?for?mir::scene::Snapshot;
239 vtable?for?mir::scene::Surface;
240- vtable?for?mir::scene::SurfaceBufferAccess;
241 vtable?for?mir::scene::SurfaceConfigurator;
242 vtable?for?mir::scene::SurfaceCoordinator;
243 vtable?for?mir::scene::SurfaceCreationParameters;
244
245=== modified file 'tests/include/mir_test_doubles/null_snapshot_strategy.h'
246--- tests/include/mir_test_doubles/null_snapshot_strategy.h 2015-05-13 13:07:31 +0000
247+++ tests/include/mir_test_doubles/null_snapshot_strategy.h 2015-05-29 17:54:05 +0000
248@@ -31,7 +31,7 @@
249 struct NullSnapshotStrategy : public scene::SnapshotStrategy
250 {
251 void take_snapshot_of(
252- std::shared_ptr<scene::SurfaceBufferAccess> const&,
253+ std::shared_ptr<compositor::BufferStream> const&,
254 scene::SnapshotCallback const&)
255 {
256 }
257
258=== modified file 'tests/unit-tests/scene/test_application_session.cpp'
259--- tests/unit-tests/scene/test_application_session.cpp 2015-05-19 21:34:34 +0000
260+++ tests/unit-tests/scene/test_application_session.cpp 2015-05-29 17:54:05 +0000
261@@ -67,7 +67,7 @@
262 ~MockSnapshotStrategy() noexcept {}
263
264 MOCK_METHOD2(take_snapshot_of,
265- void(std::shared_ptr<ms::SurfaceBufferAccess> const&,
266+ void(std::shared_ptr<mc::BufferStream> const&,
267 ms::SnapshotCallback const&));
268 };
269
270@@ -410,20 +410,20 @@
271
272 auto mock_surface = make_mock_surface();
273 NiceMock<MockSurfaceFactory> surface_factory;
274+ MockBufferStreamFactory mock_buffer_stream_factory;
275+ std::shared_ptr<mc::BufferStream> const mock_stream = std::make_shared<mtd::MockBufferStream>();
276+ ON_CALL(mock_buffer_stream_factory, create_buffer_stream(_)).WillByDefault(Return(mock_stream));
277 ON_CALL(surface_factory, create_surface(_,_)).WillByDefault(Return(mock_surface));
278 NiceMock<mtd::MockSurfaceCoordinator> surface_coordinator;
279
280- auto const default_surface_buffer_access =
281- std::static_pointer_cast<ms::SurfaceBufferAccess>(mock_surface);
282 auto const snapshot_strategy = std::make_shared<MockSnapshotStrategy>();
283
284- EXPECT_CALL(*snapshot_strategy,
285- take_snapshot_of(default_surface_buffer_access, _));
286+ EXPECT_CALL(*snapshot_strategy, take_snapshot_of(mock_stream, _));
287
288 ms::ApplicationSession app_session(
289 mt::fake_shared(surface_coordinator),
290 mt::fake_shared(surface_factory),
291- stub_buffer_stream_factory,
292+ mt::fake_shared(mock_buffer_stream_factory),
293 pid, name,
294 snapshot_strategy,
295 std::make_shared<ms::NullSessionListener>(),
296
297=== modified file 'tests/unit-tests/scene/test_threaded_snapshot_strategy.cpp'
298--- tests/unit-tests/scene/test_threaded_snapshot_strategy.cpp 2015-05-13 13:07:31 +0000
299+++ tests/unit-tests/scene/test_threaded_snapshot_strategy.cpp 2015-05-29 17:54:05 +0000
300@@ -18,11 +18,11 @@
301
302 #include "src/server/scene/threaded_snapshot_strategy.h"
303 #include "src/server/scene/pixel_buffer.h"
304-#include "mir/scene/surface_buffer_access.h"
305 #include "mir/graphics/buffer.h"
306
307 #include "mir_test_doubles/stub_buffer.h"
308 #include "mir_test_doubles/null_pixel_buffer.h"
309+#include "mir_test_doubles/stub_buffer_stream.h"
310 #include "mir_test/fake_shared.h"
311 #include "mir_test/wait_condition.h"
312 #include "mir_test/current_thread_name.h"
313@@ -43,22 +43,6 @@
314 namespace
315 {
316
317-class StubSurfaceBufferAccess : public ms::SurfaceBufferAccess
318-{
319-public:
320- ~StubSurfaceBufferAccess() noexcept {}
321-
322- void with_most_recent_buffer_do(
323- std::function<void(mg::Buffer&)> const& exec)
324- {
325- thread_name = mt::current_thread_name();
326- exec(buffer);
327- }
328-
329- mtd::StubBuffer buffer;
330- std::string thread_name;
331-};
332-
333 class MockPixelBuffer : public ms::PixelBuffer
334 {
335 public:
336@@ -72,7 +56,7 @@
337
338 struct ThreadedSnapshotStrategyTest : testing::Test
339 {
340- StubSurfaceBufferAccess buffer_access;
341+ mtd::StubBufferStream buffer_access;
342 };
343
344 }
345@@ -87,7 +71,7 @@
346
347 MockPixelBuffer pixel_buffer;
348
349- EXPECT_CALL(pixel_buffer, fill_from(Ref(buffer_access.buffer)));
350+ EXPECT_CALL(pixel_buffer, fill_from(Ref(*buffer_access.stub_compositor_buffer)));
351 EXPECT_CALL(pixel_buffer, as_argb_8888())
352 .WillOnce(Return(pixels));
353 EXPECT_CALL(pixel_buffer, size())

Subscribers

People subscribed via source and target branches