Hi Matt,
On 24 August 2017 at 15:24, Matt Hoosier <[email protected]> wrote:
> @@ -1545,10 +1548,22 @@ drm_assign_planes(struct weston_output *output_base,
> void *repaint_data)
> next_plane = primary;
> if (next_plane == NULL)
> next_plane = drm_output_prepare_cursor_view(output,
> ev);
> - if (next_plane == NULL)
> +
> + /* If a higher-stacked view already got assigned to scanout,
> it's incorrect to
> + * assign a subsequent (lower-stacked) view to scanout.
> + */
> + if (next_plane == NULL && !picked_scanout) {
> next_plane = drm_output_prepare_scanout_view(output,
> ev);
> - if (next_plane == NULL)
> + if (next_plane)
> + picked_scanout = true;
> + }
> +
> + /* Similarly, it's incorrect to elevate a view to an overlay
> if some higher-stacked
> + * view is already identified as full-screen scanout.
> + */
> + if (next_plane == NULL && !picked_scanout)
> next_plane = drm_output_prepare_overlay_view(output,
> ev);
It can't be correct to raise it to the cursor plane either, since both
cursor and overlay planes strictly stack above the scanout plane. I
guess this would read a lot easier with:
if (picked_scanout)
next_plane = primary;
at the top of the loop.
Cheers,
Daniel
_______________________________________________
wayland-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/wayland-devel