> The instinct to have one "MirRenderSurface thing is good. But I think that
> mf::BufferStreamId is really the concept that's being looked for. All 3
> client-facing concepts are represented by mf::BufferStreamId in the end.
And this fits in well, esp in light of how multiple surfaces are arranged in MirSurfaceSpec.
If you add
void mir_surface_spec_add_render_surface(MirSurfaceSpec*, MirRenderSurface*, int width, int height, int displacement_x, int displacement_y);
then if a user wanted to make a multi-content MirSurface, this would be easy to do both from the client api perspective, and from Mir's perspective internally.
Client perspective:
EG, making a french/italian/mexican/etc 3-bar-style-flag from the 3 components:
Mir's internal perspective:
mir_surface_spec_add_* will just add mf::BufferStreamId to the request. The server doesn't have to know what sort of client construct is present, as its all boiled down to NBS rpc transactions.
> The instinct to have one "MirRenderSurface thing is good. But I think that
> mf::BufferStreamId is really the concept that's being looked for. All 3
> client-facing concepts are represented by mf::BufferStreamId in the end.
And this fits in well, esp in light of how multiple surfaces are arranged in MirSurfaceSpec.
If you add spec_add_ render_ surface( MirSurfaceSpec* , MirRenderSurface*, int width, int height, int displacement_x, int displacement_y);
void mir_surface_
to the two functions for BS and PC: bazaar. launchpad. net/~mir- team/mir/ development- branch/ view/head: /src/include/ client/ mir_toolkit/ mir_presentatio n_chain. h#L122
http://
then if a user wanted to make a multi-content MirSurface, this would be easy to do both from the client api perspective, and from Mir's perspective internally.
Client perspective: italian/ mexican/ etc 3-bar-style-flag from the 3 components:
EG, making a french/
int bar_height = 200, bar_width = 200; create_ spec_for_ normal_ surface( connection, full_width, full_height, format); Chain* chain = mir_connection_ create_ presentation_ chain_sync( connection) ; create_ buffer_ stream( connection, bar_width, bar_height, format, usage); create_ render_ surface_ sync(connection ); spec_add_ presentation_ chain(spec, bar_width, bar_height, 0, 0, chain); spec_add_ buffer_ stream( spec, bar_width, 0, stream) spec_add_ render_ surface( spec, rs, bar_width, bar_height, 2*bar_width, 0); create_ sync(spec) ;
int full_width = 3 * bar_width, full_height = bar_height;
MirSurfaceSpec* spec = mir_connection_
MirPresentation
MirBufferStream* stream = mir_connection_
MirRenderSurface* rs = mir_connection_
mir_surface_
mir_surface_
mir_surface_
MirSurface* surface = mir_surface_
Mir's internal perspective: spec_add_ * will just add mf::BufferStreamId to the request. The server doesn't have to know what sort of client construct is present, as its all boiled down to NBS rpc transactions.
mir_surface_