Skip to content
  • Simon Ser's avatar
    unstable/linux-dmabuf: add wp_linux_dmabuf_feedback · 8a5cd28a
    Simon Ser authored
    
    
    On multi-GPU setups, multiple devices can be used for rendering. Clients
    need feedback about the device in use by the compositor. For instance,
    if they render on another GPU, then they need to make sure the memory is
    accessible between devices and that their buffers are not placed in
    hidden memory.
    
    This commit introduces a new wp_linux_dmabuf_feedback object. This
    object advertises a preferred main device, a set of preferred
    formats/modifiers and target devices.
    
    Each object is bound to a wl_surface and can dynamically update its
    feedback parameters. This enables fine-grained per-surface
    optimizations. For instance, when a surface is scanned out on a GPU the
    compositor isn't compositing with, the target device can be set to this
    GPU to avoid unnecessary roundtrips.
    
    A feedback object can also be standalone for clients that don't support
    per-surface feedback.
    
    Signed-off-by: Simon Ser's avatarSimon Ser <contact@emersion.fr>
    Signed-off-by: default avatarLeandro Ribeiro <leandro.ribeiro@collabora.com>
    Reviewed-by: default avatarDaniel Stone <daniels@collabora.com>
    Closes: wayland#59
    8a5cd28a