forked from enlightenment/efl
ecore_drm2: Add scanout status callbacks
This generates callbacks when a fb becomes scanned out on a hardware plane or when it no longer is.
This commit is contained in:
parent
5f2d4e75ab
commit
1552f85ede
|
@ -299,6 +299,10 @@ ecore_drm2_fb_flip_complete(Ecore_Drm2_Output *output)
|
|||
fb->scanout_count++;
|
||||
|
||||
plane->scanout = EINA_TRUE;
|
||||
if (fb->status_handler && (fb->scanout_count == 1))
|
||||
fb->status_handler(fb,
|
||||
ECORE_DRM2_FB_STATUS_SCANOUT_ON,
|
||||
fb->status_data);
|
||||
continue;
|
||||
}
|
||||
plane_scanout = plane->scanout;
|
||||
|
@ -307,6 +311,10 @@ ecore_drm2_fb_flip_complete(Ecore_Drm2_Output *output)
|
|||
if (!plane_scanout) continue;
|
||||
|
||||
fb->scanout_count--;
|
||||
if (fb->status_handler && (fb->scanout_count == 0))
|
||||
fb->status_handler(fb,
|
||||
ECORE_DRM2_FB_STATUS_SCANOUT_OFF,
|
||||
fb->status_data);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue