mirror of
https://github.com/moonlight-stream/moonlight-qt.git
synced 2025-07-02 15:55:39 +00:00
Allow reuse of an active plane for devices with only one usable plane per CRTC
This commit is contained in:
parent
517b684f85
commit
5711e6064e
@ -422,7 +422,10 @@ bool DrmRenderer::initialize(PDECODER_PARAMETERS params)
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((plane->possible_crtcs & (1 << crtcIndex)) && plane->crtc_id == 0) {
|
// We don't check plane->crtc_id here because we want to be able to reuse the primary plane
|
||||||
|
// that may owned by Qt and in use on a CRTC prior to us taking over DRM master. When we give
|
||||||
|
// control back to Qt, it will repopulate the plane with the FB it owns and render as normal.
|
||||||
|
if ((plane->possible_crtcs & (1 << crtcIndex))) {
|
||||||
drmModeObjectPropertiesPtr props = drmModeObjectGetProperties(m_DrmFd, planeRes->planes[i], DRM_MODE_OBJECT_PLANE);
|
drmModeObjectPropertiesPtr props = drmModeObjectGetProperties(m_DrmFd, planeRes->planes[i], DRM_MODE_OBJECT_PLANE);
|
||||||
if (props != nullptr) {
|
if (props != nullptr) {
|
||||||
for (uint32_t j = 0; j < props->count_props; j++) {
|
for (uint32_t j = 0; j < props->count_props; j++) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user