syncobj: use rendernode for timelines (#11087)
* syncobj: use rendernode for timelines use rendernode for timelines instead of the drmfd, some devices dont support to use the drmfd for this. * opengl: use rendernode if available use rendernode if available for CHyprOpenglImpl * MesaDRM: use the m_drmRenderNodeFD if it exist try use the rendernode we got from AQ if it exist. * linuxdmabuf: use rendernode if available use the rendernode if available already from AQ * syncobj: prefer rendernode over displaynode prefer the rendernode over the displaynode, and log a error if attempting to use the protocol without explicit sync support on any of the nodes. * syncobj: check support on both nodes always check support on both nodes always so it can be used later for preferring rendernode if possible in syncobj protocol. * syncobj: remove old var in non linux if else case remove old m_bDrmSyncobjTimelineSupported from non linux if else case that will fail to compile on non linux. the nodes sets support by default to false, and if non linux it wont check for support and set it to true. * build: bump aq requirement bump to 0.9.3 where rendernode support got added. * flake.lock: update * renderer: glfinish on software renderer software renderers apparently bug out on implicit sync, use glfinish as with nvidia case on implicit paths. * flake.lock: update --------- Co-authored-by: Mihai Fufezan <mihai@fufexan.net>
This commit is contained in:
parent
ced38b1b0f
commit
b329ea8e96
12 changed files with 107 additions and 59 deletions
|
|
@ -199,8 +199,18 @@ bool CDRMSyncobjManagerResource::good() {
|
|||
return m_resource->resource();
|
||||
}
|
||||
|
||||
CDRMSyncobjProtocol::CDRMSyncobjProtocol(const wl_interface* iface, const int& ver, const std::string& name) :
|
||||
IWaylandProtocol(iface, ver, name), m_drmFD(g_pCompositor->m_drmFD) {}
|
||||
CDRMSyncobjProtocol::CDRMSyncobjProtocol(const wl_interface* iface, const int& ver, const std::string& name) : IWaylandProtocol(iface, ver, name) {
|
||||
if (g_pCompositor->m_drmRenderNode.syncObjSupport)
|
||||
m_drmFD = g_pCompositor->m_drmRenderNode.fd;
|
||||
else if (g_pCompositor->m_drm.syncobjSupport)
|
||||
m_drmFD = g_pCompositor->m_drm.fd;
|
||||
else {
|
||||
LOGM(ERR, "CDRMSyncobjProtocol: no nodes support explicit sync?");
|
||||
return;
|
||||
}
|
||||
|
||||
LOGM(LOG, "CDRMSyncobjProtocol: using fd {}", m_drmFD);
|
||||
}
|
||||
|
||||
void CDRMSyncobjProtocol::bindManager(wl_client* client, void* data, uint32_t ver, uint32_t id) {
|
||||
const auto& RESOURCE = m_managers.emplace_back(makeUnique<CDRMSyncobjManagerResource>(makeUnique<CWpLinuxDrmSyncobjManagerV1>(client, ver, id)));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue