DRM page-flip with damage for weston

Daniel Stone daniel at fooishbar.org
Fri Jul 20 11:26:22 UTC 2018


Hi Deepak,

On Fri, 20 Jul 2018 at 12:21, Deepak Singh Rawat <drawat at vmware.com> wrote:
> In brief the damage is in frame-buffer coordinate of attached fb to the plane.
> Unlike plane src coordinates, damage clips are not in 16.16 fixed point. Damage
> during page flip is helpful for some drivers like vmwgfx where each framebuffer
> change needs to be transmitted over network, usb, etc.
>
> Now that I have some code ready and got it working for vmwgfx driver, the
> next step is to change weston to send damage during page flip. With my current
> understanding of weston I think the damage received during
> weston_output.repaint() is exactly what I am looking for ? Does this damage
> region during weston_output.repaint() is in frame-buffer coordinate ?

The damage region received during output repaint is in Weston's global
co-ordinate space. To shift to CRTC co-ordinates, you need to
translate the damage region by (-output->x, -output->y). When we are
using the renderer, there is no scaling, so CRTC co-ordinates and
framebuffer co-ordinates are guaranteed to be equal. This only
accounts for the primary plane; damage to views on other planes is
considered separately.

Also, if you are not already working from git master, I recommend you
do so, as the DRM backend has changed hugely since 4.0.0.

Cheers,
Daniel


More information about the wayland-devel mailing list