diff --git a/Cargo.lock b/Cargo.lock
index 3e15fee6..80dce136 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -4,9 +4,9 @@ version = 3
[[package]]
name = "ab_glyph"
-version = "0.2.17"
+version = "0.2.18"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "04a9283dace1c41c265496614998d5b9c4a97b3eb770e804f007c5144bf03f2b"
+checksum = "4dcdbc68024b653943864d436fe8a24b028095bc1cf91a8926f8241e4aaffe59"
dependencies = [
"ab_glyph_rasterizer",
"owned_ttf_parser",
@@ -35,10 +35,11 @@ checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe"
[[package]]
name = "ahash"
-version = "0.7.6"
+version = "0.8.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47"
+checksum = "bf6ccdb167abbf410dcb915cabd428929d7f6a04980b54a11f26a39f1c7f7107"
dependencies = [
+ "cfg-if",
"getrandom",
"once_cell",
"version_check",
@@ -55,9 +56,9 @@ dependencies = [
[[package]]
name = "anyhow"
-version = "1.0.65"
+version = "1.0.66"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "98161a4e3e2184da77bb14f02184cdd111e83bbbcc9979dfee3c44b9a85f5602"
+checksum = "216261ddc8289130e551ddcd5ce8a064710c0d064a4d2895c67151c92b5443f6"
dependencies = [
"backtrace",
]
@@ -84,10 +85,22 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "983cd8b9d4b02a6dc6ffa557262eb5858a27a0038ffffe21a0f133eaa819a164"
[[package]]
-name = "atomic_float"
-version = "0.1.0"
+name = "arrayref"
+version = "0.3.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "62af46d040ba9df09edc6528dae9d8e49f5f3e82f55b7d2ec31a733c38dbc49d"
+checksum = "a4c527152e37cf757a3f78aae5a06fbeefdb07ccc535c980a3208ee3060dd544"
+
+[[package]]
+name = "arrayvec"
+version = "0.5.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "23b62fc65de8e4e7f52534fb52b0f3ed04746ae267519eef2a83941e8085068b"
+
+[[package]]
+name = "arrayvec"
+version = "0.7.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8da52d66c7071e2e3fa2a1e5c6d088fec47b593032b254f5e980de8ea54454d6"
[[package]]
name = "atomic_refcell"
@@ -122,16 +135,16 @@ dependencies = [
"cc",
"cfg-if",
"libc",
- "miniz_oxide",
+ "miniz_oxide 0.5.4",
"object",
"rustc-demangle",
]
[[package]]
name = "base64"
-version = "0.13.0"
+version = "0.13.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "904dfeac50f3cdaba28fc6f57fdcddb75f49ed61346676a78c4ffe55877802fd"
+checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8"
[[package]]
name = "bitflags"
@@ -156,24 +169,24 @@ dependencies = [
[[package]]
name = "bumpalo"
-version = "3.11.0"
+version = "3.11.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c1ad822118d20d2c234f427000d5acc36eabe1e29a348c89b63dd60b13f28e5d"
+checksum = "572f695136211188308f16ad2ca5c851a712c464060ae6974944458eb83880ba"
[[package]]
name = "bytemuck"
-version = "1.12.1"
+version = "1.12.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2f5715e491b5a1598fc2bef5a606847b5dc1d48ea625bd3c02c00de8285591da"
+checksum = "aaa3a8d9a1ca92e282c96a32d6511b695d7d994d1d102ba85d279f9b2756947f"
dependencies = [
"bytemuck_derive",
]
[[package]]
name = "bytemuck_derive"
-version = "1.2.1"
+version = "1.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1b9e1f5fa78f69496407a27ae9ed989e3c3b072310286f5ef385525e4cbc24a9"
+checksum = "5fe233b960f12f8007e3db2d136e3cb1c291bfd7396e384ee76025fc1a3932b4"
dependencies = [
"proc-macro2",
"quote",
@@ -181,13 +194,19 @@ dependencies = [
]
[[package]]
-name = "calloop"
-version = "0.10.1"
+name = "byteorder"
+version = "1.4.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a22a6a8f622f797120d452c630b0ab12e1331a1a753e2039ce7868d4ac77b4ee"
+checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610"
+
+[[package]]
+name = "calloop"
+version = "0.10.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "5bcf530afb40e45e14440701e5e996d7fd139e84a912a4d83a8d6a0fb3e58663"
dependencies = [
"log",
- "nix 0.24.2",
+ "nix 0.25.0",
"slotmap",
"thiserror",
"vec_map",
@@ -195,9 +214,9 @@ dependencies = [
[[package]]
name = "cc"
-version = "1.0.73"
+version = "1.0.76"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "2fff2a6927b3bb87f9595d67196a70493f627687a71d87a0d692242c33f58c11"
+checksum = "76a284da2e6fe2092f2353e51713435363112dfd60030e22add80be333fb928f"
[[package]]
name = "cfg-if"
@@ -217,9 +236,9 @@ dependencies = [
[[package]]
name = "cocoa"
-version = "0.24.0"
+version = "0.24.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "6f63902e9223530efb4e26ccd0cf55ec30d592d3b42e21a28defc42a9586e832"
+checksum = "f425db7937052c684daec3bd6375c8abe2d146dca4b8b143d6db777c39138f3a"
dependencies = [
"bitflags",
"block",
@@ -246,6 +265,12 @@ dependencies = [
"objc",
]
+[[package]]
+name = "color_quant"
+version = "1.1.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b"
+
[[package]]
name = "core-foundation"
version = "0.9.3"
@@ -292,7 +317,6 @@ name = "cosmic-comp"
version = "0.1.0"
dependencies = [
"anyhow",
- "atomic_float",
"bitflags",
"cosmic-protocols",
"edid-rs",
@@ -316,7 +340,7 @@ dependencies = [
"smithay-egui",
"thiserror",
"wayland-backend",
- "wayland-scanner 0.30.0-beta.10",
+ "wayland-scanner 0.30.0-beta.13",
"xcursor",
"xdg",
"xkbcommon 0.4.1",
@@ -325,12 +349,12 @@ dependencies = [
[[package]]
name = "cosmic-protocols"
version = "0.1.0"
-source = "git+https://github.com/pop-os/cosmic-protocols?branch=main#3ff11df30ef551e1ccbdcb091930fe0d72266195"
+source = "git+https://github.com/pop-os/cosmic-protocols?branch=main#a3e0aa740a3e0f8f7b486fef0d62fa09a1dfa328"
dependencies = [
"bitflags",
"wayland-backend",
- "wayland-protocols 0.30.0-beta.10",
- "wayland-scanner 0.30.0-beta.10",
+ "wayland-protocols 0.30.0-beta.13",
+ "wayland-scanner 0.30.0-beta.13",
"wayland-server",
]
@@ -424,10 +448,19 @@ dependencies = [
]
[[package]]
-name = "digest"
-version = "0.10.5"
+name = "data-url"
+version = "0.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "adfbc57365a37acbd2ebf2b64d7e69bb766e2fea813521ed536f5d0520dcf86c"
+checksum = "3a30bfce702bcfa94e906ef82421f2c0e61c076ad76030c16ee5d2e9a32fe193"
+dependencies = [
+ "matches",
+]
+
+[[package]]
+name = "digest"
+version = "0.10.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8168378f4e5023e7218c89c891c0fd8ecdb5e5e4f18cb78f38cf245dd021e76f"
dependencies = [
"block-buffer",
"crypto-common",
@@ -542,9 +575,9 @@ checksum = "2ab5fa33485cd85ac354df485819a63360fefa312fe04cffe65e6f175be1522c"
[[package]]
name = "egui"
-version = "0.18.1"
+version = "0.19.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "eb095a8b9feb9b7ff8f00b6776dffcef059538a3f4a91238e03c900e9c9ad9a2"
+checksum = "fc9fcd393c3daaaf5909008a1d948319d538b79c51871e4df0993260260a94e4"
dependencies = [
"ahash",
"epaint",
@@ -552,20 +585,51 @@ dependencies = [
]
[[package]]
-name = "emath"
-version = "0.18.0"
+name = "egui_extras"
+version = "0.19.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c223f58c7e38abe1770f367b969f1b3fbd4704b67666bcb65dbb1adb0980ba72"
+checksum = "f698f685bb0ad39e87109e2f695ded0bccde77d5d40bbf7590cb5561c1e3039d"
+dependencies = [
+ "egui",
+ "resvg",
+ "tiny-skia",
+ "usvg",
+]
+
+[[package]]
+name = "egui_glow"
+version = "0.19.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ad77d4a00402bae9658ee64be148f4b2a0b38e4fc7874970575ca01ed1c5b75d"
+dependencies = [
+ "bytemuck",
+ "egui",
+ "glow",
+ "memoffset",
+ "tracing",
+ "wasm-bindgen",
+ "web-sys",
+]
+
+[[package]]
+name = "emath"
+version = "0.19.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9542a40106fdba943a055f418d1746a050e1a903a049b030c2b097d4686a33cf"
+dependencies = [
+ "bytemuck",
+]
[[package]]
name = "epaint"
-version = "0.18.1"
+version = "0.19.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "0c29567088888e8ac3e8f61bbb2ddc820207ebb8d69eefde5bcefa06d65e4e89"
+checksum = "5ba04741be7f6602b1a1b28f1082cce45948a7032961c52814f8946b28493300"
dependencies = [
"ab_glyph",
"ahash",
"atomic_refcell",
+ "bytemuck",
"emath",
"nohash-hasher",
"parking_lot",
@@ -608,15 +672,42 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f82b0f4c27ad9f8bfd1f3208d882da2b09c301bc1c828fd3a00d0216d2fbbff6"
dependencies = [
"crc32fast",
- "miniz_oxide",
+ "miniz_oxide 0.5.4",
]
+[[package]]
+name = "float-cmp"
+version = "0.9.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "98de4bbd547a563b716d8dfa9aad1cb19bfab00f4fa09a6a4ed21dbcf44ce9c4"
+
[[package]]
name = "fnv"
version = "1.0.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1"
+[[package]]
+name = "fontconfig-parser"
+version = "0.5.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "2be17a530a842f8a7a60f4397a08e8f08872849a5e31b20c7bd7301dac483296"
+dependencies = [
+ "roxmltree 0.15.1",
+]
+
+[[package]]
+name = "fontdb"
+version = "0.9.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d52186a39c335aa6f79fc0bf1c3cf854870b6ad4e50a7bb8a59b4ba1331f478a"
+dependencies = [
+ "fontconfig-parser",
+ "log",
+ "memmap2",
+ "ttf-parser 0.17.1",
+]
+
[[package]]
name = "foreign-types"
version = "0.3.2"
@@ -676,15 +767,25 @@ dependencies = [
[[package]]
name = "getrandom"
-version = "0.2.7"
+version = "0.2.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4eb1a864a501629691edf6c15a593b7a51eebaa1e8468e9ddc623de7c9b58ec6"
+checksum = "c05aeb6a22b8f62540c194aac980f2115af067bfe15a0734d7277a768d396b31"
dependencies = [
"cfg-if",
"libc",
"wasi",
]
+[[package]]
+name = "gif"
+version = "0.11.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3edd93c6756b4dfaf2709eafcc345ba2636565295c198a9cfbf75fa5e3e00b06"
+dependencies = [
+ "color_quant",
+ "weezl",
+]
+
[[package]]
name = "gimli"
version = "0.26.2"
@@ -702,6 +803,18 @@ dependencies = [
"xml-rs",
]
+[[package]]
+name = "glow"
+version = "0.11.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d8bd5877156a19b8ac83a29b2306fe20537429d318f3ff0a1a2119f8d9c61919"
+dependencies = [
+ "js-sys",
+ "slotmap",
+ "wasm-bindgen",
+ "web-sys",
+]
+
[[package]]
name = "hashbrown"
version = "0.12.3"
@@ -742,10 +855,23 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39"
[[package]]
-name = "indexmap"
-version = "1.9.1"
+name = "image"
+version = "0.24.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "10a35a97730320ffe8e2d410b5d3b69279b98d2c14bdb8b70ea89ecf7888d41e"
+checksum = "69b7ea949b537b0fd0af141fff8c77690f2ce96f4f41f042ccb6c69c6c965945"
+dependencies = [
+ "bytemuck",
+ "byteorder",
+ "color_quant",
+ "num-rational",
+ "num-traits",
+]
+
+[[package]]
+name = "indexmap"
+version = "1.9.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1885e79c1fc4b10f0e172c475f458b7f7b93061064d98c3293e98c5ba0c8b399"
dependencies = [
"autocfg",
"hashbrown",
@@ -791,7 +917,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6f65dae1d3aa98e6877917ab4e6fdbfdfb00e95885ea7c4f4f29e3a5dfc08fdf"
dependencies = [
"libc",
- "windows-sys",
+ "windows-sys 0.36.1",
]
[[package]]
@@ -806,6 +932,12 @@ version = "0.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130"
+[[package]]
+name = "jpeg-decoder"
+version = "0.2.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9478aa10f73e7528198d75109c8be5cd7d15fb530238040148d5f9a22d4c5b3b"
+
[[package]]
name = "js-sys"
version = "0.3.60"
@@ -821,6 +953,15 @@ version = "3.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e2db585e1d738fc771bf08a151420d3ed193d9d895a36df7f6f8a9456b911ddc"
+[[package]]
+name = "kurbo"
+version = "0.8.3"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7a53776d271cfb873b17c618af0298445c88afc52837f3e948fa3fafd131f449"
+dependencies = [
+ "arrayvec 0.7.2",
+]
+
[[package]]
name = "lazy_static"
version = "1.4.0"
@@ -829,15 +970,15 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646"
[[package]]
name = "libc"
-version = "0.2.133"
+version = "0.2.137"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c0f80d65747a3e43d1596c7c5492d95d5edddaabd45a7fcdb02b95f644164966"
+checksum = "fc7fcc620a3bff7cdd7a365be3376c97191aeaccc2a603e600951e452615bf89"
[[package]]
name = "libloading"
-version = "0.7.3"
+version = "0.7.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "efbc0f03f9a775e9f6aed295c6a1ba2253c5757a9e03d55c6caa46a681abcddd"
+checksum = "b67380fd3b2fbe7527a606e18729d21c6f3951633d0500574c4dc22d2d638b9f"
dependencies = [
"cfg-if",
"winapi",
@@ -921,6 +1062,12 @@ dependencies = [
"libc",
]
+[[package]]
+name = "matches"
+version = "0.1.9"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a3e378b66a060d48947b590737b30a1be76706c8dd7b8ba0f2fe3989c68a853f"
+
[[package]]
name = "memchr"
version = "2.5.0"
@@ -929,9 +1076,9 @@ checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d"
[[package]]
name = "memmap2"
-version = "0.5.7"
+version = "0.5.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "95af15f345b17af2efc8ead6080fb8bc376f8cec1b35277b935637595fe77498"
+checksum = "4b182332558b18d807c4ce1ca8ca983b34c3ee32765e47b3f0f69b90355cc1dc"
dependencies = [
"libc",
]
@@ -961,15 +1108,24 @@ dependencies = [
]
[[package]]
-name = "mio"
-version = "0.8.4"
+name = "miniz_oxide"
+version = "0.6.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "57ee1c23c7c63b0c9250c339ffdc69255f110b298b901b9f6c82547b7b87caaf"
+checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa"
+dependencies = [
+ "adler",
+]
+
+[[package]]
+name = "mio"
+version = "0.8.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e5d732bc30207a6423068df043e3d02e0735b155ad7ce1a6f76fe2baa5b158de"
dependencies = [
"libc",
"log",
"wasi",
- "windows-sys",
+ "windows-sys 0.42.0",
]
[[package]]
@@ -1055,6 +1211,19 @@ dependencies = [
"memoffset",
]
+[[package]]
+name = "nix"
+version = "0.25.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e322c04a9e3440c327fca7b6c8a63e6890a32fa2ad689db972425f07e0d22abb"
+dependencies = [
+ "autocfg",
+ "bitflags",
+ "cfg-if",
+ "libc",
+ "memoffset",
+]
+
[[package]]
name = "nohash-hasher"
version = "0.2.0"
@@ -1071,6 +1240,27 @@ dependencies = [
"minimal-lexical",
]
+[[package]]
+name = "num-integer"
+version = "0.1.45"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9"
+dependencies = [
+ "autocfg",
+ "num-traits",
+]
+
+[[package]]
+name = "num-rational"
+version = "0.4.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0"
+dependencies = [
+ "autocfg",
+ "num-integer",
+ "num-traits",
+]
+
[[package]]
name = "num-traits"
version = "0.2.15"
@@ -1130,17 +1320,17 @@ dependencies = [
[[package]]
name = "once_cell"
-version = "1.15.0"
+version = "1.16.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e82dad04139b71a90c080c8463fe0dc7902db5192d939bd0950f074d014339e1"
+checksum = "86f0b0d4bf799edbc74508c1e8bf170ff5f41238e5f8225603ca7caaae2b7860"
[[package]]
name = "owned_ttf_parser"
-version = "0.15.2"
+version = "0.17.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "05e6affeb1632d6ff6a23d2cd40ffed138e82f1532571a26f527c8a284bb2fbb"
+checksum = "18904d3c65493a9f0d7542293d1a7f69bfdc309a6b9ef4f46dc3e58b0577edc5"
dependencies = [
- "ttf-parser",
+ "ttf-parser 0.17.1",
]
[[package]]
@@ -1155,15 +1345,15 @@ dependencies = [
[[package]]
name = "parking_lot_core"
-version = "0.9.3"
+version = "0.9.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "09a279cbf25cb0757810394fbc1e359949b59e348145c643a939a525692e6929"
+checksum = "4dc9e0dc2adc1c69d09143aff38d3d30c5c3f0df0dad82e6d25547af174ebec0"
dependencies = [
"cfg-if",
"libc",
"redox_syscall",
"smallvec",
- "windows-sys",
+ "windows-sys 0.42.0",
]
[[package]]
@@ -1173,28 +1363,40 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e"
[[package]]
-name = "pkg-config"
-version = "0.3.25"
+name = "pico-args"
+version = "0.5.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1df8c4ec4b0627e53bdf214615ad287367e482558cf84b109250b37464dc03ae"
+checksum = "5be167a7af36ee22fe3115051bc51f6e6c7054c9348e28deb4f49bd6f705a315"
+
+[[package]]
+name = "pin-project-lite"
+version = "0.2.9"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116"
+
+[[package]]
+name = "pkg-config"
+version = "0.3.26"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160"
[[package]]
name = "png"
-version = "0.17.6"
+version = "0.17.7"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "8f0e7f4c94ec26ff209cee506314212639d6c91b80afb82984819fafce9df01c"
+checksum = "5d708eaf860a19b19ce538740d2b4bdeeb8337fa53f7738455e706623ad5c638"
dependencies = [
"bitflags",
"crc32fast",
"flate2",
- "miniz_oxide",
+ "miniz_oxide 0.6.2",
]
[[package]]
name = "ppv-lite86"
-version = "0.2.16"
+version = "0.2.17"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "eb9f9e6e233e5c4a35559a617bf40a4ec447db2e84c20b55a6f83167b7e57872"
+checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de"
[[package]]
name = "proc-macro-crate"
@@ -1282,6 +1484,12 @@ dependencies = [
"cty",
]
+[[package]]
+name = "rctree"
+version = "0.4.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9ae028b272a6e99d9f8260ceefa3caa09300a8d6c8d2b2001316474bc52122e9"
+
[[package]]
name = "redox_syscall"
version = "0.2.16"
@@ -1304,9 +1512,9 @@ dependencies = [
[[package]]
name = "regex"
-version = "1.6.0"
+version = "1.7.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "4c4eb3267174b8c6c2f654116623910a0fef09c4753f8dd83db29c48a0df988b"
+checksum = "e076559ef8e241f2ae3479e36f97bd5741c0330689e217ad51ce2c76808b868a"
dependencies = [
"aho-corasick",
"memchr",
@@ -1315,9 +1523,9 @@ dependencies = [
[[package]]
name = "regex-syntax"
-version = "0.6.27"
+version = "0.6.28"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a3f87b73ce11b1619a3c6332f45341e0047173771e8b8b73f87bfeefb7b56244"
+checksum = "456c603be3e8d448b072f410900c09faf164fbce2d480456f50eea6e25f9c848"
[[package]]
name = "remove_dir_all"
@@ -1328,6 +1536,33 @@ dependencies = [
"winapi",
]
+[[package]]
+name = "resvg"
+version = "0.23.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "34489194784b86c03c3d688258e2ba73f3c82700ba4673ee2ecad5ae540b9438"
+dependencies = [
+ "gif",
+ "jpeg-decoder",
+ "log",
+ "pico-args",
+ "png",
+ "rgb",
+ "svgfilters",
+ "svgtypes",
+ "tiny-skia",
+ "usvg",
+]
+
+[[package]]
+name = "rgb"
+version = "0.8.34"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "3603b7d71ca82644f79b5a06d1220e9a58ede60bd32255f698cb1af8838b8db3"
+dependencies = [
+ "bytemuck",
+]
+
[[package]]
name = "ron"
version = "0.7.1"
@@ -1339,6 +1574,24 @@ dependencies = [
"serde",
]
+[[package]]
+name = "roxmltree"
+version = "0.14.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "921904a62e410e37e215c40381b7117f830d9d89ba60ab5236170541dd25646b"
+dependencies = [
+ "xmlparser",
+]
+
+[[package]]
+name = "roxmltree"
+version = "0.15.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "6b9de9831a129b122e7e61f242db509fa9d0838008bf0b29bb0624669edfe48a"
+dependencies = [
+ "xmlparser",
+]
+
[[package]]
name = "rustc-demangle"
version = "0.1.21"
@@ -1351,12 +1604,37 @@ version = "1.0.9"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "97477e48b4cf8603ad5f7aaf897467cf42ab4218a38ef76fb14c2d6773a6d6a8"
+[[package]]
+name = "rustybuzz"
+version = "0.5.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a617c811f5c9a7060fe511d35d13bf5b9f0463ce36d63ce666d05779df2b4eba"
+dependencies = [
+ "bitflags",
+ "bytemuck",
+ "smallvec",
+ "ttf-parser 0.15.2",
+ "unicode-bidi-mirroring",
+ "unicode-ccc",
+ "unicode-general-category",
+ "unicode-script",
+]
+
[[package]]
name = "ryu"
version = "1.0.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4501abdff3ae82a1c1b477a17252eb69cee9e66eb915c1abaa4f44d873df9f09"
+[[package]]
+name = "safe_arch"
+version = "0.5.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "c1ff3d6d9696af502cc3110dacce942840fb06ff4514cad92236ecc455f2ce05"
+dependencies = [
+ "bytemuck",
+]
+
[[package]]
name = "scan_fmt"
version = "0.2.6"
@@ -1365,9 +1643,9 @@ checksum = "0b53b0a5db882a8e2fdaae0a43f7b39e7e9082389e978398bdf223a55b581248"
[[package]]
name = "scoped-tls"
-version = "1.0.0"
+version = "1.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ea6a9290e3c9cf0f18145ef7ffa62d68ee0bf5fcd651017e586dc7fd5da448c2"
+checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294"
[[package]]
name = "scopeguard"
@@ -1386,18 +1664,18 @@ dependencies = [
[[package]]
name = "serde"
-version = "1.0.145"
+version = "1.0.147"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "728eb6351430bccb993660dfffc5a72f91ccc1295abaa8ce19b27ebe4f75568b"
+checksum = "d193d69bae983fc11a79df82342761dfbf28a99fc8d203dca4c3c1b590948965"
dependencies = [
"serde_derive",
]
[[package]]
name = "serde_derive"
-version = "1.0.145"
+version = "1.0.147"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "81fa1584d3d1bcacd84c277a0dfe21f5b0f6accf4a23d04d4c6d61f1af522b4c"
+checksum = "4f1d362ca8fc9c3e3a7484440752472d68a6caa98f1ab81d99b5dfe517cec852"
dependencies = [
"proc-macro2",
"quote",
@@ -1406,9 +1684,9 @@ dependencies = [
[[package]]
name = "serde_json"
-version = "1.0.85"
+version = "1.0.88"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e55a28e3aaef9d5ce0506d0a14dbba8054ddc7e499ef522dd8b26859ec9d4a44"
+checksum = "8e8b3801309262e8184d9687fb697586833e939767aea0dda89f5a8e650e8bd7"
dependencies = [
"itoa",
"ryu",
@@ -1426,6 +1704,21 @@ dependencies = [
"digest",
]
+[[package]]
+name = "simplecss"
+version = "0.2.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a11be7c62927d9427e9f40f3444d5499d868648e2edbc4e2116de69e7ec0e89d"
+dependencies = [
+ "log",
+]
+
+[[package]]
+name = "siphasher"
+version = "0.3.10"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7bd3e3206899af3f8b12af284fafc038cc1dc2b41d1b89dd17297221c5d225de"
+
[[package]]
name = "slog"
version = "2.7.0"
@@ -1497,11 +1790,12 @@ checksum = "2fd0db749597d91ff862fd1d55ea87f7855a744a8425a64695b6fca237d1dad1"
[[package]]
name = "smithay"
version = "0.3.0"
-source = "git+https://github.com/Smithay//smithay?rev=625cbca5#625cbca54981021000d5a33c1bdc711056ff6000"
+source = "git+https://github.com/pop-os/smithay?rev=c8aaa059e8#c8aaa059e841886ed9e689e0cc0d0cb821b97b71"
dependencies = [
"appendlist",
"bitflags",
"calloop",
+ "cc",
"cgmath",
"downcast-rs",
"drm",
@@ -1509,6 +1803,7 @@ dependencies = [
"drm-fourcc",
"gbm",
"gl_generator",
+ "glow",
"indexmap",
"input",
"io-lifetimes",
@@ -1518,6 +1813,7 @@ dependencies = [
"libseat",
"nix 0.24.2",
"once_cell",
+ "pkg-config",
"rand",
"scan_fmt",
"slog",
@@ -1527,11 +1823,11 @@ dependencies = [
"udev",
"wayland-backend",
"wayland-egl",
- "wayland-protocols 0.30.0-beta.10",
+ "wayland-protocols 0.30.0-beta.13",
"wayland-protocols-misc",
"wayland-protocols-wlr",
"wayland-server",
- "wayland-sys 0.30.0-beta.10",
+ "wayland-sys 0.30.0-beta.13",
"winit",
"x11rb",
"xkbcommon 0.5.0",
@@ -1559,13 +1855,14 @@ dependencies = [
[[package]]
name = "smithay-egui"
version = "0.1.0"
-source = "git+https://github.com/Smithay/smithay-egui.git?rev=939febaf#939febafd4df990b412213abff992ab4a4b9bd44"
+source = "git+https://github.com/Smithay/smithay-egui.git?rev=9fe1fa5e01#9fe1fa5e01dc39c145f036564e971a50f84864ff"
dependencies = [
"cgmath",
"egui",
- "lazy_static",
+ "egui_extras",
+ "egui_glow",
+ "image",
"memoffset",
- "slog",
"smithay",
"xkbcommon 0.4.1",
]
@@ -1589,10 +1886,29 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601"
[[package]]
-name = "syn"
-version = "1.0.101"
+name = "svgfilters"
+version = "0.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e90cde112c4b9690b8cbe810cba9ddd8bc1d7472e2cae317b69e9438c1cba7d2"
+checksum = "639abcebc15fdc2df179f37d6f5463d660c1c79cd552c12343a4600827a04bce"
+dependencies = [
+ "float-cmp",
+ "rgb",
+]
+
+[[package]]
+name = "svgtypes"
+version = "0.8.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "22975e8a2bac6a76bb54f898a6b18764633b00e780330f0b689f65afb3975564"
+dependencies = [
+ "siphasher",
+]
+
+[[package]]
+name = "syn"
+version = "1.0.103"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "a864042229133ada95abf3b54fdc62ef5ccabe9515b64717bcb9a1919e59445d"
dependencies = [
"proc-macro2",
"quote",
@@ -1661,21 +1977,46 @@ dependencies = [
[[package]]
name = "time"
-version = "0.3.14"
+version = "0.3.17"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "3c3f9a28b618c3a6b9251b6908e9c99e04b9e5c02e6581ccbb67d59c34ef7f9b"
+checksum = "a561bf4617eebd33bca6434b988f39ed798e527f51a1e797d0ee4f61c0a38376"
dependencies = [
"itoa",
"libc",
"num_threads",
+ "serde",
+ "time-core",
"time-macros",
]
[[package]]
-name = "time-macros"
-version = "0.2.4"
+name = "time-core"
+version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "42657b1a6f4d817cda8e7a0ace261fe0cc946cf3a80314390b22cc61ae080792"
+checksum = "2e153e1f1acaef8acc537e68b44906d2db6436e2b35ac2c6b42640fff91f00fd"
+
+[[package]]
+name = "time-macros"
+version = "0.2.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d967f99f534ca7e495c575c62638eebc2898a8c84c119b89e250477bc4ba16b2"
+dependencies = [
+ "time-core",
+]
+
+[[package]]
+name = "tiny-skia"
+version = "0.6.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d049bfef0eaa2521e75d9ffb5ce86ad54480932ae19b85f78bec6f52c4d30d78"
+dependencies = [
+ "arrayref",
+ "arrayvec 0.5.2",
+ "bytemuck",
+ "cfg-if",
+ "png",
+ "safe_arch",
+]
[[package]]
name = "toml"
@@ -1686,12 +2027,38 @@ dependencies = [
"serde",
]
+[[package]]
+name = "tracing"
+version = "0.1.37"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8"
+dependencies = [
+ "cfg-if",
+ "pin-project-lite",
+ "tracing-core",
+]
+
+[[package]]
+name = "tracing-core"
+version = "0.1.30"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "24eb03ba0eab1fd845050058ce5e616558e8f8d8fca633e6b163fe25c797213a"
+dependencies = [
+ "once_cell",
+]
+
[[package]]
name = "ttf-parser"
version = "0.15.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7b3e06c9b9d80ed6b745c7159c40b311ad2916abb34a49e9be2653b90db0d8dd"
+[[package]]
+name = "ttf-parser"
+version = "0.17.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "375812fa44dab6df41c195cd2f7fecb488f6c09fbaafb62807488cefab642bff"
+
[[package]]
name = "typenum"
version = "1.15.0"
@@ -1709,12 +2076,75 @@ dependencies = [
"pkg-config",
]
+[[package]]
+name = "unicode-bidi"
+version = "0.3.8"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "099b7128301d285f79ddd55b9a83d5e6b9e97c92e0ea0daebee7263e932de992"
+
+[[package]]
+name = "unicode-bidi-mirroring"
+version = "0.1.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "56d12260fb92d52f9008be7e4bca09f584780eb2266dc8fecc6a192bec561694"
+
+[[package]]
+name = "unicode-ccc"
+version = "0.1.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cc2520efa644f8268dce4dcd3050eaa7fc044fca03961e9998ac7e2e92b77cf1"
+
+[[package]]
+name = "unicode-general-category"
+version = "0.4.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "07547e3ee45e28326cc23faac56d44f58f16ab23e413db526debce3b0bfd2742"
+
[[package]]
name = "unicode-ident"
version = "1.0.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "dcc811dc4066ac62f84f11307873c4850cb653bfa9b1719cee2bd2204a4bc5dd"
+[[package]]
+name = "unicode-script"
+version = "0.5.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "7d817255e1bed6dfd4ca47258685d14d2bdcfbc64fdc9e3819bd5848057b8ecc"
+
+[[package]]
+name = "unicode-vo"
+version = "0.1.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b1d386ff53b415b7fe27b50bb44679e2cc4660272694b7b6f3326d8480823a94"
+
+[[package]]
+name = "usvg"
+version = "0.23.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "28a82565b5c96dcbb58c9bdbb6aa3642abd395a6a6b480658532c6f74c3c4b7a"
+dependencies = [
+ "base64",
+ "data-url",
+ "flate2",
+ "float-cmp",
+ "fontdb",
+ "kurbo",
+ "log",
+ "pico-args",
+ "rctree",
+ "roxmltree 0.14.1",
+ "rustybuzz",
+ "simplecss",
+ "siphasher",
+ "svgtypes",
+ "ttf-parser 0.15.2",
+ "unicode-bidi",
+ "unicode-script",
+ "unicode-vo",
+ "xmlwriter",
+]
+
[[package]]
name = "uuid"
version = "0.8.2"
@@ -1798,17 +2228,17 @@ checksum = "1c38c045535d93ec4f0b4defec448e4291638ee608530863b1e2ba115d4fff7f"
[[package]]
name = "wayland-backend"
-version = "0.1.0-beta.10"
+version = "0.1.0-beta.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "30c089c872513a8dcc2b5cc26209d83f5ffab1841d8c7973edf2583620ebc018"
+checksum = "f3f96c52ca34b33e6bb55497327428be54dad648973aa5d3d1e02982d2fcc298"
dependencies = [
"cc",
"downcast-rs",
"io-lifetimes",
- "nix 0.24.2",
+ "nix 0.25.0",
"scoped-tls",
"smallvec",
- "wayland-sys 0.30.0-beta.10",
+ "wayland-sys 0.30.0-beta.13",
]
[[package]]
@@ -1852,13 +2282,13 @@ dependencies = [
[[package]]
name = "wayland-egl"
-version = "0.30.0-beta.10"
+version = "0.30.0-beta.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "b6cb5591d75142e1b180691df4d27f164a09abbd6efc7cba9b119ca40646809c"
+checksum = "da29b4a38d5cd89b90786305b62c21889d7d97bb1e2ccf46a94906832898e20e"
dependencies = [
"thiserror",
"wayland-backend",
- "wayland-sys 0.30.0-beta.10",
+ "wayland-sys 0.30.0-beta.13",
]
[[package]]
@@ -1875,39 +2305,39 @@ dependencies = [
[[package]]
name = "wayland-protocols"
-version = "0.30.0-beta.10"
+version = "0.30.0-beta.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "60406a2fb43ff670ece4976cdd0537bbcd1e583b54c3cd9a1b61065e966df0a7"
+checksum = "e32104ba51988754f4429dbb59c7b7fd2ccf1feaa0009bb59e49a5e2f91e985d"
dependencies = [
"bitflags",
"wayland-backend",
- "wayland-scanner 0.30.0-beta.10",
+ "wayland-scanner 0.30.0-beta.13",
"wayland-server",
]
[[package]]
name = "wayland-protocols-misc"
-version = "0.1.0-beta.10"
+version = "0.1.0-beta.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "653c3e200343bcfae719b668959efb9475bf9fcf43591cccfead308d32d67049"
+checksum = "d6d0be545a3b35869060efa6e19622f6b071a9ee8d09da5ffa48f072524fddaa"
dependencies = [
"bitflags",
"wayland-backend",
- "wayland-protocols 0.30.0-beta.10",
- "wayland-scanner 0.30.0-beta.10",
+ "wayland-protocols 0.30.0-beta.13",
+ "wayland-scanner 0.30.0-beta.13",
"wayland-server",
]
[[package]]
name = "wayland-protocols-wlr"
-version = "0.1.0-beta.10"
+version = "0.1.0-beta.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f1cfe42e0cfcce47a421844ee82e49316cfab3ec6bcbb3a1076a0a2dd6c8d61e"
+checksum = "130613a48629204e4ab50ea4b5de2efa2e17c58f71a5af15b39535f99421f8c3"
dependencies = [
"bitflags",
"wayland-backend",
- "wayland-protocols 0.30.0-beta.10",
- "wayland-scanner 0.30.0-beta.10",
+ "wayland-protocols 0.30.0-beta.13",
+ "wayland-scanner 0.30.0-beta.13",
"wayland-server",
]
@@ -1924,9 +2354,9 @@ dependencies = [
[[package]]
name = "wayland-scanner"
-version = "0.30.0-beta.10"
+version = "0.30.0-beta.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a1398566f240c3ef845bdfd310c8ee6ba800d4db695d007f23f2190eeedfff93"
+checksum = "1fb55ca28710dcc155078db4e2bd29aacf24bd311261c48750f38c6c5430bf1f"
dependencies = [
"proc-macro2",
"quick-xml",
@@ -1936,16 +2366,16 @@ dependencies = [
[[package]]
name = "wayland-server"
-version = "0.30.0-beta.10"
+version = "0.30.0-beta.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "030557c71dfa3d7e0d0b5975bbdfee2eee319fde3e4c420cde63474c61331347"
+checksum = "ba5ed6de3d02e0bcfee03cf23b8f8e923fb3707d826bcb1ef10ef34647778e20"
dependencies = [
"bitflags",
"downcast-rs",
- "nix 0.24.2",
+ "nix 0.25.0",
"thiserror",
"wayland-backend",
- "wayland-scanner 0.30.0-beta.10",
+ "wayland-scanner 0.30.0-beta.13",
]
[[package]]
@@ -1961,9 +2391,9 @@ dependencies = [
[[package]]
name = "wayland-sys"
-version = "0.30.0-beta.10"
+version = "0.30.0-beta.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "bacc6b678c3350910e5ad6c057b7503666080952c4ece0a7e8958fd33937b1f5"
+checksum = "882bda56e8397384ad66ec0ebe763e0b3b53153a6327344f7d74b85981a271e1"
dependencies = [
"dlib",
"libc",
@@ -1982,6 +2412,12 @@ dependencies = [
"wasm-bindgen",
]
+[[package]]
+name = "weezl"
+version = "0.1.7"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9193164d4de03a926d909d3bc7c30543cecb35400c02114792c2cae20d5e2dbb"
+
[[package]]
name = "winapi"
version = "0.3.9"
@@ -2019,37 +2455,88 @@ version = "0.36.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ea04155a16a59f9eab786fe12a4a450e75cdb175f9e0d80da1e17db09f55b8d2"
dependencies = [
- "windows_aarch64_msvc",
- "windows_i686_gnu",
- "windows_i686_msvc",
- "windows_x86_64_gnu",
- "windows_x86_64_msvc",
+ "windows_aarch64_msvc 0.36.1",
+ "windows_i686_gnu 0.36.1",
+ "windows_i686_msvc 0.36.1",
+ "windows_x86_64_gnu 0.36.1",
+ "windows_x86_64_msvc 0.36.1",
]
+[[package]]
+name = "windows-sys"
+version = "0.42.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7"
+dependencies = [
+ "windows_aarch64_gnullvm",
+ "windows_aarch64_msvc 0.42.0",
+ "windows_i686_gnu 0.42.0",
+ "windows_i686_msvc 0.42.0",
+ "windows_x86_64_gnu 0.42.0",
+ "windows_x86_64_gnullvm",
+ "windows_x86_64_msvc 0.42.0",
+]
+
+[[package]]
+name = "windows_aarch64_gnullvm"
+version = "0.42.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "41d2aa71f6f0cbe00ae5167d90ef3cfe66527d6f613ca78ac8024c3ccab9a19e"
+
[[package]]
name = "windows_aarch64_msvc"
version = "0.36.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9bb8c3fd39ade2d67e9874ac4f3db21f0d710bee00fe7cab16949ec184eeaa47"
+[[package]]
+name = "windows_aarch64_msvc"
+version = "0.42.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "dd0f252f5a35cac83d6311b2e795981f5ee6e67eb1f9a7f64eb4500fbc4dcdb4"
+
[[package]]
name = "windows_i686_gnu"
version = "0.36.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "180e6ccf01daf4c426b846dfc66db1fc518f074baa793aa7d9b9aaeffad6a3b6"
+[[package]]
+name = "windows_i686_gnu"
+version = "0.42.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "fbeae19f6716841636c28d695375df17562ca208b2b7d0dc47635a50ae6c5de7"
+
[[package]]
name = "windows_i686_msvc"
version = "0.36.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e2e7917148b2812d1eeafaeb22a97e4813dfa60a3f8f78ebe204bcc88f12f024"
+[[package]]
+name = "windows_i686_msvc"
+version = "0.42.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "84c12f65daa39dd2babe6e442988fc329d6243fdce47d7d2d155b8d874862246"
+
[[package]]
name = "windows_x86_64_gnu"
version = "0.36.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4dcd171b8776c41b97521e5da127a2d86ad280114807d0b2ab1e462bc764d9e1"
+[[package]]
+name = "windows_x86_64_gnu"
+version = "0.42.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "bf7b1b21b5362cbc318f686150e5bcea75ecedc74dd157d874d754a2ca44b0ed"
+
+[[package]]
+name = "windows_x86_64_gnullvm"
+version = "0.42.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "09d525d2ba30eeb3297665bd434a54297e4170c7f1a44cad4ef58095b4cd2028"
+
[[package]]
name = "windows_x86_64_msvc"
version = "0.36.1"
@@ -2057,10 +2544,16 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c811ca4a8c853ef420abd8592ba53ddbbac90410fab6903b3e79972a631f7680"
[[package]]
-name = "winit"
-version = "0.27.3"
+name = "windows_x86_64_msvc"
+version = "0.42.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "a22e94ba35ca3ff11820044bfa0dc48b95a3a15569c0068555566a12ef41c9e5"
+checksum = "f40009d85759725a34da6d89a94e63d7bdc50a862acf0dbc7c8e488f1edcb6f5"
+
+[[package]]
+name = "winit"
+version = "0.27.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "bb796d6fbd86b2fd896c9471e6f04d39d750076ebe5680a3958f00f5ab97657c"
dependencies = [
"bitflags",
"cocoa",
@@ -2084,7 +2577,7 @@ dependencies = [
"wayland-client",
"wayland-protocols 0.29.5",
"web-sys",
- "windows-sys",
+ "windows-sys 0.36.1",
"x11-dl",
]
@@ -2163,3 +2656,15 @@ name = "xml-rs"
version = "0.8.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d2d7d3948613f75c98fd9328cfdcc45acc4d360655289d0a7d4ec931392200a3"
+
+[[package]]
+name = "xmlparser"
+version = "0.13.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "4d25c75bf9ea12c4040a97f829154768bbbce366287e2dc044af160cd79a13fd"
+
+[[package]]
+name = "xmlwriter"
+version = "0.1.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ec7a2a501ed189703dba8b08142f057e887dfc4b2cc4db2d343ac6376ba3e0b9"
diff --git a/Cargo.toml b/Cargo.toml
index d351a463..f4f6b11e 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -16,7 +16,7 @@ slog-stdlog = "4.1"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
sendfd = "0.4.1"
-egui = { version = "0.18.1", optional = true }
+egui = { version = "0.19.0", optional = true }
edid-rs = { version = "0.1" }
png = "0.17.5"
lazy_static = "1.4.0"
@@ -28,28 +28,27 @@ xkbcommon = "0.4"
indexmap = "1.8.0"
xdg = "^2.1"
ron = "0.7"
-atomic_float = "0.1"
libsystemd = "0.5"
-wayland-backend = "=0.1.0-beta.10"
-wayland-scanner = "=0.30.0-beta.10"
+wayland-backend = "=0.1.0-beta.13"
+wayland-scanner = "=0.30.0-beta.13"
cosmic-protocols = { git = "https://github.com/pop-os/cosmic-protocols", branch = "main", default-features = false, features = ["server"] }
[dependencies.smithay]
version = "0.3"
git = "https://github.com/Smithay/smithay.git"
-rev = "606d2d5c"
+rev = "b297c93edc"
default-features = false
-features = ["backend_drm", "backend_gbm", "backend_egl", "backend_libinput", "backend_session_libseat", "backend_udev", "backend_winit", "backend_x11", "desktop", "use_system_lib", "renderer_gl", "renderer_multi", "wayland_frontend", "slog-stdlog"]
+features = ["backend_drm", "backend_gbm", "backend_egl", "backend_libinput", "backend_session_libseat", "backend_udev", "backend_winit", "backend_x11", "desktop", "use_system_lib", "renderer_glow", "renderer_multi", "wayland_frontend", "slog-stdlog"]
[dependencies.smithay-egui]
git = "https://github.com/Smithay/smithay-egui.git"
-rev = "939febaf"
+rev = "9fe1fa5e01"
+features = ["svg"]
optional = true
[features]
default = []
debug = ["egui", "smithay-egui"]
-experimental = []
[profile.dev]
lto = "thin"
@@ -62,4 +61,4 @@ debug = true
lto = "fat"
[patch."https://github.com/Smithay/smithay.git"]
-smithay = { git = "https://github.com/Smithay//smithay", rev = "625cbca5" }
+smithay = { git = "https://github.com/pop-os/smithay", rev = "c8aaa059e8" }
diff --git a/config.ron b/config.ron
index 5a28839b..c1795c9c 100644
--- a/config.ron
+++ b/config.ron
@@ -1,51 +1,89 @@
(
key_bindings: {
- (modifiers: [Logo, Shift], key: "Escape"): Terminate,
- (modifiers: [Logo], key: "Escape"): Debug,
- (modifiers: [Logo], key: "q"): Close,
- (modifiers: [Logo], key: "1"): Workspace(1),
- (modifiers: [Logo], key: "2"): Workspace(2),
- (modifiers: [Logo], key: "3"): Workspace(3),
- (modifiers: [Logo], key: "4"): Workspace(4),
- (modifiers: [Logo], key: "5"): Workspace(5),
- (modifiers: [Logo], key: "6"): Workspace(6),
- (modifiers: [Logo], key: "7"): Workspace(7),
- (modifiers: [Logo], key: "8"): Workspace(8),
- (modifiers: [Logo], key: "9"): Workspace(9),
- (modifiers: [Logo], key: "0"): Workspace(0),
- (modifiers: [Logo, Shift], key: "1"): MoveToWorkspace(1),
- (modifiers: [Logo, Shift], key: "2"): MoveToWorkspace(2),
- (modifiers: [Logo, Shift], key: "3"): MoveToWorkspace(3),
- (modifiers: [Logo, Shift], key: "4"): MoveToWorkspace(4),
- (modifiers: [Logo, Shift], key: "5"): MoveToWorkspace(5),
- (modifiers: [Logo, Shift], key: "6"): MoveToWorkspace(6),
- (modifiers: [Logo, Shift], key: "7"): MoveToWorkspace(7),
- (modifiers: [Logo, Shift], key: "8"): MoveToWorkspace(8),
- (modifiers: [Logo, Shift], key: "9"): MoveToWorkspace(9),
- (modifiers: [Logo, Shift], key: "0"): MoveToWorkspace(0),
- (modifiers: [Logo], key: "Left"): Focus(Left),
- (modifiers: [Logo], key: "Right"): Focus(Right),
- (modifiers: [Logo], key: "Up"): Focus(Up),
- (modifiers: [Logo], key: "Down"): Focus(Down),
- (modifiers: [Logo], key: "h"): Focus(Left),
- (modifiers: [Logo], key: "j"): Focus(Down),
- (modifiers: [Logo], key: "k"): Focus(Up),
- (modifiers: [Logo], key: "l"): Focus(Right),
-//TODO: automatic orientation with Logo+o toggling
- (modifiers: [Logo], key: "v"): Orientation(Vertical),
- (modifiers: [Logo], key: "o"): Orientation(Horizontal),
- (modifiers: [Logo], key: "y"): ToggleTiling,
- (modifiers: [Logo], key: "g"): ToggleWindowFloating,
- (modifiers: [Logo, Shift], key: "f"): Fullscreen,
- (modifiers: [Logo, Shift], key: "s"): Screenshot,
+ (modifiers: [Super, Shift], key: "Escape"): Terminate,
+ (modifiers: [Super], key: "Escape"): Debug,
+ (modifiers: [Super], key: "q"): Close,
+
+ (modifiers: [Super], key: "1"): Workspace(1),
+ (modifiers: [Super], key: "2"): Workspace(2),
+ (modifiers: [Super], key: "3"): Workspace(3),
+ (modifiers: [Super], key: "4"): Workspace(4),
+ (modifiers: [Super], key: "5"): Workspace(5),
+ (modifiers: [Super], key: "6"): Workspace(6),
+ (modifiers: [Super], key: "7"): Workspace(7),
+ (modifiers: [Super], key: "8"): Workspace(8),
+ (modifiers: [Super], key: "9"): Workspace(9),
+ (modifiers: [Super], key: "0"): LastWorkspace,
+ (modifiers: [Super, Shift], key: "1"): MoveToWorkspace(1),
+ (modifiers: [Super, Shift], key: "2"): MoveToWorkspace(2),
+ (modifiers: [Super, Shift], key: "3"): MoveToWorkspace(3),
+ (modifiers: [Super, Shift], key: "4"): MoveToWorkspace(4),
+ (modifiers: [Super, Shift], key: "5"): MoveToWorkspace(5),
+ (modifiers: [Super, Shift], key: "6"): MoveToWorkspace(6),
+ (modifiers: [Super, Shift], key: "7"): MoveToWorkspace(7),
+ (modifiers: [Super, Shift], key: "8"): MoveToWorkspace(8),
+ (modifiers: [Super, Shift], key: "9"): MoveToWorkspace(9),
+ (modifiers: [Super, Shift], key: "0"): MoveToLastWorkspace,
+
+ // TODO: Depends on workspace orientation
+ (modifiers: [Super, Ctrl], key: "Right"): NextWorkspace,
+ (modifiers: [Super, Ctrl], key: "Left"): PreviousWorkspace,
+ (modifiers: [Super, Ctrl, Shift], key: "Right"): MoveToNextWorkspace,
+ (modifiers: [Super, Ctrl, Shift], key: "Left"): MoveToPreviousWorkspace,
+ (modifiers: [Super, Ctrl], key: "l"): NextWorkspace,
+ (modifiers: [Super, Ctrl], key: "h"): PreviousWorkspace,
+ (modifiers: [Super, Ctrl, Shift], key: "l"): MoveToNextWorkspace,
+ (modifiers: [Super, Ctrl, Shift], key: "h"): MoveToPreviousWorkspace,
+
+ (modifiers: [Super, Ctrl], key: "Down"): NextOutput,
+ (modifiers: [Super, Ctrl], key: "Up"): PreviousOutput,
+ (modifiers: [Super, Ctrl, Alt], key: "Down"): NextOutput,
+ (modifiers: [Super, Ctrl, Alt], key: "Up"): PreviousOutput,
+ (modifiers: [Super, Ctrl], key: "j"): NextOutput,
+ (modifiers: [Super, Ctrl], key: "k"): PreviousOutput,
+ (modifiers: [Super, Ctrl, Alt], key: "j"): NextOutput,
+ (modifiers: [Super, Ctrl, Alt], key: "k"): PreviousOutput,
+
+ (modifiers: [Super], key: "Period"): NextOutput,
+ (modifiers: [Super], key: "Comma"): PreviousOutput,
+ (modifiers: [Super, Shift], key: "Period"): MoveToNextOutput,
+ (modifiers: [Super, Shift], key: "Comma"): MoveToPreviousOutput,
+
+ (modifiers: [Super], key: "Left"): Focus(Left),
+ (modifiers: [Super], key: "Right"): Focus(Right),
+ (modifiers: [Super], key: "Up"): Focus(Up),
+ (modifiers: [Super], key: "Down"): Focus(Down),
+ (modifiers: [Super], key: "h"): Focus(Left),
+ (modifiers: [Super], key: "j"): Focus(Down),
+ (modifiers: [Super], key: "k"): Focus(Up),
+ (modifiers: [Super], key: "l"): Focus(Right),
+
+ (modifiers: [Super, Shift], key: "Left"): Move(Left),
+ (modifiers: [Super, Shift], key: "Right"): Move(Right),
+ (modifiers: [Super, Shift], key: "Up"): Move(Up),
+ (modifiers: [Super, Shift], key: "Down"): Move(Down),
+ (modifiers: [Super, Shift], key: "h"): Move(Left),
+ (modifiers: [Super, Shift], key: "j"): Move(Down),
+ (modifiers: [Super, Shift], key: "k"): Move(Up),
+ (modifiers: [Super, Shift], key: "l"): Move(Right),
+
+ (modifiers: [Super], key: "o"): ToggleOrientation,
+
+ (modifiers: [Super], key: "y"): ToggleTiling,
+ (modifiers: [Super], key: "g"): ToggleWindowFloating,
+
+ (modifiers: [Super], key: "m"): Maximize,
+
//TODO: ability to select default web browser
- (modifiers: [Logo], key: "b"): Spawn("firefox"),
+ (modifiers: [Super], key: "b"): Spawn("firefox"),
//TODO: ability to select default file browser
- (modifiers: [Logo], key: "f"): Spawn("nautilus"),
+ (modifiers: [Super], key: "f"): Spawn("nautilus"),
//TODO: ability to select default terminal
- (modifiers: [Logo], key: "t"): Spawn("gnome-terminal"),
- (modifiers: [Logo], key: "a"): Spawn("busctl --user call com.system76.CosmicAppletHost /com/system76/CosmicAppletHost com.system76.CosmicAppletHost Toggle s 'com.system76.CosmicAppLibrary'"),
- (modifiers: [Logo], key: "slash"): Spawn("busctl --user call com.system76.CosmicAppletHost /com/system76/CosmicAppletHost com.system76.CosmicAppletHost Toggle s 'com.system76.CosmicLauncher'"),
+ (modifiers: [Super], key: "t"): Spawn("gnome-terminal"),
+
+ (modifiers: [Super], key: "a"): Spawn("busctl --user call com.system76.CosmicAppletHost /com/system76/CosmicAppletHost com.system76.CosmicAppletHost Toggle s 'com.system76.CosmicAppLibrary'"),
+ (modifiers: [Super], key: "slash"): Spawn("busctl --user call com.system76.CosmicAppletHost /com/system76/CosmicAppletHost com.system76.CosmicAppletHost Toggle s 'com.system76.CosmicLauncher'"),
+
(modifiers: [], key: "XF86AudioRaiseVolume"): Spawn("amixer sset Master 5%+"),
(modifiers: [], key: "XF86AudioLowerVolume"): Spawn("amixer sset Master 5%-"),
(modifiers: [], key: "XF86AudioMute"): Spawn("amixer sset Master toggle"),
@@ -53,5 +91,6 @@
(modifiers: [], key: "XF86MonBrightnessDown"): Spawn("busctl --user call com.system76.CosmicSettingsDaemon /com/system76/CosmicSettingsDaemon com.system76.CosmicSettingsDaemon DecreaseDisplayBrightness"),
},
workspace_mode: OutputBound,
+ workspace_amount: Dynamic,
floating_default: false,
)
diff --git a/resources/icons/amd.svg b/resources/icons/amd.svg
new file mode 100644
index 00000000..59275eda
--- /dev/null
+++ b/resources/icons/amd.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/resources/icons/intel.svg b/resources/icons/intel.svg
new file mode 100644
index 00000000..b7253316
--- /dev/null
+++ b/resources/icons/intel.svg
@@ -0,0 +1,12 @@
+
+
+
\ No newline at end of file
diff --git a/resources/icons/nvidia.svg b/resources/icons/nvidia.svg
new file mode 100644
index 00000000..2b25de27
--- /dev/null
+++ b/resources/icons/nvidia.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/rust-toolchain.toml b/rust-toolchain.toml
index e403b651..70772a38 100644
--- a/rust-toolchain.toml
+++ b/rust-toolchain.toml
@@ -1,2 +1,2 @@
[toolchain]
-channel = "1.63"
\ No newline at end of file
+channel = "1.65"
\ No newline at end of file
diff --git a/src/backend/kms/mod.rs b/src/backend/kms/mod.rs
index fd860432..6652b632 100644
--- a/src/backend/kms/mod.rs
+++ b/src/backend/kms/mod.rs
@@ -1,14 +1,15 @@
// SPDX-License-Identifier: GPL-3.0-only
-#[cfg(feature = "debug")]
-use crate::state::Fps;
-
use crate::{
backend::render,
config::OutputConfig,
shell::Shell,
- state::{BackendData, ClientState, Common, Data},
+ state::{BackendData, ClientState, Common, Data, Fps},
utils::prelude::*,
+ wayland::{
+ handlers::screencopy::{PendingScreencopyBuffers, UserdataExt},
+ protocols::screencopy::{BufferParams, Session as ScreencopySession},
+ },
};
use anyhow::{Context, Result};
@@ -20,13 +21,16 @@ use smithay::{
input::InputEvent,
libinput::{LibinputInputBackend, LibinputSessionInterface},
renderer::{
+ damage::DamageTrackedRenderer,
gles2::Gles2Renderbuffer,
+ glow::GlowRenderer,
multigpu::{egl::EglGlesBackend, GpuManager},
- Bind,
},
session::{auto::AutoSession, Session, Signal},
udev::{all_gpus, primary_gpu, UdevBackend, UdevEvent},
},
+ desktop::utils::OutputPresentationFeedback,
+ input::Seat,
output::{Mode as OutputMode, Output, PhysicalProperties, Subpixel},
reexports::{
calloop::{
@@ -36,6 +40,7 @@ use smithay::{
drm::control::{connector, crtc, Device as ControlDevice, ModeTypeFlags},
input::Libinput,
nix::{fcntl::OFlag, sys::stat::dev_t},
+ wayland_protocols::wp::presentation_time::server::wp_presentation_feedback,
wayland_server::{protocol::wl_surface::WlSurface, DisplayHandle, Resource},
},
utils::{
@@ -51,7 +56,7 @@ use std::{
os::unix::io::{FromRawFd, OwnedFd},
path::PathBuf,
rc::Rc,
- time::{Duration, Instant},
+ time::Duration,
};
mod drm_helpers;
@@ -60,9 +65,13 @@ mod socket;
use session_fd::*;
use socket::*;
+use super::render::{CursorMode, GlMultiRenderer};
+// for now we assume we need at least 3ms
+const MIN_RENDER_TIME: Duration = Duration::from_millis(3);
+
pub struct KmsState {
devices: HashMap,
- pub api: GpuManager,
+ pub api: GpuManager>,
pub primary: DrmNode,
session: AutoSession,
signaler: Signaler,
@@ -82,16 +91,21 @@ pub struct Device {
}
pub struct Surface {
- surface: Option>>, SessionFd>>,
+ surface: Option<
+ GbmBufferedSurface<
+ Rc>>,
+ SessionFd,
+ Option,
+ >,
+ >,
+ damage_tracker: DamageTrackedRenderer,
connector: connector::Handle,
output: Output,
- last_render: Option<(Dmabuf, Instant)>,
- last_submit: Option,
refresh_rate: u32,
vrr: bool,
pending: bool,
+ dirty: bool,
render_timer_token: Option,
- #[cfg(feature = "debug")]
fps: Fps,
}
@@ -120,12 +134,12 @@ pub fn init_backend(
}
data.state.process_input_event(event);
for output in data.state.common.shell.outputs() {
- if let Err(err) = data
- .state
- .backend
- .kms()
- .schedule_render(&data.state.common.event_loop_handle, output)
- {
+ if let Err(err) = data.state.backend.kms().schedule_render(
+ &data.state.common.event_loop_handle,
+ output,
+ None,
+ None,
+ ) {
slog_scope::crit!(
"Error scheduling event loop for output {}: {:?}",
output.name(),
@@ -142,7 +156,8 @@ pub fn init_backend(
.map_err(|err| err.error)
.context("Failed to initialize session event source")?;
- let api = GpuManager::new(EglGlesBackend, None).context("Failed to initialize renderers")?;
+ let api = GpuManager::new(EglGlesBackend::::default(), None)
+ .context("Failed to initialize renderers")?;
// TODO get this info from system76-power, if available and setup a watcher
let primary = if let Some(path) = std::env::var("COSMIC_RENDER_DEVICE")
@@ -238,20 +253,15 @@ pub fn init_backend(
}
}
}
- data.state.common.output_configuration_state.update();
+ let seats = data.state.common.seats().cloned().collect::>();
data.state.common.config.read_outputs(
- data.state.common.output_configuration_state.outputs(),
+ &mut data.state.common.output_configuration_state,
&mut data.state.backend,
&mut data.state.common.shell,
+ seats.into_iter(),
&data.state.common.event_loop_handle,
);
- data.state.common.shell.refresh_outputs();
- data.state
- .common
- .config
- .write_outputs(data.state.common.output_configuration_state.outputs());
-
for surface in data
.state
.backend
@@ -263,12 +273,17 @@ pub fn init_backend(
surface.pending = false;
}
for output in data.state.common.shell.outputs() {
- if let Err(err) = data
- .state
- .backend
- .kms()
- .schedule_render(&data.state.common.event_loop_handle, output)
- {
+ let sessions = output.pending_buffers().collect::>();
+ if let Err(err) = data.state.backend.kms().schedule_render(
+ &data.state.common.event_loop_handle,
+ output,
+ None,
+ if !sessions.is_empty() {
+ Some(sessions)
+ } else {
+ None
+ },
+ ) {
slog_scope::crit!(
"Error scheduling event loop for output {}: {:?}",
output.name(),
@@ -364,27 +379,87 @@ impl State {
let dispatcher =
Dispatcher::new(drm, move |event, metadata, data: &mut Data| match event {
DrmEvent::VBlank(crtc) => {
- if let Some(device) = data.state.backend.kms().devices.get_mut(&drm_node) {
- if let Some(surface) = device.surfaces.get_mut(&crtc) {
- match surface.surface.as_mut().map(|x| x.frame_submitted()) {
- Some(Ok(_)) => {
- surface.last_submit = metadata.take().map(|data| data.time);
- surface.pending = false;
- data.state
- .common
- .shell
- .active_space_mut(&surface.output)
- .space
- .send_frames(
- data.state.common.start_time.elapsed().as_millis()
- as u32,
- );
+ let rescheduled =
+ if let Some(device) = data.state.backend.kms().devices.get_mut(&drm_node) {
+ if let Some(surface) = device.surfaces.get_mut(&crtc) {
+ #[cfg(feature = "debug")]
+ surface.fps.displayed();
+
+ match surface.surface.as_mut().map(|x| x.frame_submitted()) {
+ Some(Ok(feedback)) => {
+ if let Some(mut feedback) = feedback.flatten() {
+ let submit_time =
+ match metadata.take().map(|data| data.time) {
+ Some(DrmEventTime::Monotonic(tp)) => Some(tp),
+ _ => None,
+ };
+ let seq = metadata
+ .as_ref()
+ .map(|metadata| metadata.sequence)
+ .unwrap_or(0);
+
+ let (clock, flags) = if let Some(tp) = submit_time {
+ (
+ tp.into(),
+ wp_presentation_feedback::Kind::Vsync
+ | wp_presentation_feedback::Kind::HwClock
+ | wp_presentation_feedback::Kind::HwCompletion,
+ )
+ } else {
+ (
+ data.state.common.clock.now(),
+ wp_presentation_feedback::Kind::Vsync,
+ )
+ };
+
+ feedback.presented(
+ clock,
+ surface
+ .output
+ .current_mode()
+ .map(|mode| mode.refresh as u32)
+ .unwrap_or_default(),
+ seq as u64,
+ flags,
+ );
+ }
+
+ surface.pending = false;
+ surface.dirty.then(|| {
+ (surface.output.clone(), surface.fps.avg_rendertime(5))
+ })
+ }
+ Some(Err(err)) => {
+ slog_scope::warn!("Failed to submit frame: {}", err);
+ None
+ }
+ _ => None, // got disabled
}
- Some(Err(err)) => {
- slog_scope::warn!("Failed to submit frame: {}", err)
- }
- None => {} // got disabled
- };
+ } else {
+ None
+ }
+ } else {
+ None
+ };
+
+ if let Some((output, avg_rendertime)) = rescheduled {
+ let mut scheduled_sessions =
+ data.state.workspace_session_for_output(&output);
+ if let Some(sessions) = output.user_data().get::()
+ {
+ scheduled_sessions
+ .get_or_insert_with(Vec::new)
+ .extend(sessions.borrow_mut().drain(..));
+ }
+
+ let repaint_delay = std::cmp::max(avg_rendertime, MIN_RENDER_TIME);
+ if let Err(err) = data.state.backend.kms().schedule_render(
+ &data.state.common.event_loop_handle,
+ &output,
+ Some(repaint_delay),
+ scheduled_sessions,
+ ) {
+ slog_scope::warn!("Failed to schedule render: {}", err);
}
}
}
@@ -424,47 +499,44 @@ impl State {
let outputs = device.enumerate_surfaces()?.added; // There are no removed outputs on newly added devices
let mut wl_outputs = Vec::new();
let mut w = self.common.shell.global_space().size.w;
- for (crtc, conn) in outputs {
- match device.setup_surface(crtc, conn, (w, 0)) {
- Ok(output) => {
- w += output
- .user_data()
- .get::>()
- .unwrap()
- .borrow()
- .mode_size()
- .w;
- wl_outputs.push(output);
- }
- Err(err) => slog_scope::warn!("Failed to initialize output: {}", err),
- };
+ {
+ let backend = self.backend.kms();
+ for (crtc, conn) in outputs {
+ let mut renderer = match backend.api.renderer(&render_node, &render_node) {
+ Ok(renderer) => renderer,
+ Err(err) => {
+ slog_scope::warn!("Failed to initialize output: {}", err);
+ continue;
+ }
+ };
+ match device.setup_surface(crtc, conn, (w, 0), &mut renderer) {
+ Ok(output) => {
+ w += output
+ .user_data()
+ .get::>()
+ .unwrap()
+ .borrow()
+ .mode_size()
+ .w;
+ wl_outputs.push(output);
+ }
+ Err(err) => slog_scope::warn!("Failed to initialize output: {}", err),
+ };
+ }
+ backend.devices.insert(drm_node, device);
}
- self.backend.kms().devices.insert(drm_node, device);
self.common
.output_configuration_state
.add_heads(wl_outputs.iter());
- self.common.output_configuration_state.update();
- for output in wl_outputs {
- if let Err(err) = self.backend.kms().apply_config_for_output(
- &output,
- &mut self.common.shell,
- false,
- &self.common.event_loop_handle,
- ) {
- slog_scope::warn!("Failed to initialize output: {}", err);
- }
- }
+ let seats = self.common.seats().cloned().collect::>();
self.common.config.read_outputs(
- self.common.output_configuration_state.outputs(),
+ &mut self.common.output_configuration_state,
&mut self.backend,
&mut self.common.shell,
+ seats.into_iter(),
&self.common.event_loop_handle,
);
- self.common.shell.refresh_outputs();
- self.common
- .config
- .write_outputs(self.common.output_configuration_state.outputs());
Ok(())
}
@@ -477,32 +549,45 @@ impl State {
let drm_node = DrmNode::from_dev_id(dev)?;
let mut outputs_removed = Vec::new();
let mut outputs_added = Vec::new();
- if let Some(device) = self.backend.kms().devices.get_mut(&drm_node) {
- let changes = device.enumerate_surfaces()?;
- let mut w = self.common.shell.global_space().size.w;
- for crtc in changes.removed {
- if let Some(surface) = device.surfaces.remove(&crtc) {
- if let Some(token) = surface.render_timer_token {
- self.common.event_loop_handle.remove(token);
+ {
+ let backend = self.backend.kms();
+ if let Some(device) = backend.devices.get_mut(&drm_node) {
+ let changes = device.enumerate_surfaces()?;
+ let mut w = self.common.shell.global_space().size.w;
+ for crtc in changes.removed {
+ if let Some(surface) = device.surfaces.remove(&crtc) {
+ if let Some(token) = surface.render_timer_token {
+ self.common.event_loop_handle.remove(token);
+ }
+ w -= surface.output.current_mode().map(|m| m.size.w).unwrap_or(0);
+ outputs_removed.push(surface.output.clone());
}
- w -= surface.output.current_mode().map(|m| m.size.w).unwrap_or(0);
- outputs_removed.push(surface.output.clone());
}
- }
- for (crtc, conn) in changes.added {
- match device.setup_surface(crtc, conn, (w, 0)) {
- Ok(output) => {
- w += output
- .user_data()
- .get::>()
- .unwrap()
- .borrow()
- .mode_size()
- .w;
- outputs_added.push(output);
- }
- Err(err) => slog_scope::warn!("Failed to initialize output: {}", err),
- };
+ for (crtc, conn) in changes.added {
+ let mut renderer = match backend
+ .api
+ .renderer(&device.render_node, &device.render_node)
+ {
+ Ok(renderer) => renderer,
+ Err(err) => {
+ slog_scope::warn!("Failed to initialize output: {}", err);
+ continue;
+ }
+ };
+ match device.setup_surface(crtc, conn, (w, 0), &mut renderer) {
+ Ok(output) => {
+ w += output
+ .user_data()
+ .get::>()
+ .unwrap()
+ .borrow()
+ .mode_size()
+ .w;
+ outputs_added.push(output);
+ }
+ Err(err) => slog_scope::warn!("Failed to initialize output: {}", err),
+ };
+ }
}
}
@@ -512,30 +597,19 @@ impl State {
self.common
.output_configuration_state
.add_heads(outputs_added.iter());
- for output in outputs_added {
- if let Err(err) = self.backend.kms().apply_config_for_output(
- &output,
- &mut self.common.shell,
- false,
- &self.common.event_loop_handle,
- ) {
- slog_scope::warn!("Failed to initialize output: {}", err);
- }
- }
+ let seats = self.common.seats().cloned().collect::>();
for output in outputs_removed {
- self.common.shell.remove_output(&output);
+ self.common
+ .shell
+ .remove_output(&output, seats.iter().cloned());
}
- self.common.output_configuration_state.update();
self.common.config.read_outputs(
- self.common.output_configuration_state.outputs(),
+ &mut self.common.output_configuration_state,
&mut self.backend,
&mut self.common.shell,
+ seats.into_iter(),
&self.common.event_loop_handle,
);
- self.common.shell.refresh_outputs();
- self.common
- .config
- .write_outputs(self.common.output_configuration_state.outputs());
Ok(())
}
@@ -564,22 +638,23 @@ impl State {
self.common
.output_configuration_state
.remove_heads(outputs_removed.iter());
- self.common.output_configuration_state.update();
+ let seats = self.common.seats().cloned().collect::>();
if self.backend.kms().session.is_active() {
for output in outputs_removed {
- self.common.shell.remove_output(&output);
+ self.common
+ .shell
+ .remove_output(&output, seats.iter().cloned());
}
self.common.config.read_outputs(
- self.common.output_configuration_state.outputs(),
+ &mut self.common.output_configuration_state,
&mut self.backend,
&mut self.common.shell,
+ seats.into_iter(),
&self.common.event_loop_handle,
);
- self.common.shell.refresh_outputs();
- self.common
- .config
- .write_outputs(self.common.output_configuration_state.outputs());
+ } else {
+ self.common.output_configuration_state.update();
}
Ok(())
@@ -624,6 +699,7 @@ impl Device {
crtc: crtc::Handle,
conn: connector::Handle,
position: (i32, i32),
+ renderer: &mut GlMultiRenderer<'_>,
) -> Result