Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
299e19f
chore: step one
Decodetalkers Jan 15, 2026
0276cdf
chore: better waymirror-egl
Decodetalkers Jan 15, 2026
dd7b2d2
feat: screencast egl api
Decodetalkers Jan 15, 2026
cffc574
chore: follow r-egl-wayland
Decodetalkers Jan 15, 2026
d3c526f
chore: clippy fix
Decodetalkers Jan 15, 2026
b6a2532
chore: use asref for dmabuf
Decodetalkers Jan 16, 2026
5051ab7
fix: panic because egl
Decodetalkers Jan 17, 2026
c127d4c
chore: do not return error during roundtrip
Decodetalkers Jan 17, 2026
68d36bb
fix: fd leak prevent
Decodetalkers Jan 17, 2026
bf4a2f5
chore: api tidy up
Decodetalkers Jan 17, 2026
c74b6d1
fix: color wrong
Decodetalkers Jan 17, 2026
19d7d6f
chore: use keywords in r-egl-wayland
Decodetalkers Jan 17, 2026
4e2cc5b
chore: modify the Cargo.toml of waymirror-egl
Decodetalkers Jan 17, 2026
584db25
chore: use keywords in libs
Decodetalkers Jan 17, 2026
e515999
chore: not modify useless part
Decodetalkers Jan 17, 2026
26ae07a
chore: remove useless dependence
Decodetalkers Jan 17, 2026
fd015a2
chore: remove useless lifetime
Decodetalkers Jan 17, 2026
91f04b5
chore: fix document
Decodetalkers Jan 17, 2026
50ee10f
chore!: remove the use of egl::Instance<T>
Decodetalkers Jan 17, 2026
24e01bc
chore: update deps
Decodetalkers Jan 17, 2026
627c023
chore: update deps
Decodetalkers Jan 17, 2026
a25ac39
chore: api adjust
Decodetalkers Jan 17, 2026
e27fea9
chore!: tidy up api
Decodetalkers Jan 17, 2026
f72239a
chore: reduce repeat code
Decodetalkers Jan 17, 2026
90c3817
chore: do not set waymirror-egl to default member
Decodetalkers Jan 19, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
- name: Build
run: |
rm Cargo.lock
cargo build --release
cargo build --workspace --release
- name: Clippy check
run:
cargo clippy -- -D warnings
Expand Down
70 changes: 59 additions & 11 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
[workspace]
resolver = "2"
members = ["wayshot", "libwayshot"]
members = ["wayshot", "libwayshot", "./waymirror-egl"]
default-members = ["wayshot", "libwayshot"]

[workspace.package]
authors = ["Shinyzenith <https://aakash.is-a.dev>"]
Expand All @@ -15,3 +16,4 @@ edition = "2024"
[workspace.dependencies]
libwayshot = { version = "0.7.0", path = "./libwayshot" }
tracing = "0.1.44"
r-egl-wayland = "0.7.1"
8 changes: 6 additions & 2 deletions libwayshot/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,16 @@ rustix = { version = "1.1", features = ["fs", "shm"] }
thiserror = "2"

wayland-client = "0.31.8"
wayland-protocols = { version = "0.32.6", features = ["client", "staging", "unstable"] }
wayland-protocols = { version = "0.32.6", features = [
"client",
"staging",
"unstable",
] }
wayland-protocols-wlr = { version = "0.3.6", features = ["client"] }
wayland-backend = { version = "0.3.10", features = ["client_system"] }

gbm = "0.18.0"
drm = "0.14.1"

gl = "0.14.0"
khronos-egl = { version = "6.0.0", features = ["static"] }
r-egl-wayland.workspace = true
22 changes: 0 additions & 22 deletions libwayshot/examples/waymirror-egl/src/error.rs

This file was deleted.

67 changes: 0 additions & 67 deletions libwayshot/examples/waymirror-egl/src/main.rs

This file was deleted.

2 changes: 1 addition & 1 deletion libwayshot/examples/waymirror.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ fn main() {
.try_init_dmabuf(WayshotTarget::Screen(output.clone()))
.expect("Cannot find a drm");
let cast = wayshot
.create_screencast_with_dmabuf(None, WayshotTarget::Screen(output), true)
.create_screencast_with_dmabuf(WayshotTarget::Screen(output), true, None)
.unwrap();

let view_porter = globals
Expand Down
7 changes: 4 additions & 3 deletions libwayshot/src/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ use std::{io, result};

use drm::buffer::UnrecognizedFourcc;
use gbm::InvalidFdError;
use r_egl_wayland::r_egl as egl;
use thiserror::Error;
use wayland_client::{
ConnectError, DispatchError, WEnum,
Expand Down Expand Up @@ -46,7 +47,7 @@ pub enum Error {
#[error("dmabuf color format provided by compositor is invalid")]
UnrecognizedColorCode(#[from] UnrecognizedFourcc),
#[error("dmabuf device has been destroyed")]
EGLError(#[from] khronos_egl::Error),
EGLError(#[from] egl::Error),
#[error("No EGLImageTargetTexture2DOES function located, this extension may not be supported")]
EGLImageToTexProcNotFoundError,
#[error("Capture failed: {0}")]
Expand Down Expand Up @@ -264,11 +265,11 @@ mod tests {

#[test]
fn test_from_egl_error() {
let egl_error = khronos_egl::Error::ContextLost;
let egl_error = egl::Error::ContextLost;
let wayshot_error: Error = egl_error.into();

match wayshot_error {
Error::EGLError(khronos_egl::Error::ContextLost) => {}
Error::EGLError(egl::Error::ContextLost) => {}
_ => panic!("Expected Error::EGLError(khronos_egl::Error::ContextLost)"),
}
}
Expand Down
Loading