Add linux-drm-syncobj-v1 protocol
This commit is contained in:
parent
005093b622
commit
9dddead15d
4 changed files with 73 additions and 1 deletions
19
src/wayland/handlers/drm_syncobj.rs
Normal file
19
src/wayland/handlers/drm_syncobj.rs
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
// SPDX-License-Identifier: GPL-3.0-only
|
||||
|
||||
use crate::state::{BackendData, State};
|
||||
use smithay::{
|
||||
delegate_drm_syncobj,
|
||||
wayland::drm_syncobj::{DrmSyncobjHandler, DrmSyncobjState},
|
||||
};
|
||||
|
||||
impl DrmSyncobjHandler for State {
|
||||
fn drm_syncobj_state(&mut self) -> &mut DrmSyncobjState {
|
||||
let kms = match &mut self.backend {
|
||||
BackendData::Kms(kms) => kms,
|
||||
_ => unreachable!(),
|
||||
};
|
||||
kms.syncobj_state.as_mut().unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
delegate_drm_syncobj!(State);
|
||||
Loading…
Add table
Add a link
Reference in a new issue