autocommit 2022-04-04 14:29:04 CEST
This commit is contained in:
parent
1f71290dab
commit
e897d271af
21 changed files with 278 additions and 127 deletions
|
|
@ -205,7 +205,7 @@ impl MetalBackend {
|
|||
return;
|
||||
}
|
||||
let master = Rc::new(DrmMaster::new(res.fd.clone()));
|
||||
let dev = match slf.creat_drm_device(dev, &master) {
|
||||
let dev = match slf.create_drm_device(dev, &master) {
|
||||
Ok(d) => d,
|
||||
Err(e) => {
|
||||
log::error!("Could not initialize drm device: {}", ErrorFmt(e));
|
||||
|
|
|
|||
|
|
@ -17,6 +17,7 @@ use crate::utils::clonecell::CloneCell;
|
|||
use crate::utils::errorfmt::ErrorFmt;
|
||||
use crate::utils::numcell::NumCell;
|
||||
use crate::utils::oserror::OsError;
|
||||
use crate::utils::syncqueue::SyncQueue;
|
||||
use ahash::{AHashMap, AHashSet};
|
||||
use bstr::{BString, ByteSlice};
|
||||
use std::cell::Cell;
|
||||
|
|
@ -24,7 +25,6 @@ use std::ffi::CString;
|
|||
use std::fmt::{Debug, Formatter};
|
||||
use std::rc::Rc;
|
||||
use uapi::c;
|
||||
use crate::utils::syncqueue::SyncQueue;
|
||||
|
||||
pub struct PendingDrmDevice {
|
||||
pub id: DrmId,
|
||||
|
|
@ -405,7 +405,7 @@ impl<T: Copy> MutableProperty<T> {
|
|||
}
|
||||
|
||||
impl MetalBackend {
|
||||
pub fn creat_drm_device(
|
||||
pub fn create_drm_device(
|
||||
self: &Rc<Self>,
|
||||
pending: PendingDrmDevice,
|
||||
master: &Rc<DrmMaster>,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,8 @@
|
|||
use crate::async_engine::{Phase, SpawnedFuture};
|
||||
use crate::backend::{Backend, BackendEvent, InputDevice, InputDeviceAccelProfile, InputDeviceCapability, InputDeviceId, InputEvent, KeyState, Connector, OutputId, ScrollAxis, Mode, ConnectorEvent};
|
||||
use crate::backend::{
|
||||
Backend, BackendEvent, Connector, ConnectorEvent, InputDevice, InputDeviceAccelProfile,
|
||||
InputDeviceCapability, InputDeviceId, InputEvent, KeyState, Mode, OutputId, ScrollAxis,
|
||||
};
|
||||
use crate::drm::drm::{Drm, DrmError};
|
||||
use crate::drm::gbm::{GbmDevice, GbmError, GBM_BO_USE_RENDERING};
|
||||
use crate::drm::{ModifiedFormat, INVALID_MODIFIER};
|
||||
|
|
@ -12,6 +15,7 @@ use crate::utils::copyhashmap::CopyHashMap;
|
|||
use crate::utils::errorfmt::ErrorFmt;
|
||||
use crate::utils::numcell::NumCell;
|
||||
use crate::utils::queue::AsyncQueue;
|
||||
use crate::utils::syncqueue::SyncQueue;
|
||||
use crate::wire_xcon::{
|
||||
ChangeProperty, ChangeWindowAttributes, ConfigureNotify, CreateCursor, CreatePixmap,
|
||||
CreateWindow, CreateWindowValues, DestroyNotify, Dri3Open, Dri3PixmapFromBuffer,
|
||||
|
|
@ -39,7 +43,6 @@ use std::cell::{Cell, RefCell};
|
|||
use std::collections::VecDeque;
|
||||
use std::rc::Rc;
|
||||
use thiserror::Error;
|
||||
use crate::utils::syncqueue::SyncQueue;
|
||||
|
||||
#[derive(Debug, Error)]
|
||||
pub enum XBackendError {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue