Skip to content

Reduce compositor-to-backend lookup

There are a few places where backends look up the backend pointer from the compositor via to_xyz_backend() helpers when creating heads or outputs. With the compositor->backend pointer this is trivial now, but with multi-backend support this pointer would go away and it would be required to iterate over all backends to find the correct one.

Reduce to_xyz_backend() usage or pass a weston_backend pointer and simplify the helpers into container_of() wrappers, for the windowed output API.

This might be an alternative to the suggestion in !578 (comment 1866445).

/cc @mol

Merge request reports

Loading