Commits on Source (9)
-
Previously renderers were not told when the output (framebuffer they need to draw) size changed. Renderers just pulled that information out from weston_output::current_mode when they happened to need it. This makes some things awkward, like resizing the shadow or intermediate buffers. In fact, Pixman-renderer does not even support resizing its shadow buffer, nor does GL-renderer. DRM-backend has to destroy and re-create the renderer output state anyway, but rdp, x11 and wayland backends would be natural users of resizing API. This commit adds an API for resizing with empty implementations. Actual implementations will be added in following patches for each renderer while moving parts of resizing code from backends into the renderers. No-op renderer needs no implementation. Only wayland-backend has actual resizing code already, and that is made to call the new API. Unfortunately, Pixman and GL renderers differ: one does not blit them while the other does. In order to assert the functionality of each renderer to keep the API consistent, wayland-backend needs to lie to pixman-renderer. That's not new, it already does so in wayland_output_get_shm_buffer() where the 'pm_image' addresses only the interior area instead of the whole buffer. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
86364223 -
This is necessary if you want to resize a Pixman rendered output that uses the shadow. Also reset the current hw_buffer to NULL, because surely it needs to change and we don't want to keep an old buffer live for no reason if there happens to be one. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
deff5096 -
In a journey to decouple renderer from weston_output, pass the initial framebuffer size to Pixman-renderer explicitly. Now Pixman-renderer will never look into weston_output::current_mode. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
f4559b07 -
This will make sure that backends do not forget to tell us about resizes. composite_*() functions still read the size from the destination buffer, because pixman_output_state is not available there. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
55d08f96 -
This is a slightly better way of keeping pixman-renderer aware of the target size. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
e78e0cf5 -
Now that resize_output() exists and is implemented for Pixman-renderer, use it. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
84b5d0eb -
This changes the GL-renderer interface to pass the initial framebuffer size and compositing area explicitly. All backends are changed to provide the correct parameters. GL-renderer mostly does not yet use these values, but later patches will. The pbuffer path uses it already, because they replaced the existing fields. All this is to make GL-renderer aware of the different sizes, so it can implement the future revision of the screenshooting API. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
7886cbe4 -
This is necessary if you want to resize an output that uses a shadow framebuffer, instead of destroying and re-creating the renderer state. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
a989d12c -
We get rid of unnecessary GL-renderer output state destroy and create, meaning we don't destroy and create an EGLSurface either. Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
8c4f75f0