From 8da40049defe753051be82eddc1424cc4b4285d7 Mon Sep 17 00:00:00 2001 From: Sergey Sushilin Date: Wed, 6 May 2026 02:17:58 +0300 Subject: [PATCH 01/14] Update FFMPEG version and save pause state for each monitor. --- Cargo.lock | 20 +++++---- crates/video/Cargo.toml | 2 +- crates/video/src/hardware.rs | 6 +++ crates/video/src/lib.rs | 53 ++++++++++-------------- crates/waywe-daemon/src/wallpaper_app.rs | 2 + crates/waywe-ipc/src/profile.rs | 1 + 6 files changed, 45 insertions(+), 39 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 34aea705..553a5ef1 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -423,9 +423,9 @@ dependencies = [ [[package]] name = "bindgen" -version = "0.70.1" +version = "0.72.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f49d8fed880d473ea71efb9bf597651e77201bdd4893efe54c9e5d65ae04ce6f" +checksum = "993776b509cfb49c750f11b8f07a46fa23e0a1386ffc01fb1e7d343efc387895" dependencies = [ "bitflags 2.9.4", "cexpr", @@ -434,7 +434,7 @@ dependencies = [ "proc-macro2", "quote", "regex", - "rustc-hash", + "rustc-hash 2.1.2", "shlex", "syn", ] @@ -1092,9 +1092,9 @@ dependencies = [ [[package]] name = "ffmpeg-sys-next" -version = "7.1.3" +version = "8.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9e9c75ebd4463de9d8998fb134ba26347fe5faee62fabf0a4b4d41bd500b4ad" +checksum = "a314bc0e022a33a99567ed4bd2576bd58ffd8fcff7891c29194cfecc26a62547" dependencies = [ "bindgen", "cc", @@ -1903,7 +1903,7 @@ dependencies = [ "once_cell", "petgraph", "pp-rs", - "rustc-hash", + "rustc-hash 1.1.0", "spirv", "thiserror 2.0.17", "unicode-ident", @@ -2610,6 +2610,12 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" +[[package]] +name = "rustc-hash" +version = "2.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94300abf3f1ae2e2b8ffb7b58043de3d399c73fa6f4b73826402a5c457614dbe" + [[package]] name = "rustix" version = "0.38.44" @@ -3641,7 +3647,7 @@ dependencies = [ "portable-atomic", "profiling", "raw-window-handle", - "rustc-hash", + "rustc-hash 1.1.0", "smallvec", "thiserror 2.0.17", "wgpu-core-deps-apple", diff --git a/crates/video/Cargo.toml b/crates/video/Cargo.toml index 1a73b466..79056c66 100644 --- a/crates/video/Cargo.toml +++ b/crates/video/Cargo.toml @@ -8,7 +8,7 @@ authors.workspace = true repository.workspace = true [dependencies] -ffmpeg-sys-next = { version = "7.1.3", features = ["build-vaapi"] } +ffmpeg-sys-next = { version = "8.1.0", features = ["build-vaapi"] } glam.workspace = true bitflags.workspace = true thiserror.workspace = true diff --git a/crates/video/src/hardware.rs b/crates/video/src/hardware.rs index 68aecef9..eea7fec1 100644 --- a/crates/video/src/hardware.rs +++ b/crates/video/src/hardware.rs @@ -25,6 +25,8 @@ pub enum HardwareDeviceType { MediaCodec = 10, Vulkan = 11, D3D12Va = 12, + Amf = 13, + Ohcodec = 14, } impl HardwareDeviceType { @@ -43,6 +45,8 @@ impl HardwareDeviceType { Self::MediaCodec => AVHWDeviceType::AV_HWDEVICE_TYPE_MEDIACODEC, Self::Vulkan => AVHWDeviceType::AV_HWDEVICE_TYPE_VULKAN, Self::D3D12Va => AVHWDeviceType::AV_HWDEVICE_TYPE_D3D12VA, + Self::Amf => AVHWDeviceType::AV_HWDEVICE_TYPE_AMF, + Self::Ohcodec => AVHWDeviceType::AV_HWDEVICE_TYPE_OHCODEC, } } @@ -66,6 +70,8 @@ impl HardwareDeviceType { AVHWDeviceType::AV_HWDEVICE_TYPE_MEDIACODEC => Self::MediaCodec, AVHWDeviceType::AV_HWDEVICE_TYPE_VULKAN => Self::Vulkan, AVHWDeviceType::AV_HWDEVICE_TYPE_D3D12VA => Self::D3D12Va, + AVHWDeviceType::AV_HWDEVICE_TYPE_AMF => Self::Amf, + AVHWDeviceType::AV_HWDEVICE_TYPE_OHCODEC => Self::Ohcodec, }) } diff --git a/crates/video/src/lib.rs b/crates/video/src/lib.rs index 3e51be6c..f3c9fd44 100644 --- a/crates/video/src/lib.rs +++ b/crates/video/src/lib.rs @@ -8,16 +8,7 @@ pub mod time; use bitflags::bitflags; use ffi::va; use ffmpeg_sys_next::{ - AV_PROFILE_UNKNOWN, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, - AVPixFmtDescriptor, AVProfile, AVStream, SEEK_SET, SWS_ACCURATE_RND, SWS_AREA, SWS_BICUBIC, - SWS_BICUBLIN, SWS_BILINEAR, SWS_BITEXACT, SWS_DIRECT_BGR, SWS_ERROR_DIFFUSION, - SWS_FAST_BILINEAR, SWS_FULL_CHR_H_INP, SWS_FULL_CHR_H_INT, SWS_GAUSS, SWS_LANCZOS, - SWS_PARAM_DEFAULT, SWS_POINT, SWS_PRINT_INFO, SWS_SINC, SWS_SPLINE, SWS_SRC_V_CHR_DROP_MASK, - SWS_SRC_V_CHR_DROP_SHIFT, SWS_X, SwsContext, av_buffer_get_ref_count, av_codec_iterate, - av_find_best_stream, av_frame_alloc, av_frame_free, av_frame_get_buffer, av_frame_unref, - av_new_packet, av_packet_alloc, av_packet_free, av_packet_ref, av_packet_unref, av_read_frame, - avdevice_register_all, avformat_close_input, avformat_find_stream_info, avformat_open_input, - avformat_seek_file, avio_seek, sws_getContext, sws_scale, + AV_PROFILE_UNKNOWN, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, AVPixFmtDescriptor, AVProfile, AVStream, SEEK_SET, SwsContext, SwsFlags::{SWS_ACCURATE_RND, SWS_AREA, SWS_BICUBIC, SWS_BICUBLIN, SWS_BILINEAR, SWS_BITEXACT, SWS_DIRECT_BGR, SWS_ERROR_DIFFUSION, SWS_FAST_BILINEAR, SWS_FULL_CHR_H_INP, SWS_FULL_CHR_H_INT, SWS_GAUSS, SWS_LANCZOS, SWS_POINT, SWS_PRINT_INFO, SWS_SINC, SWS_SPLINE, SWS_X}, av_buffer_get_ref_count, av_codec_iterate, av_find_best_stream, av_frame_alloc, av_frame_free, av_frame_get_buffer, av_frame_unref, av_new_packet, av_packet_alloc, av_packet_free, av_packet_ref, av_packet_unref, av_read_frame, avdevice_register_all, avformat_close_input, avformat_find_stream_info, avformat_open_input, avformat_seek_file, avio_seek, sws_getContext, sws_scale }; use glam::UVec2; use std::{ @@ -1078,27 +1069,27 @@ pub struct ScalerFormat { bitflags! { #[derive(Copy, Clone, Debug, PartialEq, Eq)] pub struct ScalerFlags: i32 { - const FAST_BILINEAR = SWS_FAST_BILINEAR; - const BILINEAR = SWS_BILINEAR; - const BICUBIC = SWS_BICUBIC; - const X = SWS_X; - const POINT = SWS_POINT; - const AREA = SWS_AREA; - const BICUBLIN = SWS_BICUBLIN; - const GAUSS = SWS_GAUSS; - const SINC = SWS_SINC; - const LANCZOS = SWS_LANCZOS; - const SPLINE = SWS_SPLINE; - const SRC_V_CHR_DROP_MASK = SWS_SRC_V_CHR_DROP_MASK; - const SRC_V_CHR_DROP_SHIFT = SWS_SRC_V_CHR_DROP_SHIFT; - const PARAM_DEFAULT = SWS_PARAM_DEFAULT; - const PRINT_INFO = SWS_PRINT_INFO; - const FULL_CHR_H_INT = SWS_FULL_CHR_H_INT; - const FULL_CHR_H_INP = SWS_FULL_CHR_H_INP; - const DIRECT_BGR = SWS_DIRECT_BGR; - const ACCURATE_RND = SWS_ACCURATE_RND; - const BITEXACT = SWS_BITEXACT; - const ERROR_DIFFUSION = SWS_ERROR_DIFFUSION; + const FAST_BILINEAR = SWS_FAST_BILINEAR as i32; + const BILINEAR = SWS_BILINEAR as i32; + const BICUBIC = SWS_BICUBIC as i32; + const X = SWS_X as i32; + const POINT = SWS_POINT as i32; + const AREA = SWS_AREA as i32; + const BICUBLIN = SWS_BICUBLIN as i32; + const GAUSS = SWS_GAUSS as i32; + const SINC = SWS_SINC as i32; + const LANCZOS = SWS_LANCZOS as i32; + const SPLINE = SWS_SPLINE as i32; + // const SRC_V_CHR_DROP_MASK = SWS_SRC_V_CHR_DROP_MASK as i32; + // const SRC_V_CHR_DROP_SHIFT = SWS_SRC_V_CHR_DROP_SHIFT as i32; + // const PARAM_DEFAULT = SWS_PARAM_DEFAULT as i32; + const PRINT_INFO = SWS_PRINT_INFO as i32; + const FULL_CHR_H_INT = SWS_FULL_CHR_H_INT as i32; + const FULL_CHR_H_INP = SWS_FULL_CHR_H_INP as i32; + const DIRECT_BGR = SWS_DIRECT_BGR as i32; + const ACCURATE_RND = SWS_ACCURATE_RND as i32; + const BITEXACT = SWS_BITEXACT as i32; + const ERROR_DIFFUSION = SWS_ERROR_DIFFUSION as i32; } } diff --git a/crates/waywe-daemon/src/wallpaper_app.rs b/crates/waywe-daemon/src/wallpaper_app.rs index 71791ccb..8e309adc 100644 --- a/crates/waywe-daemon/src/wallpaper_app.rs +++ b/crates/waywe-daemon/src/wallpaper_app.rs @@ -228,6 +228,7 @@ impl Handle for WallpaperApp { }; runtime.task_pool.emitter.emit(event).unwrap(); + self.wallpaper_states.insert(monitor_id, if info.is_paused { WallpaperState::Paused } else { WallpaperState::Running }); } runtime.control_flow.busy(); @@ -283,6 +284,7 @@ impl Handle for WallpaperApp { let monitor_profile = Monitor { wallpaper_type: ty, path: path.clone(), + is_paused: self.wallpaper_states[&monitor_id].is_paused(), }; if let Err(error) = SetupProfile::default() diff --git a/crates/waywe-ipc/src/profile.rs b/crates/waywe-ipc/src/profile.rs index be818ccd..979d23fd 100644 --- a/crates/waywe-ipc/src/profile.rs +++ b/crates/waywe-ipc/src/profile.rs @@ -17,6 +17,7 @@ use thiserror::Error; pub struct Monitor { pub wallpaper_type: WallpaperType, pub path: PathBuf, + pub is_paused: bool, } #[derive(Clone, Default, PartialEq, Debug, Eq, Encode, Decode)] From 5dc2e272b4110864513e28e9d5c732a50a00ab53 Mon Sep 17 00:00:00 2001 From: Sergey Sushilin Date: Wed, 6 May 2026 03:54:04 +0300 Subject: [PATCH 02/14] Fix reading unexisting field. --- crates/waywe-daemon/src/wallpaper_app.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/waywe-daemon/src/wallpaper_app.rs b/crates/waywe-daemon/src/wallpaper_app.rs index 8e309adc..4666ad02 100644 --- a/crates/waywe-daemon/src/wallpaper_app.rs +++ b/crates/waywe-daemon/src/wallpaper_app.rs @@ -284,7 +284,7 @@ impl Handle for WallpaperApp { let monitor_profile = Monitor { wallpaper_type: ty, path: path.clone(), - is_paused: self.wallpaper_states[&monitor_id].is_paused(), + is_paused: self.wallpaper_states.get(&monitor_id).map_or_else(|| false, |s| s.is_paused()), }; if let Err(error) = SetupProfile::default() From 6e01a8ad66d08c9ea81c9d8e91e9268595f6c22c Mon Sep 17 00:00:00 2001 From: Sergey Sushilin Date: Wed, 6 May 2026 19:16:34 +0300 Subject: [PATCH 03/14] Remove everything. --- crates/waywe-daemon/src/wallpaper_app.rs | 3 +-- crates/waywe-ipc/src/profile.rs | 1 - 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/crates/waywe-daemon/src/wallpaper_app.rs b/crates/waywe-daemon/src/wallpaper_app.rs index 4666ad02..c899c157 100644 --- a/crates/waywe-daemon/src/wallpaper_app.rs +++ b/crates/waywe-daemon/src/wallpaper_app.rs @@ -228,7 +228,6 @@ impl Handle for WallpaperApp { }; runtime.task_pool.emitter.emit(event).unwrap(); - self.wallpaper_states.insert(monitor_id, if info.is_paused { WallpaperState::Paused } else { WallpaperState::Running }); } runtime.control_flow.busy(); @@ -284,8 +283,8 @@ impl Handle for WallpaperApp { let monitor_profile = Monitor { wallpaper_type: ty, path: path.clone(), - is_paused: self.wallpaper_states.get(&monitor_id).map_or_else(|| false, |s| s.is_paused()), }; + debug!("monitor prof {monitor_profile:?} {:?}", self.wallpaper_states); if let Err(error) = SetupProfile::default() .with(monitor_name, monitor_profile) diff --git a/crates/waywe-ipc/src/profile.rs b/crates/waywe-ipc/src/profile.rs index 979d23fd..be818ccd 100644 --- a/crates/waywe-ipc/src/profile.rs +++ b/crates/waywe-ipc/src/profile.rs @@ -17,7 +17,6 @@ use thiserror::Error; pub struct Monitor { pub wallpaper_type: WallpaperType, pub path: PathBuf, - pub is_paused: bool, } #[derive(Clone, Default, PartialEq, Debug, Eq, Encode, Decode)] From 349e4dfd8317c592f7f7e07a5448a0d988acc3a6 Mon Sep 17 00:00:00 2001 From: hack3rmann Date: Wed, 6 May 2026 19:32:41 +0300 Subject: [PATCH 04/14] format code --- crates/video/src/lib.rs | 14 +++++++++++++- crates/waywe-daemon/src/wallpaper_app.rs | 5 ++++- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/crates/video/src/lib.rs b/crates/video/src/lib.rs index f3c9fd44..5e378832 100644 --- a/crates/video/src/lib.rs +++ b/crates/video/src/lib.rs @@ -8,7 +8,19 @@ pub mod time; use bitflags::bitflags; use ffi::va; use ffmpeg_sys_next::{ - AV_PROFILE_UNKNOWN, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, AVPixFmtDescriptor, AVProfile, AVStream, SEEK_SET, SwsContext, SwsFlags::{SWS_ACCURATE_RND, SWS_AREA, SWS_BICUBIC, SWS_BICUBLIN, SWS_BILINEAR, SWS_BITEXACT, SWS_DIRECT_BGR, SWS_ERROR_DIFFUSION, SWS_FAST_BILINEAR, SWS_FULL_CHR_H_INP, SWS_FULL_CHR_H_INT, SWS_GAUSS, SWS_LANCZOS, SWS_POINT, SWS_PRINT_INFO, SWS_SINC, SWS_SPLINE, SWS_X}, av_buffer_get_ref_count, av_codec_iterate, av_find_best_stream, av_frame_alloc, av_frame_free, av_frame_get_buffer, av_frame_unref, av_new_packet, av_packet_alloc, av_packet_free, av_packet_ref, av_packet_unref, av_read_frame, avdevice_register_all, avformat_close_input, avformat_find_stream_info, avformat_open_input, avformat_seek_file, avio_seek, sws_getContext, sws_scale + AV_PROFILE_UNKNOWN, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, + AVPixFmtDescriptor, AVProfile, AVStream, SEEK_SET, SwsContext, + SwsFlags::{ + SWS_ACCURATE_RND, SWS_AREA, SWS_BICUBIC, SWS_BICUBLIN, SWS_BILINEAR, SWS_BITEXACT, + SWS_DIRECT_BGR, SWS_ERROR_DIFFUSION, SWS_FAST_BILINEAR, SWS_FULL_CHR_H_INP, + SWS_FULL_CHR_H_INT, SWS_GAUSS, SWS_LANCZOS, SWS_POINT, SWS_PRINT_INFO, SWS_SINC, + SWS_SPLINE, SWS_X, + }, + av_buffer_get_ref_count, av_codec_iterate, av_find_best_stream, av_frame_alloc, av_frame_free, + av_frame_get_buffer, av_frame_unref, av_new_packet, av_packet_alloc, av_packet_free, + av_packet_ref, av_packet_unref, av_read_frame, avdevice_register_all, avformat_close_input, + avformat_find_stream_info, avformat_open_input, avformat_seek_file, avio_seek, sws_getContext, + sws_scale, }; use glam::UVec2; use std::{ diff --git a/crates/waywe-daemon/src/wallpaper_app.rs b/crates/waywe-daemon/src/wallpaper_app.rs index c899c157..8e21288e 100644 --- a/crates/waywe-daemon/src/wallpaper_app.rs +++ b/crates/waywe-daemon/src/wallpaper_app.rs @@ -284,7 +284,10 @@ impl Handle for WallpaperApp { wallpaper_type: ty, path: path.clone(), }; - debug!("monitor prof {monitor_profile:?} {:?}", self.wallpaper_states); + debug!( + "monitor prof {monitor_profile:?} {:?}", + self.wallpaper_states + ); if let Err(error) = SetupProfile::default() .with(monitor_name, monitor_profile) From 6149795e531f3cd76f2417b7401728353eadb96c Mon Sep 17 00:00:00 2001 From: hack3rmann Date: Wed, 6 May 2026 19:50:27 +0300 Subject: [PATCH 05/14] update `ScalerFlags` --- crates/video/src/lib.rs | 69 ++++++++++++++++++++++++----------------- 1 file changed, 41 insertions(+), 28 deletions(-) diff --git a/crates/video/src/lib.rs b/crates/video/src/lib.rs index 5e378832..f145fc80 100644 --- a/crates/video/src/lib.rs +++ b/crates/video/src/lib.rs @@ -9,13 +9,7 @@ use bitflags::bitflags; use ffi::va; use ffmpeg_sys_next::{ AV_PROFILE_UNKNOWN, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, - AVPixFmtDescriptor, AVProfile, AVStream, SEEK_SET, SwsContext, - SwsFlags::{ - SWS_ACCURATE_RND, SWS_AREA, SWS_BICUBIC, SWS_BICUBLIN, SWS_BILINEAR, SWS_BITEXACT, - SWS_DIRECT_BGR, SWS_ERROR_DIFFUSION, SWS_FAST_BILINEAR, SWS_FULL_CHR_H_INP, - SWS_FULL_CHR_H_INT, SWS_GAUSS, SWS_LANCZOS, SWS_POINT, SWS_PRINT_INFO, SWS_SINC, - SWS_SPLINE, SWS_X, - }, + AVPixFmtDescriptor, AVProfile, AVStream, SEEK_SET, SwsContext, SwsFlags, av_buffer_get_ref_count, av_codec_iterate, av_find_best_stream, av_frame_alloc, av_frame_free, av_frame_get_buffer, av_frame_unref, av_new_packet, av_packet_alloc, av_packet_free, av_packet_ref, av_packet_unref, av_read_frame, avdevice_register_all, avformat_close_input, @@ -1081,27 +1075,46 @@ pub struct ScalerFormat { bitflags! { #[derive(Copy, Clone, Debug, PartialEq, Eq)] pub struct ScalerFlags: i32 { - const FAST_BILINEAR = SWS_FAST_BILINEAR as i32; - const BILINEAR = SWS_BILINEAR as i32; - const BICUBIC = SWS_BICUBIC as i32; - const X = SWS_X as i32; - const POINT = SWS_POINT as i32; - const AREA = SWS_AREA as i32; - const BICUBLIN = SWS_BICUBLIN as i32; - const GAUSS = SWS_GAUSS as i32; - const SINC = SWS_SINC as i32; - const LANCZOS = SWS_LANCZOS as i32; - const SPLINE = SWS_SPLINE as i32; - // const SRC_V_CHR_DROP_MASK = SWS_SRC_V_CHR_DROP_MASK as i32; - // const SRC_V_CHR_DROP_SHIFT = SWS_SRC_V_CHR_DROP_SHIFT as i32; - // const PARAM_DEFAULT = SWS_PARAM_DEFAULT as i32; - const PRINT_INFO = SWS_PRINT_INFO as i32; - const FULL_CHR_H_INT = SWS_FULL_CHR_H_INT as i32; - const FULL_CHR_H_INP = SWS_FULL_CHR_H_INP as i32; - const DIRECT_BGR = SWS_DIRECT_BGR as i32; - const ACCURATE_RND = SWS_ACCURATE_RND as i32; - const BITEXACT = SWS_BITEXACT as i32; - const ERROR_DIFFUSION = SWS_ERROR_DIFFUSION as i32; + /// < fast bilinear filtering + const FAST_BILINEAR = SwsFlags::SWS_FAST_BILINEAR as i32; + /// < bilinear filtering + const BILINEAR = SwsFlags::SWS_BILINEAR as i32; + /// < 2-tap cubic B-spline + const BICUBIC = SwsFlags::SWS_BICUBIC as i32; + /// < experimental + const X = SwsFlags::SWS_X as i32; + /// < nearest neighbor + const POINT = SwsFlags::SWS_POINT as i32; + /// < area averaging + const AREA = SwsFlags::SWS_AREA as i32; + /// < bicubic luma, bilinear chroma + const BICUBLIN = SwsFlags::SWS_BICUBLIN as i32; + /// < gaussian approximation + const GAUSS = SwsFlags::SWS_GAUSS as i32; + /// < unwindowed sinc + const SINC = SwsFlags::SWS_SINC as i32; + /// < 3-tap sinc/sinc + const LANCZOS = SwsFlags::SWS_LANCZOS as i32; + /// < cubic Keys spline + const SPLINE = SwsFlags::SWS_SPLINE as i32; + /// Return an error on underspecified conversions. Without this flag,\n unspecified fields are defaulted to sensible values. + const STRICT = SwsFlags::SWS_STRICT as i32; + /// Emit verbose log of scaling parameters. + const PRINT_INFO = SwsFlags::SWS_PRINT_INFO as i32; + /// Perform full chroma upsampling when upscaling to RGB.\n\n For example, when converting 50x50 yuv420p to 100x100 rgba, setting this flag\n will scale the chroma plane from 25x25 to 100x100 (4:4:4), and then convert\n the 100x100 yuv444p image to rgba in the final output step.\n\n Without this flag, the chroma plane is instead scaled to 50x100 (4:2:2),\n with a single chroma sample being reused for both of the horizontally\n adjacent RGBA output pixels. + const FULL_CHR_H_INT = SwsFlags::SWS_FULL_CHR_H_INT as i32; + /// Perform full chroma interpolation when downscaling RGB sources.\n\n For example, when converting a 100x100 rgba source to 50x50 yuv444p, setting\n this flag will generate a 100x100 (4:4:4) chroma plane, which is then\n downscaled to the required 50x50.\n\n Without this flag, the chroma plane is instead generated at 50x100 (dropping\n every other pixel), before then being downscaled to the required 50x50\n resolution. + const FULL_CHR_H_INP = SwsFlags::SWS_FULL_CHR_H_INP as i32; + /// Force bit-exact output. This will prevent the use of platform-specific\n optimizations that may lead to slight difference in rounding, in favor\n of always maintaining exact bit output compatibility with the reference\n C code.\n\n Note: It is recommended to set both of these flags simultaneously. + const ACCURATE_RND = SwsFlags::SWS_ACCURATE_RND as i32; + /// Force bit-exact output. This will prevent the use of platform-specific\n optimizations that may lead to slight difference in rounding, in favor\n of always maintaining exact bit output compatibility with the reference\n C code.\n\n Note: It is recommended to set both of these flags simultaneously. + const BITEXACT = SwsFlags::SWS_BITEXACT as i32; + /// Allow using experimental new code paths. This may be faster, slower,\n or produce different output, with semantics subject to change at any\n point in time. For testing and debugging purposes only. + const UNSTABLE = SwsFlags::SWS_UNSTABLE as i32; + /// < This flag has no effect + const DIRECT_BGR = SwsFlags::SWS_DIRECT_BGR as i32; + /// < Set `SwsContext.dither` instead + const ERROR_DIFFUSION = SwsFlags::SWS_ERROR_DIFFUSION as i32; } } From 11115c955f77eff42e9eca785ae30fc0ec591e9b Mon Sep 17 00:00:00 2001 From: Sergey Sushilin Date: Wed, 6 May 2026 20:02:12 +0300 Subject: [PATCH 06/14] Remove useless debug. --- crates/waywe-daemon/src/wallpaper_app.rs | 4 ---- 1 file changed, 4 deletions(-) diff --git a/crates/waywe-daemon/src/wallpaper_app.rs b/crates/waywe-daemon/src/wallpaper_app.rs index 8e21288e..71791ccb 100644 --- a/crates/waywe-daemon/src/wallpaper_app.rs +++ b/crates/waywe-daemon/src/wallpaper_app.rs @@ -284,10 +284,6 @@ impl Handle for WallpaperApp { wallpaper_type: ty, path: path.clone(), }; - debug!( - "monitor prof {monitor_profile:?} {:?}", - self.wallpaper_states - ); if let Err(error) = SetupProfile::default() .with(monitor_name, monitor_profile) From 678ae7e6e94260bf27458eef444943c8993b02a5 Mon Sep 17 00:00:00 2001 From: Sergey Sushilin Date: Wed, 6 May 2026 21:04:24 +0300 Subject: [PATCH 07/14] Fix repeate_stream(). --- crates/video/src/lib.rs | 33 ++++++++++++++++++++++++--------- 1 file changed, 24 insertions(+), 9 deletions(-) diff --git a/crates/video/src/lib.rs b/crates/video/src/lib.rs index f145fc80..a10d707e 100644 --- a/crates/video/src/lib.rs +++ b/crates/video/src/lib.rs @@ -285,19 +285,34 @@ impl FormatContext { }) } - /// Seeks to the start of the input file pub fn repeat_stream(&mut self, index: usize) -> Result<(), BackendError> { - let io_context_ptr = unsafe { (*self.as_raw().as_ptr()).pb }; - let _new_pos = - BackendError::result_or_u64(unsafe { avio_seek(io_context_ptr, 0, SEEK_SET) })?; + let ctx = self.as_raw().as_ptr(); - let stream = &self.streams()[index]; - let duration = unsafe { (*stream.as_raw().as_ptr()).duration }; + let ret = unsafe { + ffmpeg_sys_next::av_seek_frame(ctx, index as i32, 0, ffmpeg_sys_next::AVSEEK_FLAG_BACKWARD) + }; + BackendError::result_of(ret)?; - BackendError::result_of(unsafe { - avformat_seek_file(self.as_raw().as_ptr(), index as i32, 0, 0, duration, 0) - }) + Ok(()) } + + // /// Seeks to the start of the input file + // pub fn repeat_stream(&mut self, index: usize) -> Result<(), BackendError> { + // let io_context_ptr = unsafe { (*self.as_raw().as_ptr()).pb }; + // let _new_pos = + // BackendError::result_or_u64(unsafe { avio_seek(io_context_ptr, 0, SEEK_SET) })?; + + // dbg!("position", _new_pos); + + // let stream = &self.streams()[index]; + // let duration = unsafe { (*stream.as_raw().as_ptr()).duration }; + + // let c = unsafe { + // avformat_seek_file(self.as_raw().as_ptr(), index as i32, 0, 0, duration, 0) + // }; + // dbg!("c ", c, self.as_raw().as_ptr(), index, duration); + // BackendError::result_of(c) + // } } impl Drop for FormatContext { From 025b039b362c270c9466f65aa9ed84fcad6b3ee9 Mon Sep 17 00:00:00 2001 From: Sergey Sushilin Date: Wed, 6 May 2026 21:49:42 +0300 Subject: [PATCH 08/14] Fix repeat_stream(). --- crates/video/src/lib.rs | 106 ++++++++++++++++++++++++++++---- crates/waywe-scene/src/video.rs | 2 +- 2 files changed, 94 insertions(+), 14 deletions(-) diff --git a/crates/video/src/lib.rs b/crates/video/src/lib.rs index a10d707e..b1bc2298 100644 --- a/crates/video/src/lib.rs +++ b/crates/video/src/lib.rs @@ -8,13 +8,7 @@ pub mod time; use bitflags::bitflags; use ffi::va; use ffmpeg_sys_next::{ - AV_PROFILE_UNKNOWN, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, - AVPixFmtDescriptor, AVProfile, AVStream, SEEK_SET, SwsContext, SwsFlags, - av_buffer_get_ref_count, av_codec_iterate, av_find_best_stream, av_frame_alloc, av_frame_free, - av_frame_get_buffer, av_frame_unref, av_new_packet, av_packet_alloc, av_packet_free, - av_packet_ref, av_packet_unref, av_read_frame, avdevice_register_all, avformat_close_input, - avformat_find_stream_info, avformat_open_input, avformat_seek_file, avio_seek, sws_getContext, - sws_scale, + AV_PROFILE_UNKNOWN, AVCodecConfig, AVCodecContext, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, AVPixFmtDescriptor, AVProfile, AVStream, SEEK_SET, SwsContext, SwsFlags, av_buffer_get_ref_count, av_codec_iterate, av_find_best_stream, av_frame_alloc, av_frame_free, av_frame_get_buffer, av_frame_unref, av_new_packet, av_packet_alloc, av_packet_free, av_packet_ref, av_packet_unref, av_read_frame, avdevice_register_all, avformat_close_input, avformat_find_stream_info, avformat_open_input, avformat_seek_file, avio_seek, sws_getContext, sws_scale }; use glam::UVec2; use std::{ @@ -285,17 +279,103 @@ impl FormatContext { }) } - pub fn repeat_stream(&mut self, index: usize) -> Result<(), BackendError> { - let ctx = self.as_raw().as_ptr(); +pub fn repeat_stream( + &mut self, + codec_context: *mut AVCodecContext, + index: usize, +) -> Result<(), BackendError> { + let ctx = self.as_raw().as_ptr(); - let ret = unsafe { - ffmpeg_sys_next::av_seek_frame(ctx, index as i32, 0, ffmpeg_sys_next::AVSEEK_FLAG_BACKWARD) + // --- 1. Validate stream index --- + let stream_index = index as i32; + + unsafe { + if stream_index < 0 || stream_index >= (*ctx).nb_streams as i32 { + return Err(BackendError::INVALID_DATA); + } + + // --- 2. Ensure seekability --- + let pb = (*ctx).pb; + if pb.is_null() || (*pb).seekable == 0 { + return Err(BackendError::INVALID_DATA); + } + } + + // --- 3. Perform seek --- + // + // Use av_seek_frame: + // - simpler and more robust than avformat_seek_file + // - AVSEEK_FLAG_BACKWARD ensures landing on a keyframe + // + let ret = unsafe { + ffmpeg_sys_next::av_seek_frame( + ctx, + stream_index, // you explicitly want this stream + 0, // timestamp = start + ffmpeg_sys_next::AVSEEK_FLAG_BACKWARD, + ) + }; + + if ret < 0 { + // --- 4. Fallback: try generic seek --- + let ret2 = unsafe { + ffmpeg_sys_next::av_seek_frame( + ctx, + -1, // let FFmpeg choose best stream + 0, + ffmpeg_sys_next::AVSEEK_FLAG_BACKWARD, + ) }; - BackendError::result_of(ret)?; - Ok(()) + if ret2 < 0 { + return Err(BackendError::INVALID_DATA); + } } + // --- 5. Flush decoder state (CRITICAL) --- + unsafe { + if !codec_context.is_null() { + ffmpeg_sys_next::avcodec_flush_buffers(codec_context); + } + } + + // --- 6. (Optional but recommended) drop any buffered packets --- + // If you maintain your own packet queue, clear it here. + + Ok(()) +} + +// pub fn repeat_stream(&mut self, codec_context: *mut AVCodecContext, index: usize) -> Result<(), BackendError> { +// let ctx = self.as_raw().as_ptr(); + +// unsafe { +// let pb = (*ctx).pb; +// if pb.is_null() { +// return Err(BackendError::INVALID_DATA); +// } + +// BackendError::result_or_u64(avio_seek(pb, 0, SEEK_SET))?; + +// ffmpeg_sys_next::avio_flush(pb); +// ffmpeg_sys_next::avformat_flush(ctx); + +// let ret = avformat_seek_file( +// ctx, +// index as i32, +// i64::MIN, +// 0, +// i64::MAX, +// ffmpeg_sys_next::AVSEEK_FLAG_BACKWARD, +// ); + +// BackendError::result_of(ret)?; + +// ffmpeg_sys_next::avcodec_flush_buffers(codec_context); +// } + +// Ok(()) +// } + // /// Seeks to the start of the input file // pub fn repeat_stream(&mut self, index: usize) -> Result<(), BackendError> { // let io_context_ptr = unsafe { (*self.as_raw().as_ptr()).pb }; diff --git a/crates/waywe-scene/src/video.rs b/crates/waywe-scene/src/video.rs index d76d66be..731631a6 100644 --- a/crates/waywe-scene/src/video.rs +++ b/crates/waywe-scene/src/video.rs @@ -217,7 +217,7 @@ impl Video { let best_index = self.best_stream_index; - if let Err(error) = self.format_context.repeat_stream(best_index) { + if let Err(error) = self.format_context.repeat_stream(self.codec_context.as_raw().as_ptr(), best_index) { panic!("failed to repeat video stream: {error}"); } From f05af9668d68728ba38c2c9632c3c7379f7c3245 Mon Sep 17 00:00:00 2001 From: Sergey Sushilin Date: Thu, 7 May 2026 00:34:06 +0300 Subject: [PATCH 09/14] Fix repeat_stream(). --- crates/video/src/lib.rs | 109 +++++++++++++++++++++------------------- 1 file changed, 58 insertions(+), 51 deletions(-) diff --git a/crates/video/src/lib.rs b/crates/video/src/lib.rs index b1bc2298..7fc79b97 100644 --- a/crates/video/src/lib.rs +++ b/crates/video/src/lib.rs @@ -279,71 +279,78 @@ impl FormatContext { }) } -pub fn repeat_stream( - &mut self, - codec_context: *mut AVCodecContext, - index: usize, -) -> Result<(), BackendError> { - let ctx = self.as_raw().as_ptr(); - - // --- 1. Validate stream index --- - let stream_index = index as i32; - - unsafe { - if stream_index < 0 || stream_index >= (*ctx).nb_streams as i32 { - return Err(BackendError::INVALID_DATA); - } + pub fn repeat_stream( + &mut self, + codec_context: *mut AVCodecContext, + index: usize, + ) -> Result<(), BackendError> { + let ctx = self.as_raw().as_ptr(); - // --- 2. Ensure seekability --- - let pb = (*ctx).pb; - if pb.is_null() || (*pb).seekable == 0 { - return Err(BackendError::INVALID_DATA); - } - } + // --- 1. Validate context and stream index --- + unsafe { + if ctx.is_null() { + return Err(BackendError::INVALID_DATA); + } - // --- 3. Perform seek --- - // - // Use av_seek_frame: - // - simpler and more robust than avformat_seek_file - // - AVSEEK_FLAG_BACKWARD ensures landing on a keyframe - // - let ret = unsafe { - ffmpeg_sys_next::av_seek_frame( - ctx, - stream_index, // you explicitly want this stream - 0, // timestamp = start - ffmpeg_sys_next::AVSEEK_FLAG_BACKWARD, - ) - }; + let stream_index = index as i32; + if stream_index < 0 || stream_index >= (*ctx).nb_streams as i32 { + return Err(BackendError::INVALID_DATA); + } + + // --- 2. Verify seekability --- + let pb = (*ctx).pb; + if pb.is_null() { + return Err(BackendError::INVALID_DATA); + } - if ret < 0 { - // --- 4. Fallback: try generic seek --- - let ret2 = unsafe { + // Check if stream is seekable (seekable field != 0) + if (*pb).seekable == 0 { + return Err(BackendError::INVALID_DATA); + } + } + + // --- 3. Perform the seek operation --- + // av_seek_frame is preferred over avformat_seek_file for simplicity + // AVSEEK_FLAG_BACKWARD ensures we land on a keyframe + let ret = unsafe { ffmpeg_sys_next::av_seek_frame( ctx, - -1, // let FFmpeg choose best stream - 0, + index as i32, + 0, // timestamp = 0 (start of stream) ffmpeg_sys_next::AVSEEK_FLAG_BACKWARD, ) }; - if ret2 < 0 { - return Err(BackendError::INVALID_DATA); + if ret < 0 { + // --- 4. Fallback: try generic seek (any stream) --- + let ret_fallback = unsafe { + ffmpeg_sys_next::av_seek_frame( + ctx, + -1, // let FFmpeg choose the best stream + 0, + ffmpeg_sys_next::AVSEEK_FLAG_BACKWARD, + ) + }; + + if ret_fallback < 0 { + return Err(BackendError::INVALID_DATA); + } } - } - // --- 5. Flush decoder state (CRITICAL) --- - unsafe { - if !codec_context.is_null() { - ffmpeg_sys_next::avcodec_flush_buffers(codec_context); + // --- 5. CRITICAL: Flush decoder state --- + // This clears any pending frames in the decoder + unsafe { + if !codec_context.is_null() { + ffmpeg_sys_next::avcodec_flush_buffers(codec_context); + } } - } - // --- 6. (Optional but recommended) drop any buffered packets --- - // If you maintain your own packet queue, clear it here. + // --- 6. Clear any buffered packets (application responsibility) --- + // NOTE: The caller should clear their own packet queue/buffer here + // This is crucial to avoid feeding old packets to the decoder - Ok(()) -} + Ok(()) + } // pub fn repeat_stream(&mut self, codec_context: *mut AVCodecContext, index: usize) -> Result<(), BackendError> { // let ctx = self.as_raw().as_ptr(); From 1b66379b70f924911f4cf64e979c647c0152bddb Mon Sep 17 00:00:00 2001 From: SergeGris <42321357+SergeGris@users.noreply.github.com> Date: Thu, 7 May 2026 00:39:52 +0300 Subject: [PATCH 10/14] refactor: use avio_seek to reset stream to first frame in repeat_stream The updated repeat_stream method now: 1. Uses avio_seek() to seek the I/O layer to byte 0 (start of file) 2. Flushes I/O and format buffers with avio_flush() and avformat_flush() 3. Uses av_seek_frame() to reset the demuxer 4. Flushes decoder state with avcodec_flush_buffers() 5. Includes comprehensive comments and improved error handling This approach is more robust than pure high-level seeking and matches the FFmpeg recommended practice for stream repetition in modern versions. --- crates/video/src/lib.rs | 100 +++++++++++++++------------------------- 1 file changed, 37 insertions(+), 63 deletions(-) diff --git a/crates/video/src/lib.rs b/crates/video/src/lib.rs index 7fc79b97..1aa3d514 100644 --- a/crates/video/src/lib.rs +++ b/crates/video/src/lib.rs @@ -8,7 +8,7 @@ pub mod time; use bitflags::bitflags; use ffi::va; use ffmpeg_sys_next::{ - AV_PROFILE_UNKNOWN, AVCodecConfig, AVCodecContext, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, AVPixFmtDescriptor, AVProfile, AVStream, SEEK_SET, SwsContext, SwsFlags, av_buffer_get_ref_count, av_codec_iterate, av_find_best_stream, av_frame_alloc, av_frame_free, av_frame_get_buffer, av_frame_unref, av_new_packet, av_packet_alloc, av_packet_free, av_packet_ref, av_packet_unref, av_read_frame, avdevice_register_all, avformat_close_input, avformat_find_stream_info, avformat_open_input, avformat_seek_file, avio_seek, sws_getContext, sws_scale + AV_PROFILE_UNKNOWN, AVCodecConfig, AVCodecContext, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, AVPixFmtDescriptor, AVProfile, AVStream, SEEK_SET, SwsContext, SwsFlags, av_buffe[...] }; use glam::UVec2; use std::{ @@ -279,6 +279,19 @@ impl FormatContext { }) } + /// Seeks to the beginning of the stream and resets decoder state + /// + /// Uses the I/O layer (avio) to seek to byte 0, then seeks the format context + /// back to the start, and flushes the decoder state. + /// + /// # Arguments + /// + /// * `codec_context` - The codec context to flush after seeking (can be null) + /// * `index` - The stream index to seek in + /// + /// # Note + /// + /// The caller should clear their own packet queue/buffer after calling this method. pub fn repeat_stream( &mut self, codec_context: *mut AVCodecContext, @@ -297,7 +310,7 @@ impl FormatContext { return Err(BackendError::INVALID_DATA); } - // --- 2. Verify seekability --- + // --- 2. Verify I/O context exists and is seekable --- let pb = (*ctx).pb; if pb.is_null() { return Err(BackendError::INVALID_DATA); @@ -307,11 +320,21 @@ impl FormatContext { if (*pb).seekable == 0 { return Err(BackendError::INVALID_DATA); } + + // --- 3. Use avio to seek to byte 0 (start of file) --- + // This is the low-level I/O seek operation + let seek_result = ffmpeg_sys_next::avio_seek(pb, 0, SEEK_SET); + if seek_result < 0 { + return Err(BackendError::INVALID_DATA); + } + + // --- 4. Flush the I/O write buffers and format context state --- + ffmpeg_sys_next::avio_flush(pb); + ffmpeg_sys_next::avformat_flush(ctx); } - // --- 3. Perform the seek operation --- - // av_seek_frame is preferred over avformat_seek_file for simplicity - // AVSEEK_FLAG_BACKWARD ensures we land on a keyframe + // --- 5. Seek the format context to the start of the stream --- + // This resets the demuxer state let ret = unsafe { ffmpeg_sys_next::av_seek_frame( ctx, @@ -322,7 +345,7 @@ impl FormatContext { }; if ret < 0 { - // --- 4. Fallback: try generic seek (any stream) --- + // --- 6. Fallback: try generic seek (any stream) --- let ret_fallback = unsafe { ffmpeg_sys_next::av_seek_frame( ctx, @@ -337,69 +360,20 @@ impl FormatContext { } } - // --- 5. CRITICAL: Flush decoder state --- - // This clears any pending frames in the decoder + // --- 7. CRITICAL: Flush decoder state --- + // This clears any pending frames in the decoder buffer unsafe { if !codec_context.is_null() { ffmpeg_sys_next::avcodec_flush_buffers(codec_context); } } - // --- 6. Clear any buffered packets (application responsibility) --- + // --- 8. Clear any buffered packets (application responsibility) --- // NOTE: The caller should clear their own packet queue/buffer here // This is crucial to avoid feeding old packets to the decoder Ok(()) } - -// pub fn repeat_stream(&mut self, codec_context: *mut AVCodecContext, index: usize) -> Result<(), BackendError> { -// let ctx = self.as_raw().as_ptr(); - -// unsafe { -// let pb = (*ctx).pb; -// if pb.is_null() { -// return Err(BackendError::INVALID_DATA); -// } - -// BackendError::result_or_u64(avio_seek(pb, 0, SEEK_SET))?; - -// ffmpeg_sys_next::avio_flush(pb); -// ffmpeg_sys_next::avformat_flush(ctx); - -// let ret = avformat_seek_file( -// ctx, -// index as i32, -// i64::MIN, -// 0, -// i64::MAX, -// ffmpeg_sys_next::AVSEEK_FLAG_BACKWARD, -// ); - -// BackendError::result_of(ret)?; - -// ffmpeg_sys_next::avcodec_flush_buffers(codec_context); -// } - -// Ok(()) -// } - - // /// Seeks to the start of the input file - // pub fn repeat_stream(&mut self, index: usize) -> Result<(), BackendError> { - // let io_context_ptr = unsafe { (*self.as_raw().as_ptr()).pb }; - // let _new_pos = - // BackendError::result_or_u64(unsafe { avio_seek(io_context_ptr, 0, SEEK_SET) })?; - - // dbg!("position", _new_pos); - - // let stream = &self.streams()[index]; - // let duration = unsafe { (*stream.as_raw().as_ptr()).duration }; - - // let c = unsafe { - // avformat_seek_file(self.as_raw().as_ptr(), index as i32, 0, 0, duration, 0) - // }; - // dbg!("c ", c, self.as_raw().as_ptr(), index, duration); - // BackendError::result_of(c) - // } } impl Drop for FormatContext { @@ -1203,15 +1177,15 @@ bitflags! { const STRICT = SwsFlags::SWS_STRICT as i32; /// Emit verbose log of scaling parameters. const PRINT_INFO = SwsFlags::SWS_PRINT_INFO as i32; - /// Perform full chroma upsampling when upscaling to RGB.\n\n For example, when converting 50x50 yuv420p to 100x100 rgba, setting this flag\n will scale the chroma plane from 25x25 to 100x100 (4:4:4), and then convert\n the 100x100 yuv444p image to rgba in the final output step.\n\n Without this flag, the chroma plane is instead scaled to 50x100 (4:2:2),\n with a single chroma sample being reused for both of the horizontally\n adjacent RGBA output pixels. + /// Perform full chroma upsampling when upscaling to RGB.\n\n For example, when converting 50x50 yuv420p to 100x100 rgba, setting this flag\n will scale the chroma plane from 25x25 to 100x100[...] const FULL_CHR_H_INT = SwsFlags::SWS_FULL_CHR_H_INT as i32; - /// Perform full chroma interpolation when downscaling RGB sources.\n\n For example, when converting a 100x100 rgba source to 50x50 yuv444p, setting\n this flag will generate a 100x100 (4:4:4) chroma plane, which is then\n downscaled to the required 50x50.\n\n Without this flag, the chroma plane is instead generated at 50x100 (dropping\n every other pixel), before then being downscaled to the required 50x50\n resolution. + /// Perform full chroma interpolation when downscaling RGB sources.\n\n For example, when converting a 100x100 rgba source to 50x50 yuv444p, setting\n this flag will generate a 100x100 (4:4:4[...] const FULL_CHR_H_INP = SwsFlags::SWS_FULL_CHR_H_INP as i32; - /// Force bit-exact output. This will prevent the use of platform-specific\n optimizations that may lead to slight difference in rounding, in favor\n of always maintaining exact bit output compatibility with the reference\n C code.\n\n Note: It is recommended to set both of these flags simultaneously. + /// Force bit-exact output. This will prevent the use of platform-specific\n optimizations that may lead to slight difference in rounding, in favor\n of always maintaining exact bit output co[...] const ACCURATE_RND = SwsFlags::SWS_ACCURATE_RND as i32; - /// Force bit-exact output. This will prevent the use of platform-specific\n optimizations that may lead to slight difference in rounding, in favor\n of always maintaining exact bit output compatibility with the reference\n C code.\n\n Note: It is recommended to set both of these flags simultaneously. + /// Force bit-exact output. This will prevent the use of platform-specific\n optimizations that may lead to slight difference in rounding, in favor\n of always maintaining exact bit output co[...] const BITEXACT = SwsFlags::SWS_BITEXACT as i32; - /// Allow using experimental new code paths. This may be faster, slower,\n or produce different output, with semantics subject to change at any\n point in time. For testing and debugging purposes only. + /// Allow using experimental new code paths. This may be faster, slower,\n or produce different output, with semantics subject to change at any\n point in time. For testing and debugging purp[...] const UNSTABLE = SwsFlags::SWS_UNSTABLE as i32; /// < This flag has no effect const DIRECT_BGR = SwsFlags::SWS_DIRECT_BGR as i32; From dffb24d173338f1d5763a9d5c75a340c41fa5da0 Mon Sep 17 00:00:00 2001 From: SergeGris <42321357+SergeGris@users.noreply.github.com> Date: Thu, 7 May 2026 01:17:24 +0300 Subject: [PATCH 11/14] fix: use safe high-level av_seek_frame only for reliable stream reset Removed low-level avio_seek operations that cause segfaults. The new approach: 1. Only uses av_seek_frame with proper flags (AVSEEK_FLAG_BACKWARD) 2. Flushes decoder buffers after seeking 3. Avoids mixing low-level I/O with format context operations This is more reliable and safer across different file formats and FFmpeg versions. --- crates/video/src/lib.rs | 59 ++++++++--------------------------------- 1 file changed, 11 insertions(+), 48 deletions(-) diff --git a/crates/video/src/lib.rs b/crates/video/src/lib.rs index 1aa3d514..4ade4320 100644 --- a/crates/video/src/lib.rs +++ b/crates/video/src/lib.rs @@ -279,10 +279,11 @@ impl FormatContext { }) } - /// Seeks to the beginning of the stream and resets decoder state - /// - /// Uses the I/O layer (avio) to seek to byte 0, then seeks the format context - /// back to the start, and flushes the decoder state. + /// Seeks to the beginning of the stream and resets decoder state. + /// + /// Uses high-level FFmpeg seek API (`av_seek_frame`) to safely reset to the + /// start of the stream. The caller is responsible for clearing their own + /// packet queue/buffer after calling this method. /// /// # Arguments /// @@ -291,7 +292,8 @@ impl FormatContext { /// /// # Note /// - /// The caller should clear their own packet queue/buffer after calling this method. + /// This method only uses high-level FFmpeg APIs to avoid state corruption. + /// Low-level I/O operations are avoided for safety and stability. pub fn repeat_stream( &mut self, codec_context: *mut AVCodecContext, @@ -299,42 +301,7 @@ impl FormatContext { ) -> Result<(), BackendError> { let ctx = self.as_raw().as_ptr(); - // --- 1. Validate context and stream index --- - unsafe { - if ctx.is_null() { - return Err(BackendError::INVALID_DATA); - } - - let stream_index = index as i32; - if stream_index < 0 || stream_index >= (*ctx).nb_streams as i32 { - return Err(BackendError::INVALID_DATA); - } - - // --- 2. Verify I/O context exists and is seekable --- - let pb = (*ctx).pb; - if pb.is_null() { - return Err(BackendError::INVALID_DATA); - } - - // Check if stream is seekable (seekable field != 0) - if (*pb).seekable == 0 { - return Err(BackendError::INVALID_DATA); - } - - // --- 3. Use avio to seek to byte 0 (start of file) --- - // This is the low-level I/O seek operation - let seek_result = ffmpeg_sys_next::avio_seek(pb, 0, SEEK_SET); - if seek_result < 0 { - return Err(BackendError::INVALID_DATA); - } - - // --- 4. Flush the I/O write buffers and format context state --- - ffmpeg_sys_next::avio_flush(pb); - ffmpeg_sys_next::avformat_flush(ctx); - } - - // --- 5. Seek the format context to the start of the stream --- - // This resets the demuxer state + // Seek to timestamp 0 with AVSEEK_FLAG_BACKWARD to land on keyframe let ret = unsafe { ffmpeg_sys_next::av_seek_frame( ctx, @@ -344,8 +311,8 @@ impl FormatContext { ) }; + // If stream-specific seek fails, try generic seek if ret < 0 { - // --- 6. Fallback: try generic seek (any stream) --- let ret_fallback = unsafe { ffmpeg_sys_next::av_seek_frame( ctx, @@ -360,18 +327,14 @@ impl FormatContext { } } - // --- 7. CRITICAL: Flush decoder state --- - // This clears any pending frames in the decoder buffer + // Flush decoder buffers to clear any pending frames unsafe { if !codec_context.is_null() { ffmpeg_sys_next::avcodec_flush_buffers(codec_context); } } - // --- 8. Clear any buffered packets (application responsibility) --- - // NOTE: The caller should clear their own packet queue/buffer here - // This is crucial to avoid feeding old packets to the decoder - + // Caller must clear their own packet queue/buffer Ok(()) } } From 550378d43e934123582f34ccc007892b955ea99b Mon Sep 17 00:00:00 2001 From: Sergey Sushilin Date: Thu, 7 May 2026 05:16:18 +0300 Subject: [PATCH 12/14] Update repeat_stream(). --- crates/video/src/lib.rs | 71 +++++++++++---------------------- crates/waywe-scene/src/video.rs | 5 ++- 2 files changed, 28 insertions(+), 48 deletions(-) diff --git a/crates/video/src/lib.rs b/crates/video/src/lib.rs index 4ade4320..7945a05b 100644 --- a/crates/video/src/lib.rs +++ b/crates/video/src/lib.rs @@ -8,7 +8,13 @@ pub mod time; use bitflags::bitflags; use ffi::va; use ffmpeg_sys_next::{ - AV_PROFILE_UNKNOWN, AVCodecConfig, AVCodecContext, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, AVPixFmtDescriptor, AVProfile, AVStream, SEEK_SET, SwsContext, SwsFlags, av_buffe[...] + AV_PROFILE_UNKNOWN, AVCodecContext, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, + AVPixFmtDescriptor, AVProfile, AVSEEK_FLAG_BACKWARD, AVStream, SwsContext, SwsFlags, + av_buffer_get_ref_count, av_codec_iterate, av_find_best_stream, av_frame_alloc, av_frame_free, + av_frame_get_buffer, av_frame_unref, av_new_packet, av_packet_alloc, av_packet_free, + av_packet_ref, av_packet_unref, av_read_frame, av_seek_frame, avcodec_flush_buffers, + avdevice_register_all, avformat_close_input, avformat_find_stream_info, avformat_open_input, + sws_getContext, sws_scale, }; use glam::UVec2; use std::{ @@ -279,63 +285,34 @@ impl FormatContext { }) } - /// Seeks to the beginning of the stream and resets decoder state. - /// - /// Uses high-level FFmpeg seek API (`av_seek_frame`) to safely reset to the - /// start of the stream. The caller is responsible for clearing their own - /// packet queue/buffer after calling this method. - /// - /// # Arguments - /// - /// * `codec_context` - The codec context to flush after seeking (can be null) - /// * `index` - The stream index to seek in - /// - /// # Note - /// - /// This method only uses high-level FFmpeg APIs to avoid state corruption. - /// Low-level I/O operations are avoided for safety and stability. pub fn repeat_stream( &mut self, codec_context: *mut AVCodecContext, index: usize, ) -> Result<(), BackendError> { - let ctx = self.as_raw().as_ptr(); - - // Seek to timestamp 0 with AVSEEK_FLAG_BACKWARD to land on keyframe - let ret = unsafe { - ffmpeg_sys_next::av_seek_frame( - ctx, - index as i32, - 0, // timestamp = 0 (start of stream) - ffmpeg_sys_next::AVSEEK_FLAG_BACKWARD, - ) - }; + unsafe { + let ctx = self.as_raw().as_ptr(); - // If stream-specific seek fails, try generic seek - if ret < 0 { - let ret_fallback = unsafe { - ffmpeg_sys_next::av_seek_frame( - ctx, - -1, // let FFmpeg choose the best stream - 0, - ffmpeg_sys_next::AVSEEK_FLAG_BACKWARD, - ) - }; - - if ret_fallback < 0 { + if ctx.is_null() || codec_context.is_null() { return Err(BackendError::INVALID_DATA); } - } - // Flush decoder buffers to clear any pending frames - unsafe { - if !codec_context.is_null() { - ffmpeg_sys_next::avcodec_flush_buffers(codec_context); + // Seek to stream start + let mut ret = av_seek_frame(ctx, index as i32, 0, AVSEEK_FLAG_BACKWARD); + + // Fallback for containers that dislike explicit stream seek + if ret < 0 { + ret = av_seek_frame(ctx, -1, 0, AVSEEK_FLAG_BACKWARD); } - } - // Caller must clear their own packet queue/buffer - Ok(()) + if ret < 0 { + return BackendError::result_of(ret); + } + + // Reset decoder state + avcodec_flush_buffers(codec_context); + Ok(()) + } } } diff --git a/crates/waywe-scene/src/video.rs b/crates/waywe-scene/src/video.rs index 731631a6..724e6b5f 100644 --- a/crates/waywe-scene/src/video.rs +++ b/crates/waywe-scene/src/video.rs @@ -217,7 +217,10 @@ impl Video { let best_index = self.best_stream_index; - if let Err(error) = self.format_context.repeat_stream(self.codec_context.as_raw().as_ptr(), best_index) { + if let Err(error) = self + .format_context + .repeat_stream(self.codec_context.as_raw().as_ptr(), best_index) + { panic!("failed to repeat video stream: {error}"); } From 9ac00e0fd8b430f12769e6ff5a8852537e26e217 Mon Sep 17 00:00:00 2001 From: Sergey Sushilin Date: Thu, 7 May 2026 05:24:27 +0300 Subject: [PATCH 13/14] Fix call of repeat_stream(). --- crates/video/src/hardware.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/video/src/hardware.rs b/crates/video/src/hardware.rs index eea7fec1..15dc799e 100644 --- a/crates/video/src/hardware.rs +++ b/crates/video/src/hardware.rs @@ -309,7 +309,7 @@ mod tests { let packet = match format_context.read_any_packet() { Ok(packet) => packet, Err(BackendError::EOF) => { - format_context.repeat_stream(best_stream_index).unwrap(); + format_context.repeat_stream(codec_context.as_raw().as_ptr(), best_stream_index).unwrap(); continue; } result @ Err(..) => result.unwrap(), From de42662916a69c35f263038615a0e0eb19c96038 Mon Sep 17 00:00:00 2001 From: Sergey Sushilin Date: Sat, 18 Jul 2026 05:00:49 +0300 Subject: [PATCH 14/14] Update version of handling reset stream --- Cargo.lock | 1333 ++++++++++----------- crates/examples/waywe-test-scene/build.rs | 71 ++ crates/video/src/lib.rs | 162 +-- 3 files changed, 809 insertions(+), 757 deletions(-) create mode 100644 crates/examples/waywe-test-scene/build.rs diff --git a/Cargo.lock b/Cargo.lock index 553a5ef1..879c8688 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2,15 +2,6 @@ # It is not intended for manual editing. version = 4 -[[package]] -name = "addr2line" -version = "0.25.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b5d307320b3181d6d7954e663bd7c774a838b8220fe0593c86d9fb09f498b4b" -dependencies = [ - "gimli", -] - [[package]] name = "adler2" version = "2.0.1" @@ -19,13 +10,22 @@ checksum = "320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa" [[package]] name = "aho-corasick" -version = "1.1.3" +version = "1.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" +checksum = "ddd31a130427c27518df266943a5308ed92d4b226cc639f5a8f1002816174301" dependencies = [ "memchr", ] +[[package]] +name = "aligned" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee4508988c62edf04abd8d92897fca0c2995d907ce1dfeaf369dac3716a40685" +dependencies = [ + "as-slice", +] + [[package]] name = "aligned-vec" version = "0.6.4" @@ -52,9 +52,9 @@ dependencies = [ [[package]] name = "anstream" -version = "0.6.21" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43d5b281e737544384e969a5ccad3f1cdd24b48086a0fc1b2a5262a26b8f4f4a" +checksum = "824a212faf96e9acacdbd09febd34438f8f711fb84e09a8916013cd7815ca28d" dependencies = [ "anstyle", "anstyle-parse", @@ -67,44 +67,53 @@ dependencies = [ [[package]] name = "anstyle" -version = "1.0.13" +version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5192cca8006f1fd4f7237516f40fa183bb07f8fbdfedaa0036de5ea9b0b45e78" +checksum = "940b3a0ca603d1eade50a4846a2afffd5ef57a9feac2c0e2ec2e14f9ead76000" [[package]] name = "anstyle-parse" -version = "0.2.7" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e7644824f0aa2c7b9384579234ef10eb7efb6a0deb83f9630a49594dd9c15c2" +checksum = "52ce7f38b242319f7cabaa6813055467063ecdc9d355bbb4ce0c68908cd8130e" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.1.4" +version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e231f6134f61b71076a3eab506c379d4f36122f2af15a9ff04415ea4c3339e2" +checksum = "40c48f72fd53cd289104fc64099abca73db4166ad86ea0b4341abe65af83dadc" dependencies = [ - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] name = "anstyle-wincon" -version = "3.0.10" +version = "3.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e0633414522a32ffaac8ac6cc8f748e090c5717661fddeea04219e2344f5f2a" +checksum = "291e6a250ff86cd4a820112fb8898808a366d8f9f58ce16d1f538353ad55747d" dependencies = [ "anstyle", "once_cell_polyfill", - "windows-sys 0.60.2", + "windows-sys 0.61.2", ] [[package]] name = "anyhow" -version = "1.0.100" +version = "1.0.103" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a23eb6b1614318a8071c9b2521f36b424b2c83db5eb3a0fead4a6c0809af6e61" +checksum = "2a4385e2e34eb35d6b3efe798b9eb88096925d87726c0798709bf56d9ed84af3" + +[[package]] +name = "ar_archive_writer" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4087686b4b0a3427190bae57a1d9a478dbb2d40c5dc1bd6e2b6d797913bdd348" +dependencies = [ + "object", +] [[package]] name = "arbitrary" @@ -125,9 +134,18 @@ dependencies = [ [[package]] name = "arrayvec" -version = "0.7.6" +version = "0.7.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3fb67a6e08acf24fdeccbac2cb6ac4305825bd1f117462e0e6f2f193345ad56" + +[[package]] +name = "as-slice" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c02d123df017efcdfbd739ef81735b36c5ba83ec3c59c80a9d7ecc718f92e50" +checksum = "516b6b4f0e40d50dcda9365d53964ec74560ad4284da2e7fc97122cd83174516" +dependencies = [ + "stable_deref_trait", +] [[package]] name = "ash" @@ -169,9 +187,9 @@ dependencies = [ [[package]] name = "async-executor" -version = "1.13.3" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "497c00e0fd83a72a79a39fcbd8e3e2f055d6f6c7e025f3b3d91f4f8e76527fb8" +checksum = "c96bf972d85afc50bf5ab8fe2d54d1586b4e0b46c97c50a0c9e71e2f7bcd812a" dependencies = [ "async-task", "concurrent-queue", @@ -212,53 +230,58 @@ dependencies = [ [[package]] name = "autocfg" -version = "1.5.0" +version = "1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c08606f8c3cbf4ce6ec8e28fb0014a2c086708fe954eaa885384a6165172e7e8" +checksum = "f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53" [[package]] -name = "av1-grain" -version = "0.2.4" +name = "av-scenechange" +version = "0.14.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f3efb2ca85bc610acfa917b5aaa36f3fcbebed5b3182d7f877b02531c4b80c8" +checksum = "0f321d77c20e19b92c39e7471cf986812cbb46659d2af674adc4331ef3f18394" dependencies = [ + "aligned", "anyhow", + "arg_enum_proc_macro", "arrayvec", "log", - "nom", "num-rational", + "num-traits", + "pastey", + "rayon", + "thiserror 2.0.18", "v_frame", + "y4m", ] [[package]] -name = "avif-serialize" -version = "0.8.6" +name = "av1-grain" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "47c8fbc0f831f4519fe8b810b6a7a91410ec83031b8233f730a0480029f6a23f" +checksum = "8cfddb07216410377231960af4fcab838eaa12e013417781b78bd95ee22077f8" dependencies = [ + "anyhow", "arrayvec", + "log", + "nom 8.0.0", + "num-rational", + "v_frame", ] [[package]] -name = "backtrace" -version = "0.3.76" +name = "avif-serialize" +version = "0.8.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb531853791a215d7c62a30daf0dde835f381ab5de4589cfe7c649d2cbe92bd6" +checksum = "e7178fe5f7d460b13895ebb9dcb28a3a6216d2df2574a0806cb51b555d297f38" dependencies = [ - "addr2line", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", - "windows-link", + "arrayvec", ] [[package]] name = "bevy_ecs" -version = "0.17.2" +version = "0.17.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69d929d32190cfcde6efd2df493601c4dbc18a691fd9775a544c951c3c112e1a" +checksum = "a7dd5229dd00d00e70ac6b2fc0a139961252f6ce07d3d268cfcac0da86d5bde4" dependencies = [ "arrayvec", "bevy_ecs_macros", @@ -267,7 +290,7 @@ dependencies = [ "bevy_reflect", "bevy_tasks", "bevy_utils", - "bitflags 2.9.4", + "bitflags 2.13.1", "bumpalo", "concurrent-queue", "derive_more", @@ -278,15 +301,15 @@ dependencies = [ "serde", "slotmap", "smallvec", - "thiserror 2.0.17", + "thiserror 2.0.18", "variadics_please", ] [[package]] name = "bevy_ecs_macros" -version = "0.17.2" +version = "0.17.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6eeddfb80a2e000663e87be9229c26b4da92bddbc06c8776bc0d1f4a7f679079" +checksum = "c4d83bdd2285af4867e76c691406e0a4b55611b583d0c45b6ac7bcec1b45fd48" dependencies = [ "bevy_macro_utils", "proc-macro2", @@ -296,27 +319,27 @@ dependencies = [ [[package]] name = "bevy_macro_utils" -version = "0.17.2" +version = "0.17.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17dbc3f8948da58b3c17767d20fd3cd35fe4721ed19a9a3204a6f1d6c9951bdd" +checksum = "62d984f9f8bd0f0d9fb020492a955e641e30e7a425f3588bf346cb3e61fec3c3" dependencies = [ "parking_lot", "proc-macro2", "quote", "syn", - "toml_edit 0.23.6", + "toml_edit 0.23.10+spec-1.0.0", ] [[package]] name = "bevy_platform" -version = "0.17.2" +version = "0.17.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10cf8cda162688c95250e74cffaa1c3a04597f105d4ca35554106f107308ea57" +checksum = "4691af6d7cfd1b5deb2fc926a43a180a546cdc3fe1e5a013fcee60db9bb2c81f" dependencies = [ "critical-section", "foldhash 0.2.0", "futures-channel", - "hashbrown 0.16.0", + "hashbrown 0.16.1", "js-sys", "portable-atomic", "portable-atomic-util", @@ -328,15 +351,15 @@ dependencies = [ [[package]] name = "bevy_ptr" -version = "0.17.2" +version = "0.17.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28ab4074e7b781bab84e9b0a41ede245d673d1f75646ce0db27643aedcfb3a85" +checksum = "17d24d7906c7de556033168b3485de36c59049fbaef0c2c44c715a23e0329b10" [[package]] name = "bevy_reflect" -version = "0.17.2" +version = "0.17.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "333df3f5947b7e62728eb5c0b51d679716b16c7c5283118fed4563f13230954e" +checksum = "b5472b91928c0f3e4e3988c0d036b00719f19520f53a0c3f8c2af72f00e693c5" dependencies = [ "assert_type_match", "bevy_platform", @@ -352,7 +375,7 @@ dependencies = [ "serde", "smallvec", "smol_str", - "thiserror 2.0.17", + "thiserror 2.0.18", "uuid", "variadics_please", "wgpu-types 26.0.0", @@ -360,9 +383,9 @@ dependencies = [ [[package]] name = "bevy_reflect_derive" -version = "0.17.2" +version = "0.17.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0205dce9c5a4d8d041b263bcfd96e9d9d6f3d49416e12db347ab5778b3071fe1" +checksum = "083784255162fa39960aa3cf3c23af0e515db2daa7f2e796ae34df993f4d3f6c" dependencies = [ "bevy_macro_utils", "indexmap", @@ -374,9 +397,9 @@ dependencies = [ [[package]] name = "bevy_tasks" -version = "0.17.2" +version = "0.17.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18839182775f30d26f0f84d9de85d25361bb593c99517a80b64ede6cbaf41adc" +checksum = "bcbbfa5a58a16c4228434d3018c23fde3d78dcd76ec5f5b2b482a21f4b158dd3" dependencies = [ "async-channel", "async-executor", @@ -392,9 +415,9 @@ dependencies = [ [[package]] name = "bevy_utils" -version = "0.17.2" +version = "0.17.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "080254083c74d5f6eb0649d7cd6181bda277e8fe3c509ec68990a5d56ec23f24" +checksum = "789d04f88c764877a4552e07745b402dbc45f5d0545e6d102558f2f1752a1d89" dependencies = [ "bevy_platform", "disqualified", @@ -427,15 +450,15 @@ version = "0.72.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "993776b509cfb49c750f11b8f07a46fa23e0a1386ffc01fb1e7d343efc387895" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", "cexpr", "clang-sys", "itertools 0.13.0", "proc-macro2", "quote", "regex", - "rustc-hash 2.1.2", - "shlex", + "rustc-hash 2.1.3", + "shlex 1.3.0", "syn", ] @@ -468,18 +491,21 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.9.4" +version = "2.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2261d10cca569e4643e526d8dc2e62e433cc8aba21ab764233731f8d369bf394" +checksum = "b588b76d00fde79687d7646a9b5bdf3cc0f655e0bbd080335a95d7e96f3587da" dependencies = [ - "serde", + "serde_core", ] [[package]] name = "bitstream-io" -version = "2.6.0" +version = "4.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6099cdc01846bc367c4e7dd630dc5966dccf36b652fae7a74e17b640411a91b2" +checksum = "7eff00be299a18769011411c9def0d827e8f2d7bf0c3dbf53633147a8867fd1f" +dependencies = [ + "no_std_io2", +] [[package]] name = "block" @@ -495,30 +521,30 @@ checksum = "455335846aa0221f9e58c538fc20985e50d64241154a6fb5739267c0d776f784" [[package]] name = "built" -version = "0.7.7" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56ed6191a7e78c36abdb16ab65341eefd73d64d303fffccdbb00d51e4205967b" +checksum = "5c0e531d93d39c34eef561e929e8a7f86d77a5af08aac4f6d6e39976c51858e9" [[package]] name = "bumpalo" -version = "3.19.0" +version = "3.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46c5e41b57b8bba42a04676d81cb89e9ee8e859a1a66f80a5a72e1cb76b34d43" +checksum = "72f5acc6cb2ba439de613abc23857ec3d78374d8ed5ac84e9d11336e87da8649" [[package]] name = "bytemuck" -version = "1.24.0" +version = "1.25.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fbdf580320f38b612e485521afda1ee26d10cc9884efaaa750d383e13e3c5f4" +checksum = "d6aedf8ae72766347502cf3cb4f41cf5e9cc37d28bee90f1fdaaae15f9cf9424" dependencies = [ "bytemuck_derive", ] [[package]] name = "bytemuck_derive" -version = "1.10.2" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9abbd1bc6865053c427f7198e6af43bfdedc55ab791faed4fbd361d789575ff" +checksum = "f65693059b6b9c588b9f62fed1cedbf0a8b805631457ea162d68f0de186f3de5" dependencies = [ "proc-macro2", "quote", @@ -539,20 +565,20 @@ checksum = "8f1fe948ff07f4bd06c30984e69f5b4899c516a3ef74f34df92a2df2ab535495" [[package]] name = "bytes" -version = "1.10.1" +version = "1.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d71b6127be86fdcfddb610f7182ac57211d4b18a3e9c82eb2d17662f2227ad6a" +checksum = "fc652a48c352aef3ea3aed32080501cf3ef6ed5da78602a020c991775b0aff04" [[package]] name = "cc" -version = "1.2.60" +version = "1.2.67" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43c5703da9466b66a946814e1adf53ea2c90f10063b86290cc9eb67ce3478a20" +checksum = "e17dd265a7d0f31ef544e1b20e03add05d3b45b491b633b10d67145d2acc1a38" dependencies = [ "find-msvc-tools", "jobserver", "libc", - "shlex", + "shlex 2.0.1", ] [[package]] @@ -561,30 +587,20 @@ version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6fac387a98bb7c37292057cffc56d62ecb629900026402633ae9160df93a8766" dependencies = [ - "nom", -] - -[[package]] -name = "cfg-expr" -version = "0.15.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d067ad48b8650848b989a59a86c6c36a995d02d2bf778d45c3c5d57bc2718f02" -dependencies = [ - "smallvec", - "target-lexicon", + "nom 7.1.3", ] [[package]] name = "cfg-if" -version = "1.0.3" +version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fd1289c04a9ea8cb22300a459a72a385d7c73d3259e2ed7dcb2af674838cfa9" +checksum = "9330f8b2ff13f34540b44e946ef35111825727b38d33286ef986142615121801" [[package]] name = "cfg_aliases" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "613afe47fcd5fac7ccf1db93babcb082c5994d996f20b8b159f2ad1658eb5724" +checksum = "f079e83a288787bcd14a6aea84cee5c87a67c5a3e660c30f557a3d24761b3527" [[package]] name = "chumsky" @@ -613,9 +629,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.48" +version = "4.6.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2134bb3ea021b78629caa971416385309e0131b351b25e01dc16fb54e1b5fae" +checksum = "dd059f9da4f5c36b3787f65d38ccaab1cc315f07b01f89abc8359ee6a8205011" dependencies = [ "clap_builder", "clap_derive", @@ -623,9 +639,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.48" +version = "4.6.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2ba64afa3c0a6df7fa517765e31314e983f51dda798ffba27b988194fb65dc9" +checksum = "f09628afdcc538b57f3c6341e9c8e9970f18e4a481690a64974d7023bd33548b" dependencies = [ "anstream", "anstyle", @@ -635,9 +651,9 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.5.47" +version = "4.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbfd7eae0b0f1a6e63d4b13c9c478de77c2eb546fba158ad50b4203dc24b9f9c" +checksum = "f2ce8604710f6733aa641a2b3731eaa1e8b3d9973d5e3565da11800813f997a9" dependencies = [ "heck", "proc-macro2", @@ -647,9 +663,9 @@ dependencies = [ [[package]] name = "clap_lex" -version = "0.7.5" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b94f61472cee1439c0b966b47e3aca9ae07e45d070759512cd390ea2bebc6675" +checksum = "c8d4a3bb8b1e0c1050499d1815f5ab16d04f0959b233085fb31653fbfc9d98f9" [[package]] name = "cmake" @@ -705,9 +721,9 @@ checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b" [[package]] name = "colorchoice" -version = "1.0.4" +version = "1.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b05b61dc5112cbb17e4b6cd61790d9845d13888356391624cbe7e41efeac1e75" +checksum = "1d07550c9036bf2ae0c684c4297d503f838287c83c53686d05370d0e139ae570" [[package]] name = "concurrent-queue" @@ -721,18 +737,18 @@ dependencies = [ [[package]] name = "convert_case" -version = "0.7.1" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb402b8d4c85569410425650ce3eddc7d698ed96d39a73f941b08fb63082f1e7" +checksum = "baaaa0ecca5b51987b9423ccdc971514dd8b0bb7b4060b983d3664dad3f1f89f" dependencies = [ "unicode-segmentation", ] [[package]] name = "convert_case" -version = "0.8.0" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baaaa0ecca5b51987b9423ccdc971514dd8b0bb7b4060b983d3664dad3f1f89f" +checksum = "633458d4ef8c78b72454de2d54fd6ab2e60f9e02be22f3c6104cdc8a4e0fceb9" dependencies = [ "unicode-segmentation", ] @@ -759,7 +775,7 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3d44a101f213f6c4cdc1853d4b78aef6db6bdfa3468798cc1d9912f4735013eb" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", "core-foundation", "libc", ] @@ -794,18 +810,18 @@ dependencies = [ [[package]] name = "crossbeam-channel" -version = "0.5.15" +version = "0.5.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82b8f8f868b36967f9606790d1903570de9ceaf870a7bf9fbbd3016d636a2cb2" +checksum = "d85363c37faeca707aef026efa9f3b34d077bce547e48f770770625c6013679e" dependencies = [ "crossbeam-utils", ] [[package]] name = "crossbeam-deque" -version = "0.8.6" +version = "0.8.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9dd111b7b7f7d55b72c0a6ae361660ee5853c9af73f70c3c2ef6858b950e2e51" +checksum = "5181e0de7b61eb03a81e347d6dd8797bae9da5146707b51077e2d71a54ec0ceb" dependencies = [ "crossbeam-epoch", "crossbeam-utils", @@ -813,27 +829,27 @@ dependencies = [ [[package]] name = "crossbeam-epoch" -version = "0.9.18" +version = "0.9.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" +checksum = "2d6914041f254d6e9176c01941b21115dcfb7089e55135a35411081bd106ef3f" dependencies = [ "crossbeam-utils", ] [[package]] name = "crossbeam-queue" -version = "0.3.12" +version = "0.3.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f58bbc28f91df819d0aa2a2c00cd19754769c2fad90579b3592b1c9ba7a3115" +checksum = "803d13fb3b09d88be9f4dbc29062c66b19bf7170867ceb746d2a8689bf6c7a26" dependencies = [ "crossbeam-utils", ] [[package]] name = "crossbeam-utils" -version = "0.8.21" +version = "0.8.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0a5c400df2834b80a4c3327b3aad3a4c4cd4de0629063962b03235697506a28" +checksum = "61803da095bee82a81bb1a452ecc25d3b2f1416d1897eb86430c6159ef717c17" [[package]] name = "crunchy" @@ -863,22 +879,23 @@ dependencies = [ [[package]] name = "derive_more" -version = "2.0.1" +version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "093242cf7570c207c83073cf82f79706fe7b8317e98620a47d5be7c3d8497678" +checksum = "d751e9e49156b02b44f9c1815bcb94b984cdcc4396ecc32521c739452808b134" dependencies = [ "derive_more-impl", ] [[package]] name = "derive_more-impl" -version = "2.0.1" +version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bda628edc44c4bb645fbe0f758797143e4e07926f7ebf4e9bdfbd3d2ce621df3" +checksum = "799a97264921d8623a957f6c3b9011f3b5492f557bbb7a5a19b7fa6d06ba8dcb" dependencies = [ - "convert_case 0.7.1", + "convert_case 0.10.0", "proc-macro2", "quote", + "rustc_version", "syn", "unicode-xid", ] @@ -891,9 +908,9 @@ checksum = "c9c272297e804878a2a4b707cfcfc6d2328b5bb936944613b4fdf2b9269afdfd" [[package]] name = "document-features" -version = "0.2.11" +version = "0.2.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95249b50c6c185bee49034bcb378a49dc2b5dff0be90ff6616d31d64febab05d" +checksum = "d4b8a88685455ed29a21542a33abd9cb6510b6b129abadabdcef0f4c55bc8f61" dependencies = [ "litrs", ] @@ -915,9 +932,9 @@ dependencies = [ [[package]] name = "either" -version = "1.15.0" +version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48c757948c5ede0e46177b7add2e67155f70e33c07fea8284df6576da70b3719" +checksum = "91622ff5e7162018101f2fea40d6ebf4a78bbe5a49736a2020649edf9693679e" [[package]] name = "env_logger" @@ -938,7 +955,7 @@ version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4cd405aab171cb85d6735e5c8d9db038c17d3ca007a4d2c25f337935c3d90580" dependencies = [ - "humantime 2.3.0", + "humantime 2.4.0", "is-terminal", "log", "regex", @@ -973,9 +990,9 @@ checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "erased-serde" -version = "0.4.8" +version = "0.4.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "259d404d09818dec19332e31d94558aeb442fea04c817006456c24b5460bbd4b" +checksum = "d2add8a07dd6a8d93ff627029c51de145e12686fbc36ecb298ac22e74cf02dec" dependencies = [ "serde", "serde_core", @@ -1014,14 +1031,16 @@ dependencies = [ [[package]] name = "exr" -version = "1.73.0" +version = "1.74.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f83197f59927b46c04a183a619b7c29df34e63e63c7869320862268c0ef687e0" +checksum = "711fe42c9964295e01ee3fba3f9fe0e1d24b98886950d68efe81b1c76e21adf3" dependencies = [ "bit_field", "half", "lebe", "miniz_oxide", + "num-complex", + "pulp", "rayon-core", "smallvec", "zune-inflate", @@ -1032,14 +1051,14 @@ name = "extractor" version = "0.0.13" dependencies = [ "anyhow", - "bitflags 2.9.4", + "bitflags 2.13.1", "clap", "dxt", "image", "lz4", "png 0.17.16", "safe-transmute", - "thiserror 2.0.17", + "thiserror 2.0.18", "tracing", "transmute-extra", ] @@ -1057,29 +1076,15 @@ dependencies = [ [[package]] name = "fastrand" -version = "2.3.0" +version = "2.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be" +checksum = "9f1f227452a390804cdb637b74a86990f2a7d7ba4b7d5693aac9b4dd6defd8d6" [[package]] name = "fax" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f05de7d48f37cd6730705cbca900770cab77a89f413d23e100ad7fad7795a0ab" -dependencies = [ - "fax_derive", -] - -[[package]] -name = "fax_derive" -version = "0.2.0" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a0aca10fb742cb43f9e7bb8467c91aa9bcb8e3ffbc6a6f7389bb93ffc920577d" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] +checksum = "caf1079563223d5d59d83c85886a56e586cfd5c1a26292e971a0fa266531ac5a" [[package]] name = "fdeflate" @@ -1124,9 +1129,9 @@ checksum = "1d674e81391d1e1ab681a28d99df07927c6d4aa5b027d7da16ba32d1d21ecd99" [[package]] name = "flate2" -version = "1.1.4" +version = "1.1.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc5a4e564e38c699f2880d3fda590bedc2e69f3f84cd48b457bd892ce61d0aa9" +checksum = "843fba2746e448b37e26a819579957415c8cef339bf08564fe8b7ddbd959573c" dependencies = [ "crc32fast", "miniz_oxide", @@ -1179,24 +1184,24 @@ checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b" [[package]] name = "futures-channel" -version = "0.3.31" +version = "0.3.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dff15bf788c671c1934e366d07e30c1814a8ef514e1af724a602e8a2fbe1b10" +checksum = "07bbe89c50d7a535e539b8c17bc0b49bdb77747034daa8087407d655f3f7cc1d" dependencies = [ "futures-core", ] [[package]] name = "futures-core" -version = "0.3.31" +version = "0.3.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05f29059c0c2090612e8d742178b0580d2dc940c837851ad723096f87af6663e" +checksum = "7e3450815272ef58cec6d564423f6e755e25379b217b0bc688e295ba24df6b1d" [[package]] name = "futures-io" -version = "0.3.31" +version = "0.3.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e5c1b78ca4aae1ac06c48a526a655760685149f0d465d21f37abfe57ce075c6" +checksum = "cecba35d7ad927e23624b22ad55235f2239cfa44fd10428eecbeba6d6a717718" [[package]] name = "futures-lite" @@ -1213,9 +1218,9 @@ dependencies = [ [[package]] name = "futures-macro" -version = "0.3.31" +version = "0.3.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650" +checksum = "e835b70203e41293343137df5c0664546da5745f82ec9b84d40be8336958447b" dependencies = [ "proc-macro2", "quote", @@ -1224,21 +1229,20 @@ dependencies = [ [[package]] name = "futures-task" -version = "0.3.31" +version = "0.3.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f90f7dce0722e95104fcb095585910c0977252f286e354b5e3bd38902cd99988" +checksum = "037711b3d59c33004d3856fbdc83b99d4ff37a24768fa1be9ce3538a1cde4393" [[package]] name = "futures-util" -version = "0.3.31" +version = "0.3.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fa08315bb612088cc391249efdc3bc77536f16c91f6cf495e6fbe85b20a4a81" +checksum = "389ca41296e6190b48053de0321d02a77f32f8a5d2461dd38762c0593805c6d6" dependencies = [ "futures-core", "futures-macro", "futures-task", "pin-project-lite", - "pin-utils", "slab", ] @@ -1253,43 +1257,37 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.16" +version = "0.3.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "335ff9f135e4384c8150d6f27c6daed433577f86b4750418338c01a1a2528592" +checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd" dependencies = [ "cfg-if", "libc", - "wasi 0.11.1+wasi-snapshot-preview1", + "r-efi 5.3.0", + "wasip2", ] [[package]] name = "getrandom" -version = "0.3.3" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26145e563e54f2cadc477553f1ec5ee650b00862f0a58bcd12cbdc5f0ea2d2f4" +checksum = "300e883d756b2e4ec94e02791f39b04b522276138852cfc41d9fb7e904106099" dependencies = [ "cfg-if", "libc", - "r-efi", - "wasi 0.14.7+wasi-0.2.4", + "r-efi 6.0.0", ] [[package]] name = "gif" -version = "0.13.3" +version = "0.14.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ae047235e33e2829703574b54fdec96bfbad892062d97fed2f76022287de61b" +checksum = "ee8cfcc411d9adbbaba82fb72661cc1bcca13e8bba98b364e62b2dba8f960159" dependencies = [ "color_quant", "weezl", ] -[[package]] -name = "gimli" -version = "0.32.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e629b9b98ef3dd8afe6ca2bd0f89306cec16d43d907889945bc5d6687f2f13c7" - [[package]] name = "gl_generator" version = "0.14.0" @@ -1303,9 +1301,9 @@ dependencies = [ [[package]] name = "glam" -version = "0.30.8" +version = "0.30.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e12d847aeb25f41be4c0ec9587d624e9cd631bc007a8fd7ce3f5851e064c6460" +checksum = "19fc433e8437a212d1b6f1e68c7824af3aed907da60afa994e7f542d18d12aa9" dependencies = [ "bytemuck", "serde_core", @@ -1340,21 +1338,21 @@ dependencies = [ [[package]] name = "gpu-alloc" -version = "0.6.0" +version = "0.6.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbcd2dba93594b227a1f57ee09b8b9da8892c34d55aa332e034a228d0fe6a171" +checksum = "45cf04b2726f02df5508c6de726acdc90cdf97ac771a9a0ffd8ba10a6e696bf9" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", "gpu-alloc-types", ] [[package]] name = "gpu-alloc-types" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98ff03b468aa837d70984d55f5d3f846f6ec31fe34bbb97c4f85219caeee1ca4" +checksum = "b2bbed164dd10ed526c2e4fe3e721ca4a71c61730e5aafac6844b417b3227058" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", ] [[package]] @@ -1375,7 +1373,7 @@ version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b89c83349105e3732062a895becfc71a8f921bb71ecbbdd8ff99263e3b53a0ca" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", "gpu-descriptor-types", "hashbrown 0.15.5", ] @@ -1386,18 +1384,19 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fdf242682df893b86f33a73828fb09ca4b2d3bb6cc95249707fc684d27484b91" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", ] [[package]] name = "half" -version = "2.6.0" +version = "2.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "459196ed295495a68f7d7fe1d84f6c4b7ff0e21fe3017b2f283c6fac3ad803c9" +checksum = "6ea2d84b969582b4b1864a92dc5d27cd2b77b622a8d79306834f1be5ba20d84b" dependencies = [ "cfg-if", "crunchy", "num-traits", + "zerocopy", ] [[package]] @@ -1422,15 +1421,22 @@ dependencies = [ [[package]] name = "hashbrown" -version = "0.16.0" +version = "0.16.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5419bdc4f6a9207fbeba6d11b604d481addf78ecd10c11ad51e76c2f6482748d" +checksum = "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100" dependencies = [ "equivalent", "foldhash 0.2.0", "serde", + "serde_core", ] +[[package]] +name = "hashbrown" +version = "0.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a" + [[package]] name = "heapless" version = "0.8.0" @@ -1486,15 +1492,15 @@ dependencies = [ [[package]] name = "humantime" -version = "2.3.0" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "135b12329e5e3ce057a9f972339ea52bc954fe1e9358ef27f95e89716fbc5424" +checksum = "15cdd26707701c53297e2fa6afb323d55fbc1d0810c3aec078ae3ef0424c3c15" [[package]] name = "image" -version = "0.25.8" +version = "0.25.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "529feb3e6769d234375c4cf1ee2ce713682b8e76538cb13f9fc23e1400a591e7" +checksum = "85ab80394333c02fe689eaf900ab500fbd0c2213da414687ebf995a65d5a6104" dependencies = [ "bytemuck", "byteorder-lite", @@ -1504,7 +1510,7 @@ dependencies = [ "image-webp", "moxcms", "num-traits", - "png 0.18.0", + "png 0.18.1", "qoi", "ravif", "rayon", @@ -1526,18 +1532,18 @@ dependencies = [ [[package]] name = "imgref" -version = "1.12.0" +version = "1.12.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7c5cedc30da3a610cac6b4ba17597bdf7152cf974e8aab3afb3d54455e371c8" +checksum = "89194689a993ab15268672e99e7b0e19da2da3268ac682e8f02d29d4d1434cd7" [[package]] name = "indexmap" -version = "2.11.4" +version = "2.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b0f83760fb341a774ed326568e19f5a863af4a952def8c39f9ab92fd95b88e5" +checksum = "d466e9454f08e4a911e14806c24e16fba1b4c121d1ea474396f396069cf949d9" dependencies = [ "equivalent", - "hashbrown 0.16.0", + "hashbrown 0.17.1", ] [[package]] @@ -1551,33 +1557,22 @@ dependencies = [ "syn", ] -[[package]] -name = "io-uring" -version = "0.7.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "046fa2d4d00aea763528b4950358d0ead425372445dc8ff86312b3c69ff7727b" -dependencies = [ - "bitflags 2.9.4", - "cfg-if", - "libc", -] - [[package]] name = "is-terminal" -version = "0.4.16" +version = "0.4.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e04d7f318608d35d4b61ddd75cbdaee86b023ebe2bd5a66ee0915f0bf93095a9" +checksum = "3640c1c38b8e4e43584d8df18be5fc6b0aa314ce6ebf51b53313d4306cca8e46" dependencies = [ "hermit-abi 0.5.2", "libc", - "windows-sys 0.59.0", + "windows-sys 0.61.2", ] [[package]] name = "is_terminal_polyfill" -version = "1.70.1" +version = "1.70.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf" +checksum = "a6cb138bb79a146c1bd460005623e142ef0181e3d0219cb493e02f7d08a35695" [[package]] name = "itertools" @@ -1588,15 +1583,6 @@ dependencies = [ "either", ] -[[package]] -name = "itertools" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" -dependencies = [ - "either", -] - [[package]] name = "itertools" version = "0.13.0" @@ -1617,33 +1603,56 @@ dependencies = [ [[package]] name = "itoa" -version = "1.0.15" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4a5f13b858c8d314ee3e8f639011f7ccefe71f97f96e50151fb991f267928e2c" +checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682" [[package]] name = "jni-sys" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaf4bc02d17cbdd7ff4c7438cafcdf7fb9a4613313ad11b4f8fefe7d3fa0130" +checksum = "41a652e1f9b6e0275df1f15b32661cf0d4b78d4d87ddec5e0c3c20f097433258" +dependencies = [ + "jni-sys 0.4.1", +] + +[[package]] +name = "jni-sys" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6377a88cb3910bee9b0fa88d4f42e1d2da8e79915598f65fb0c7ee14c878af2" +dependencies = [ + "jni-sys-macros", +] + +[[package]] +name = "jni-sys-macros" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38c0b942f458fe50cdac086d2f946512305e5631e720728f2a61aabcd47a6264" +dependencies = [ + "quote", + "syn", +] [[package]] name = "jobserver" -version = "0.1.34" +version = "0.1.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9afb3de4395d6b3e67a780b6de64b51c978ecf11cb9a462c66be7d4ca9039d33" +checksum = "1c00acbd29eabad4a2392fa0e921c874934dbbf4194312ad20f04a0ed67a3cb3" dependencies = [ - "getrandom 0.3.3", + "getrandom 0.4.3", "libc", ] [[package]] name = "js-sys" -version = "0.3.81" +version = "0.3.103" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec48937a97411dcb524a265206ccd4c90bb711fca92b2792c407f268825b9305" +checksum = "53b44bfcdb3f8d5837a46dae1ca9660a837176eee74a28b229bc626816589102" dependencies = [ - "once_cell", + "cfg-if", + "futures-util", "wasm-bindgen", ] @@ -1666,9 +1675,9 @@ checksum = "e2db585e1d738fc771bf08a151420d3ed193d9d895a36df7f6f8a9456b911ddc" [[package]] name = "lazy-regex" -version = "3.4.1" +version = "3.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60c7310b93682b36b98fa7ea4de998d3463ccbebd94d935d6b48ba5b6ffa7126" +checksum = "6bae91019476d3ec7147de9aa291cadb6d870abf2f3015d2da73a90325ac1496" dependencies = [ "lazy-regex-proc_macros", "once_cell", @@ -1677,9 +1686,9 @@ dependencies = [ [[package]] name = "lazy-regex-proc_macros" -version = "3.4.1" +version = "3.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ba01db5ef81e17eb10a5e0f2109d1b3a3e29bac3070fdbd7d156bf7dbd206a1" +checksum = "4de9c1e1439d8b7b3061b2d209809f447ca33241733d9a3c01eabf2dc8d94358" dependencies = [ "proc-macro2", "quote", @@ -1701,15 +1710,15 @@ checksum = "7a79a3332a6609480d7d0c9eab957bca6b455b91bb84e66d19f5ff66294b85b8" [[package]] name = "libc" -version = "0.2.176" +version = "0.2.186" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58f929b4d672ea937a23a1ab494143d968337a5f47e56d0815df1e0890ddf174" +checksum = "68ab91017fe16c622486840e4c83c9a37afeff978bd239b5293d61ece587de66" [[package]] name = "libfuzzer-sys" -version = "0.4.10" +version = "0.4.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5037190e1f70cbeef565bd267599242926f724d3b8a9f510fd7e0b540cfa4404" +checksum = "a9fd2f41a1cba099f79a0b6b6c35656cf7c03351a7bae8ff0f28f25270f929d2" dependencies = [ "arbitrary", "cc", @@ -1727,9 +1736,9 @@ dependencies = [ [[package]] name = "libm" -version = "0.2.15" +version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9fbbcab51052fe104eb5e5d351cf728d30a5be1fe14d9be8a3b097481fb97de" +checksum = "b6d2cec3eae94f9f509c767b45932f1ada8350c4bdb85af2fcab4a3c14807981" [[package]] name = "link-cplusplus" @@ -1748,9 +1757,9 @@ checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab" [[package]] name = "litrs" -version = "0.4.2" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5e54036fe321fd421e10d732f155734c4e4afd610dd556d9a82833ab3ee0bed" +checksum = "11d3d7f243d5c5a8b9bb5d6dd2b1602c0cb0b9db1621bafc7ed66e35ff9fe092" [[package]] name = "lock_api" @@ -1763,9 +1772,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.28" +version = "0.4.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34080505efa8e45a4b816c349525ebe327ceaa8559756f0356cba97ef3bf7432" +checksum = "0ceec5bc11778974d1bcb055b18002eba7f4b3518b6a0081b3af5f21666da9ad" [[package]] name = "loop9" @@ -1810,7 +1819,7 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d1525a2a28c7f4fa0fc98bb91ae755d1e2d1505079e05539e35bc876b5d65ae9" dependencies = [ - "regex-automata 0.4.11", + "regex-automata 0.4.16", ] [[package]] @@ -1825,9 +1834,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.7.6" +version = "2.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f52b00d39961fc5b2736ea853c9cc86238e165017a493d1d5c8eac6bdc4cc273" +checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98" [[package]] name = "metal" @@ -1835,7 +1844,7 @@ version = "0.32.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "00c15a6f673ff72ddcc22394663290f870fb224c1bfce55734a75c414150e605" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", "block", "core-graphics-types", "foreign-types", @@ -1862,20 +1871,20 @@ dependencies = [ [[package]] name = "mio" -version = "1.0.4" +version = "1.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78bed444cc8a2160f01cbcf811ef18cac863ad68ae8ca62092e8db51d51c761c" +checksum = "30d65c71f1ce40ab09135ce117d742b9f8a19ff91a41a8b57ed50bc2de59c427" dependencies = [ "libc", - "wasi 0.11.1+wasi-snapshot-preview1", - "windows-sys 0.59.0", + "wasi", + "windows-sys 0.61.2", ] [[package]] name = "moxcms" -version = "0.7.6" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cc7d85f3d741164e8972ad355e26ac6e51b20fcae5f911c7da8f2d8bbbb3f33" +checksum = "bb85c154ba489f01b25c0d36ae69a87e4a1c73a72631fc6c0eb6dde34a73e44b" dependencies = [ "num-traits", "pxfm", @@ -1883,18 +1892,18 @@ dependencies = [ [[package]] name = "naga" -version = "27.0.0" +version = "27.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12b2e757b11b47345d44e7760e45458339bc490463d9548cd8651c53ae523153" +checksum = "066cf25f0e8b11ee0df221219010f213ad429855f57c494f995590c861a9a7d8" dependencies = [ "arrayvec", "bit-set", - "bitflags 2.9.4", + "bitflags 2.13.1", "cfg-if", "cfg_aliases", "codespan-reporting", "half", - "hashbrown 0.16.0", + "hashbrown 0.16.1", "hexf-parse", "indexmap", "libm", @@ -1905,7 +1914,7 @@ dependencies = [ "pp-rs", "rustc-hash 1.1.0", "spirv", - "thiserror 2.0.17", + "thiserror 2.0.18", "unicode-ident", ] @@ -1915,7 +1924,7 @@ version = "0.6.0+11769913" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ee6cda3051665f1fb8d9e08fc35c96d5a244fb1be711a03b71118828afc9a873" dependencies = [ - "jni-sys", + "jni-sys 0.3.1", ] [[package]] @@ -1924,6 +1933,15 @@ version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "650eef8c711430f1a879fdd01d4745a7deea475becfb90269c06775983bbf086" +[[package]] +name = "no_std_io2" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "418abd1b6d34fbf6cae440dc874771b0525a604428704c76e48b29a5e67b8003" +dependencies = [ + "memchr", +] + [[package]] name = "nom" version = "7.1.3" @@ -1934,6 +1952,15 @@ dependencies = [ "minimal-lexical", ] +[[package]] +name = "nom" +version = "8.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "df9761775871bdef83bee530e60050f7e54b1105350d6884eb0fb4f46c2f9405" +dependencies = [ + "memchr", +] + [[package]] name = "nonmax" version = "0.5.5" @@ -1948,23 +1975,33 @@ checksum = "0676bb32a98c1a483ce53e500a81ad9c3d5b3f7c920c28c24e9cb0980d0b5bc8" [[package]] name = "nu-ansi-term" -version = "0.50.1" +version = "0.50.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4a28e057d01f97e61255210fcff094d74ed0466038633e95017f5beb68e4399" +checksum = "7957b9740744892f114936ab4a57b3f487491bbeafaf8083688b16841a4240e5" dependencies = [ - "windows-sys 0.52.0", + "windows-sys 0.61.2", ] [[package]] name = "num-bigint" -version = "0.4.6" +version = "0.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" +checksum = "c89e69e7e0f03bea5ef08013795c25018e101932225a656383bd384495ecc367" dependencies = [ "num-integer", "num-traits", ] +[[package]] +name = "num-complex" +version = "0.4.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73f88a1307638156682bada9d7604135552957b7818057dcef22705b4d509495" +dependencies = [ + "bytemuck", + "num-traits", +] + [[package]] name = "num-derive" version = "0.4.2" @@ -2036,33 +2073,33 @@ dependencies = [ [[package]] name = "once_cell" -version = "1.21.3" +version = "1.21.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42f5e15c9953c5e4ccceeb2e7382a716482c34515315f7b03532b8b4e8393d2d" +checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50" [[package]] name = "once_cell_polyfill" -version = "1.70.1" +version = "1.70.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4895175b425cb1f87721b59f0f286c2092bd4af812243672510e1ac53e2e0ad" +checksum = "384b8ab6d37215f3c5301a95a4accb5d64aa607f1fcb26a11b5303878451b4fe" [[package]] name = "ordered-float" -version = "5.0.0" +version = "5.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2c1f9f56e534ac6a9b8a4600bdf0f530fb393b5f393e7b4d03489c3cf0c3f01" +checksum = "b7d950ca161dc355eaf28f82b11345ed76c6e1f6eb1f4f4479e0323b9e2fbd0e" dependencies = [ "num-traits", ] [[package]] name = "os_pipe" -version = "1.2.2" +version = "1.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db335f4760b14ead6290116f2427bf33a14d4f0617d49f78a246de10c1831224" +checksum = "7d8fae84b431384b68627d0f9b3b1245fcf9f46f6c0e3dc902e9dce64edd1967" dependencies = [ "libc", - "windows-sys 0.59.0", + "windows-sys 0.61.2", ] [[package]] @@ -2100,6 +2137,12 @@ version = "1.0.15" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" +[[package]] +name = "pastey" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35fb2e5f958ec131621fdd531e9fc186ed768cbe395337403ae56c17a74c68ec" + [[package]] name = "petgraph" version = "0.8.3" @@ -2128,7 +2171,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3c80231409c20246a13fddb31776fb942c38553c51e871f8cbd687a4cfb5843d" dependencies = [ "phf_shared", - "rand 0.8.5", + "rand 0.8.7", ] [[package]] @@ -2155,18 +2198,18 @@ dependencies = [ [[package]] name = "pin-project" -version = "1.1.10" +version = "1.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677f1add503faace112b9f1373e43e9e054bfdd22ff1a63c1bc485eaec6a6a8a" +checksum = "2466b2336ed02bcdca6b294417127b90ec92038d1d5c4fbeac971a922e0e0924" dependencies = [ "pin-project-internal", ] [[package]] name = "pin-project-internal" -version = "1.1.10" +version = "1.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e918e4ff8c4549eb882f14b3a4bc8c8bc93de829416eacf579f1207a8fbf861" +checksum = "c96395f0a926bc13b1c17622aaddda1ecb55d49c8f1bf9777e4d877800a43f8b" dependencies = [ "proc-macro2", "quote", @@ -2175,21 +2218,15 @@ dependencies = [ [[package]] name = "pin-project-lite" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b3cff922bd51709b605d9ead9aa71031d81447142d828eb4a6eba76fe619f9b" - -[[package]] -name = "pin-utils" -version = "0.1.0" +version = "0.2.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" +checksum = "a89322df9ebe1c1578d689c92318e070967d1042b512afbe49518723f4e6d5cd" [[package]] name = "pkg-config" -version = "0.3.32" +version = "0.3.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7edddbd0b52d732b21ad9a5fab5c704c14cd949e5e9a1ec5929a24fded1b904c" +checksum = "19f132c84eca552bf34cab8ec81f1c1dcc229b811638f9d283dceabe58c5569e" [[package]] name = "png" @@ -2206,11 +2243,11 @@ dependencies = [ [[package]] name = "png" -version = "0.18.0" +version = "0.18.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97baced388464909d42d89643fe4361939af9b7ce7a31ee32a168f832a70f2a0" +checksum = "60769b8b31b2a9f263dae2776c37b1b28ae246943cf719eb6946a1db05128a61" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", "crc32fast", "fdeflate", "flate2", @@ -2219,15 +2256,15 @@ dependencies = [ [[package]] name = "portable-atomic" -version = "1.11.1" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f84267b20a16ea918e43c6a88433c2d54fa145c92a811b5b047ccbe153674483" +checksum = "3d20d5497ef88037a52ff98267d066e7f11fcc5e99bbfbd58a42336193aacec3" [[package]] name = "portable-atomic-util" -version = "0.2.4" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8a2f0d8d040d7848a709caf78912debcc3f33ee4b3cac47d73d1e1069e83507" +checksum = "c2a106d1259c23fac8e543272398ae0e3c0b8d33c88ed73d0cc71b0f1d902618" dependencies = [ "portable-atomic", ] @@ -2290,27 +2327,27 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.101" +version = "1.0.106" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89ae43fd86e4158d6db51ad8e2b80f313af9cc74f5c0e03ccb87de09998732de" +checksum = "8fd00f0bb2e90d81d1044c2b32617f68fcb9fa3bb7640c23e9c748e53fb30934" dependencies = [ "unicode-ident", ] [[package]] name = "profiling" -version = "1.0.17" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3eb8486b569e12e2c32ad3e204dbaba5e4b5b216e9367044f25f1dba42341773" +checksum = "3d595e54a326bc53c1c197b32d295e14b169e3cfeaa8dc82b529f947fba6bcf5" dependencies = [ "profiling-procmacros", ] [[package]] name = "profiling-procmacros" -version = "1.0.17" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52717f9a02b6965224f95ca2a81e2e0c5c43baacd28ca057577988930b6c3d5b" +checksum = "4488a4a36b9a4ba6b9334a32a39971f77c1436ec82c38707bce707699cc3bbcb" dependencies = [ "quote", "syn", @@ -2321,27 +2358,48 @@ name = "project-parser" version = "0.0.13" dependencies = [ "chumsky", - "thiserror 2.0.17", + "thiserror 2.0.18", ] [[package]] name = "psm" -version = "0.1.27" +version = "0.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e66fcd288453b748497d8fb18bccc83a16b0518e3906d4b8df0a8d42d93dbb1c" +checksum = "645dbe486e346d9b5de3ef16ede18c26e6c70ad97418f4874b8b1889d6e761ea" dependencies = [ + "ar_archive_writer", "cc", ] [[package]] -name = "pxfm" -version = "0.1.24" +name = "pulp" +version = "0.22.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83f9b339b02259ada5c0f4a389b7fb472f933aa17ce176fd2ad98f28bb401fde" +checksum = "046aa45b989642ec2e4717c8e72d677b13edd831a4d3b6cf37d9a3e54912496a" dependencies = [ - "num-traits", + "bytemuck", + "cfg-if", + "libm", + "num-complex", + "paste", + "pulp-wasm-simd-flag", + "raw-cpuid", + "reborrow", + "version_check", ] +[[package]] +name = "pulp-wasm-simd-flag" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d8f70e07b9c3962945a74e59ca1c511bba65b6419468acc217c457d93f3c740" + +[[package]] +name = "pxfm" +version = "0.1.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d55d956fa96f5ec02be2e13af0e20391a5aa83d6a074e3ad368959d0fab299ea" + [[package]] name = "qoi" version = "0.4.1" @@ -2365,9 +2423,9 @@ checksum = "a993555f31e5a609f617c12db6250dedcac1b0a85076912c436e6fc9b2c8e6a3" [[package]] name = "quote" -version = "1.0.41" +version = "1.0.46" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce25767e7b499d1b604768e7cde645d14cc8584231ea6b295e9c9eb22c02e1d1" +checksum = "dfbc457d0c7a0759a614551b11a6409e5951f6c7537be1f1b7682b9ae9230368" dependencies = [ "proc-macro2", ] @@ -2379,34 +2437,28 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f" [[package]] -name = "rand" -version = "0.8.5" +name = "r-efi" +version = "6.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] +checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf" [[package]] name = "rand" -version = "0.9.2" +version = "0.8.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6db2770f06117d490610c7488547d543617b21bfa07796d7a12f6f1bd53850d1" +checksum = "22f6172bdec972074665ed81ed53b71da00bfc44b65a753cfde883ec4c702a1a" dependencies = [ - "rand_chacha 0.9.0", - "rand_core 0.9.3", + "rand_core 0.6.4", ] [[package]] -name = "rand_chacha" -version = "0.3.1" +name = "rand" +version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" +checksum = "b9ef1d0d795eb7d84685bca4f72f3649f064e6641543d3a8c415898726a57b41" dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", + "rand_chacha", + "rand_core 0.9.5", ] [[package]] @@ -2416,7 +2468,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d3022b5f1df60f26e1ffddd6c66e8aa15de382ae63b3a0c1bfc0e4d3e3f325cb" dependencies = [ "ppv-lite86", - "rand_core 0.9.3", + "rand_core 0.9.5", ] [[package]] @@ -2424,40 +2476,39 @@ name = "rand_core" version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.16", -] [[package]] name = "rand_core" -version = "0.9.3" +version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99d9a13982dcf210057a8a78572b2217b667c3beacbf3a0d8b454f6f82837d38" +checksum = "76afc826de14238e6e8c374ddcc1fa19e374fd8dd986b0d2af0d02377261d83c" dependencies = [ - "getrandom 0.3.3", + "getrandom 0.3.4", ] [[package]] name = "range-alloc" -version = "0.1.4" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3d6831663a5098ea164f89cff59c6284e95f4e3c76ce9848d4529f5ccca9bde" +checksum = "ca45419789ae5a7899559e9512e58ca889e41f04f1f2445e9f4b290ceccd1d08" [[package]] name = "rav1e" -version = "0.7.1" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd87ce80a7665b1cce111f8a16c1f3929f6547ce91ade6addf4ec86a8dda5ce9" +checksum = "43b6dd56e85d9483277cde964fd1bdb0428de4fec5ebba7540995639a21cb32b" dependencies = [ + "aligned-vec", "arbitrary", "arg_enum_proc_macro", "arrayvec", + "av-scenechange", "av1-grain", "bitstream-io", "built", "cfg-if", "interpolate_name", - "itertools 0.12.1", + "itertools 0.14.0", "libc", "libfuzzer-sys", "log", @@ -2466,23 +2517,21 @@ dependencies = [ "noop_proc_macro", "num-derive", "num-traits", - "once_cell", "paste", "profiling", - "rand 0.8.5", - "rand_chacha 0.3.1", + "rand 0.9.5", + "rand_chacha", "simd_helpers", - "system-deps", - "thiserror 1.0.69", + "thiserror 2.0.18", "v_frame", "wasm-bindgen", ] [[package]] name = "ravif" -version = "0.11.20" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5825c26fddd16ab9f515930d49028a630efec172e903483c94796cfe31893e6b" +checksum = "e52310197d971b0f5be7fe6b57530dcd27beb35c1b013f29d66c1ad73fbbcc45" dependencies = [ "avif-serialize", "imgref", @@ -2493,6 +2542,15 @@ dependencies = [ "rgb", ] +[[package]] +name = "raw-cpuid" +version = "11.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "498cd0dc59d73224351ee52a95fee0f1a617a2eae0e7d9d720cc622c73a54186" +dependencies = [ + "bitflags 2.13.1", +] + [[package]] name = "raw-window-handle" version = "0.6.2" @@ -2501,9 +2559,9 @@ checksum = "20675572f6f24e9e76ef639bc5552774ed45f1c30e2951e1e99c59888861c539" [[package]] name = "rayon" -version = "1.11.0" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "368f01d005bf8fd9b1206fb6fa653e6c4a81ceb1466406b81792d87c5677a58f" +checksum = "fb39b166781f92d482534ef4b4b1b2568f42613b53e5b6c160e24cfbfa30926d" dependencies = [ "either", "rayon-core", @@ -2519,25 +2577,31 @@ dependencies = [ "crossbeam-utils", ] +[[package]] +name = "reborrow" +version = "0.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "03251193000f4bd3b042892be858ee50e8b3719f2b08e5833ac4353724632430" + [[package]] name = "redox_syscall" version = "0.5.18" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ed2bf2547551a7053d6fdfafda3f938979645c44812fbfcda098faae3f1a362d" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", ] [[package]] name = "regex" -version = "1.11.3" +version = "1.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b5288124840bee7b386bc413c487869b360b2b4ec421ea56425128692f2a82c" +checksum = "f020237b6c8eed93db2e2cb53c00c60a8e1bc73da7d073199a1180401450218d" dependencies = [ "aho-corasick", "memchr", - "regex-automata 0.4.11", - "regex-syntax 0.8.6", + "regex-automata 0.4.16", + "regex-syntax 0.8.11", ] [[package]] @@ -2553,13 +2617,13 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.11" +version = "0.4.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "833eb9ce86d40ef33cb1306d8accf7bc8ec2bfea4355cbdebb3df68b40925cad" +checksum = "8fcfdb36bda0c880c5931cdc7a2bcdc8ba4556847b9d912bca70bc94708711ad" dependencies = [ "aho-corasick", "memchr", - "regex-syntax 0.8.6", + "regex-syntax 0.8.11", ] [[package]] @@ -2570,9 +2634,9 @@ checksum = "dbb5fb1acd8a1a18b3dd5be62d25485eb770e05afb408a9627d14d451bae12da" [[package]] name = "regex-syntax" -version = "0.8.6" +version = "0.8.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "caf4aa5b0f434c91fe5c7f1ecb6a5ece2130b02ad2a590589dda5146df959001" +checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4" [[package]] name = "renderdoc-sys" @@ -2588,9 +2652,9 @@ checksum = "4b9cb77e81b1d036c2543436df7c5ac85839b1a774a826a9f2607c57094d1a23" [[package]] name = "rgb" -version = "0.8.52" +version = "0.8.53" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c6a884d2998352bb4daf0183589aec883f16a6da1f4dde84d8e2e9a5409a1ce" +checksum = "47b34b781b31e5d73e9fbc8689c70551fd1ade9a19e3e28cfec8580a79290cc4" [[package]] name = "roxmltree" @@ -2598,12 +2662,6 @@ version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c20b6793b5c2fa6553b250154b78d6d0db37e72700ae35fad9387a46f487c97" -[[package]] -name = "rustc-demangle" -version = "0.1.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56f7d92ca342cea22a06f2121d944b4fd82af56988c270852495420f961d4ace" - [[package]] name = "rustc-hash" version = "1.1.0" @@ -2612,9 +2670,18 @@ checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" [[package]] name = "rustc-hash" -version = "2.1.2" +version = "2.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94300abf3f1ae2e2b8ffb7b58043de3d399c73fa6f4b73826402a5c457614dbe" +checksum = "6b1e7f9a428571be2dc5bc0505c13fb6bf936822b894ec87abf8a08a4e51742d" + +[[package]] +name = "rustc_version" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92" +dependencies = [ + "semver", +] [[package]] name = "rustix" @@ -2622,7 +2689,7 @@ version = "0.38.44" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", "errno", "libc", "linux-raw-sys", @@ -2631,15 +2698,9 @@ dependencies = [ [[package]] name = "rustversion" -version = "1.0.22" +version = "1.0.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b39cdef0fa800fc44525c84ccb54a029961a8215f9619753635a9c0d2538d46d" - -[[package]] -name = "ryu" -version = "1.0.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28d3b2b1366ec20994f1fd18c3c594f05c5dd4bc44d8bb0c1c632c8d6829481f" +checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f" [[package]] name = "safe-transmute" @@ -2653,6 +2714,12 @@ version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" +[[package]] +name = "semver" +version = "1.0.28" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd" + [[package]] name = "serde" version = "1.0.228" @@ -2685,15 +2752,15 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.145" +version = "1.0.150" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "402a6f66d8c709116cf22f558eab210f5a50187f702eb4d7e5ef38d9a7f1c79c" +checksum = "e8014e44b4736ed0538adeecded0fce2a272f22dc9578a7eb6b2d9993c74cfb9" dependencies = [ "itoa", "memchr", - "ryu", "serde", "serde_core", + "zmij", ] [[package]] @@ -2740,20 +2807,27 @@ version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" +[[package]] +name = "shlex" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8fadd59c855ef2080decdef8ff161eb6661b86933c9d82e5ba29dc602a55aba" + [[package]] name = "signal-hook-registry" -version = "1.4.6" +version = "1.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2a4719bff48cee6b39d12c020eeb490953ad2443b7055bd0b21fca26bd8c28b" +checksum = "c4db69cba1110affc0e9f7bcd48bbf87b3f4fc7c61fc9155afd4c469eb3d6c1b" dependencies = [ + "errno", "libc", ] [[package]] name = "simd-adler32" -version = "0.3.7" +version = "0.3.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" +checksum = "3a219298ac11a56ea9a6d2120044824d6f01aeb034955e7af7bc16858527deea" [[package]] name = "simd_helpers" @@ -2766,30 +2840,30 @@ dependencies = [ [[package]] name = "siphasher" -version = "1.0.1" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56199f7ddabf13fe5074ce809e7d3f42b42ae711800501b5b16ea82ad029c39d" +checksum = "8ee5873ec9cce0195efcb7a4e9507a04cd49aec9c83d0389df45b1ef7ba2e649" [[package]] name = "slab" -version = "0.4.11" +version = "0.4.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a2ae44ef20feb57a68b23d846850f861394c2e02dc425a50098ae8c90267589" +checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5" [[package]] name = "slotmap" -version = "1.0.7" +version = "1.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbff4acf519f630b3a3ddcfaea6c06b42174d9a44bc70c620e9ed1649d58b82a" +checksum = "bdd58c3c93c3d278ca835519292445cb4b0d4dc59ccfdf7ceadaab3f8aeb4038" dependencies = [ "version_check", ] [[package]] name = "smallvec" -version = "1.15.1" +version = "1.15.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67b1b7a3b5fe4f1376887184045fcf45c69e92af734b7aaddc05fb777b6fbd03" +checksum = "8ed6a63f02c8539c91a8685a86f4099661ba3da017932f6ebbea6de3f0fa7c90" dependencies = [ "serde", ] @@ -2805,19 +2879,19 @@ dependencies = [ [[package]] name = "socket2" -version = "0.6.0" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "233504af464074f9d066d7b5416c5f9b894a5862a6506e306f7b816cdd6f1807" +checksum = "c3d1e2c7f27f8d4cb10542a02c49005dbd6e93095799d6f3be745fae9f8fedd4" dependencies = [ "libc", - "windows-sys 0.59.0", + "windows-sys 0.61.2", ] [[package]] name = "spin" -version = "0.10.0" +version = "0.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5fe4ccb98d9c292d56fec89a5e07da7fc4cf0dc11e156b41793132775d3e591" +checksum = "023a211cb3138dbc438680b32560ad89f699977624c9f8dbb95a47d5b4c07dd3" dependencies = [ "portable-atomic", ] @@ -2828,26 +2902,26 @@ version = "0.3.0+sdk-1.3.268.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eda41003dc44290527a59b13432d4a0379379fa074b70174882adfbdfd917844" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", ] [[package]] name = "stable_deref_trait" -version = "1.2.0" +version = "1.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" +checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596" [[package]] name = "stacker" -version = "0.1.22" +version = "0.1.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1f8b29fb42aafcea4edeeb6b2f2d7ecd0d969c48b4cf0d2e64aafc471dd6e59" +checksum = "640c8cdd92b6b12f5bcb1803ca3bbf5ab96e5e6b6b96b9ab77dabe9e880b3190" dependencies = [ "cc", "cfg-if", "libc", "psm", - "windows-sys 0.59.0", + "windows-sys 0.61.2", ] [[package]] @@ -2864,34 +2938,15 @@ checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" [[package]] name = "syn" -version = "2.0.106" +version = "2.0.119" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ede7c438028d4436d71104916910f5bb611972c5cfd7f89b8300a8186e6fada6" +checksum = "872831b642d1a07999a962a351ed35b955ea2cfc8f3862091e2a240a84f17297" dependencies = [ "proc-macro2", "quote", "unicode-ident", ] -[[package]] -name = "system-deps" -version = "6.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3e535eb8dded36d55ec13eddacd30dec501792ff23a0b1682c38601b8cf2349" -dependencies = [ - "cfg-expr", - "heck", - "pkg-config", - "toml", - "version-compare", -] - -[[package]] -name = "target-lexicon" -version = "0.12.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61c41af27dd6d1e27b1b16b489db798443478cef1f06a660c96db617ba5de3b1" - [[package]] name = "termcolor" version = "1.4.1" @@ -2912,11 +2967,11 @@ dependencies = [ [[package]] name = "thiserror" -version = "2.0.17" +version = "2.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f63587ca0f12b72a0600bcba1d40081f830876000bb46dd2337a3051618f4fc8" +checksum = "4288b5bcbc7920c07a1149a35cf9590a2aa808e0bc1eafaade0b80947865fbc4" dependencies = [ - "thiserror-impl 2.0.17", + "thiserror-impl 2.0.18", ] [[package]] @@ -2932,9 +2987,9 @@ dependencies = [ [[package]] name = "thiserror-impl" -version = "2.0.17" +version = "2.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ff15c8ecd7de3849db632e14d18d2571fa09dfc5ed93479bc4485c7a517c913" +checksum = "ebc4ee7f67670e9b64d05fa4253e753e016c6c95ff35b89b7941d6b856dec1d5" dependencies = [ "proc-macro2", "quote", @@ -2943,18 +2998,18 @@ dependencies = [ [[package]] name = "thread_local" -version = "1.1.9" +version = "1.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f60246a4944f24f6e018aa17cdeffb7818b76356965d03b07d6a9886e8962185" +checksum = "1ad99c4c6d32803332c548b1af0540b357b3f5fc0be8f6c6bfe8b2e6ae784070" dependencies = [ "cfg-if", ] [[package]] name = "tiff" -version = "0.10.3" +version = "0.11.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af9605de7fee8d9551863fd692cce7637f548dbd9db9180fcc07ccc6d26c336f" +checksum = "b63feaf3343d35b6ca4d50483f94843803b0f51634937cc2ec519fc32232bc52" dependencies = [ "fax", "flate2", @@ -2966,29 +3021,26 @@ dependencies = [ [[package]] name = "tokio" -version = "1.47.1" +version = "1.53.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89e49afdadebb872d3145a5638b59eb0691ea23e46ca484037cfab3b76b95038" +checksum = "d988bcd52dbe076d3d46903332f58c912b87a2c49b1428419a5845154762ffee" dependencies = [ - "backtrace", "bytes", - "io-uring", "libc", "mio", "parking_lot", "pin-project-lite", "signal-hook-registry", - "slab", "socket2", "tokio-macros", - "windows-sys 0.59.0", + "windows-sys 0.61.2", ] [[package]] name = "tokio-macros" -version = "2.5.0" +version = "2.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e06d43f1345a3bcd39f6a56dbb7dcab2ba47e68e8ac134855e7e2bdbaf8cab8" +checksum = "6328af13490e73a9b4694030fafd93f8c8c6a9dede33e821c3fc63eddf8042ba" dependencies = [ "proc-macro2", "quote", @@ -3018,9 +3070,9 @@ dependencies = [ [[package]] name = "toml_datetime" -version = "0.7.2" +version = "0.7.5+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32f1085dec27c2b6632b04c80b3bb1b4300d6495d1e129693bdda7d91e72eec1" +checksum = "92e1cfed4a3038bc5a127e35a2d360f145e1f4b971b551a2ba5fd7aedf7e1347" dependencies = [ "serde_core", ] @@ -3036,28 +3088,28 @@ dependencies = [ "serde_spanned", "toml_datetime 0.6.11", "toml_write", - "winnow", + "winnow 0.7.15", ] [[package]] name = "toml_edit" -version = "0.23.6" +version = "0.23.10+spec-1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3effe7c0e86fdff4f69cdd2ccc1b96f933e24811c5441d44904e8683e27184b" +checksum = "84c8b9f757e028cee9fa244aea147aab2a9ec09d5325a9b01e0a49730c2b5269" dependencies = [ "indexmap", - "toml_datetime 0.7.2", + "toml_datetime 0.7.5+spec-1.1.0", "toml_parser", - "winnow", + "winnow 0.7.15", ] [[package]] name = "toml_parser" -version = "1.0.3" +version = "1.1.2+spec-1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4cf893c33be71572e0e9aa6dd15e6677937abd686b066eac3f8cd3531688a627" +checksum = "a2abe9b86193656635d2411dc43050282ca48aa31c2451210f4202550afb7526" dependencies = [ - "winnow", + "winnow 1.0.4", ] [[package]] @@ -3068,9 +3120,9 @@ checksum = "5d99f8c9a7727884afe522e9bd5edbfc91a3312b36a77b5fb8926e4c31a41801" [[package]] name = "tracing" -version = "0.1.41" +version = "0.1.44" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "784e0ac535deb450455cbfa28a6f0df145ea1bb7ae51b821cf5e7927fdcfbdd0" +checksum = "63e71662fa4b2a2c3a26f570f037eb95bb1f85397f3cd8076caed2f026a6d100" dependencies = [ "pin-project-lite", "tracing-attributes", @@ -3079,9 +3131,9 @@ dependencies = [ [[package]] name = "tracing-attributes" -version = "0.1.30" +version = "0.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81383ab64e72a7a8b8e13130c49e3dab29def6d0c7d76a03087b3cf71c5c6903" +checksum = "7490cfa5ec963746568740651ac6781f701c9c5ea257c58e057f3ba8cf69e8da" dependencies = [ "proc-macro2", "quote", @@ -3090,9 +3142,9 @@ dependencies = [ [[package]] name = "tracing-core" -version = "0.1.34" +version = "0.1.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9d12581f227e93f094d3af2ae690a574abb8a2b9b7a96e7cfe9647b2b617678" +checksum = "db97caf9d906fbde555dd62fa95ddba9eecfd14cb388e4f491a66d74cd5fb79a" dependencies = [ "once_cell", "valuable", @@ -3111,14 +3163,14 @@ dependencies = [ [[package]] name = "tracing-subscriber" -version = "0.3.20" +version = "0.3.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2054a14f5307d601f88daf0553e1cbf472acc4f2c51afab632431cdcd72124d5" +checksum = "cb7f578e5945fb242538965c2d0b04418d38ec25c79d160cd279bf0731c8d319" dependencies = [ "matchers", "nu-ansi-term", "once_cell", - "regex-automata 0.4.11", + "regex-automata 0.4.16", "sharded-slab", "smallvec", "thread_local", @@ -3129,9 +3181,9 @@ dependencies = [ [[package]] name = "tracing-test" -version = "0.2.5" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "557b891436fe0d5e0e363427fc7f217abf9ccd510d5136549847bdcbcd011d68" +checksum = "19a4c448db514d4f24c5ddb9f73f2ee71bfb24c526cf0c570ba142d1119e0051" dependencies = [ "tracing-core", "tracing-subscriber", @@ -3140,9 +3192,9 @@ dependencies = [ [[package]] name = "tracing-test-macro" -version = "0.2.5" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04659ddb06c87d233c566112c1c9c5b9e98256d9af50ec3bc9c8327f873a7568" +checksum = "ad06847b7afb65c7866a36664b75c40b895e318cea4f71299f013fb22965329d" dependencies = [ "quote", "syn", @@ -3152,7 +3204,7 @@ dependencies = [ name = "transmute-extra" version = "0.0.13" dependencies = [ - "thiserror 2.0.17", + "thiserror 2.0.18", ] [[package]] @@ -3163,15 +3215,15 @@ checksum = "bc7d623258602320d5c55d1bc22793b57daff0ec7efc270ea7d55ce1d5f5471c" [[package]] name = "unicode-ident" -version = "1.0.19" +version = "1.0.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f63a545481291138910575129486daeaf8ac54aee4387fe7906919f7830c7d9d" +checksum = "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75" [[package]] name = "unicode-segmentation" -version = "1.12.0" +version = "1.13.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6ccf251212114b54433ec949fd6a7841275f9ada20dddd2f29e9ceea4501493" +checksum = "c6f5d3c3b1bf09027a88a6bc961fc00497d651009560b5463668dc81b0fa87a8" [[package]] name = "unicode-width" @@ -3208,13 +3260,13 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.18.1" +version = "1.24.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f87b8aa10b915a06587d0dec516c282ff295b475d94abf425d62b57710070a2" +checksum = "bf3923a6f5c4c6382e0b653c4117f48d631ea17f38ed86e2a828e6f7412f5239" dependencies = [ - "getrandom 0.3.3", + "getrandom 0.4.3", "js-sys", - "serde", + "serde_core", "wasm-bindgen", ] @@ -3258,12 +3310,6 @@ version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" -[[package]] -name = "version-compare" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "852e951cb7832cb45cb1169900d19760cfa39b82bc0ea9c0e5a14ae88411c98b" - [[package]] name = "version_check" version = "0.9.5" @@ -3274,11 +3320,11 @@ checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" name = "video" version = "0.0.13" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", "ffmpeg-sys-next", "glam", "static_assertions", - "thiserror 2.0.17", + "thiserror 2.0.18", ] [[package]] @@ -3293,29 +3339,20 @@ version = "0.11.1+wasi-snapshot-preview1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ccf3ec651a847eb01de73ccad15eb7d99f80485de043efb2f370cd654f4ea44b" -[[package]] -name = "wasi" -version = "0.14.7+wasi-0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "883478de20367e224c0090af9cf5f9fa85bed63a95c1abf3afc5c083ebc06e8c" -dependencies = [ - "wasip2", -] - [[package]] name = "wasip2" -version = "1.0.1+wasi-0.2.4" +version = "1.0.4+wasi-0.2.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0562428422c63773dad2c345a1882263bbf4d65cf3f42e90921f787ef5ad58e7" +checksum = "b67efb37e106e55ce722a510d6b5f9c17f083e5fc79afc2badeb12cc313d9487" dependencies = [ "wit-bindgen", ] [[package]] name = "wasm-bindgen" -version = "0.2.104" +version = "0.2.126" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1da10c01ae9f1ae40cbfac0bac3b1e724b320abfcf52229f80b547c0d250e2d" +checksum = "4b067c0c11094aef6b7a801c1e34a26affafdf3d051dba08456b868789aaf9a4" dependencies = [ "cfg-if", "once_cell", @@ -3324,38 +3361,21 @@ dependencies = [ "wasm-bindgen-shared", ] -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.104" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "671c9a5a66f49d8a47345ab942e2cb93c7d1d0339065d4f8139c486121b43b19" -dependencies = [ - "bumpalo", - "log", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - [[package]] name = "wasm-bindgen-futures" -version = "0.4.54" +version = "0.4.76" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e038d41e478cc73bae0ff9b36c60cff1c98b8f38f8d7e8061e79ee63608ac5c" +checksum = "c62df1340f32221cb9c54d6a27b030e3dba64361d4a95bed55f9aacb44da291d" dependencies = [ - "cfg-if", "js-sys", - "once_cell", "wasm-bindgen", - "web-sys", ] [[package]] name = "wasm-bindgen-macro" -version = "0.2.104" +version = "0.2.126" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ca60477e4c59f5f2986c50191cd972e3a50d8a95603bc9434501cf156a9a119" +checksum = "167ce5e579f6bcf889c4f7175a8a5a585de84e8ff93976ce393efa5f2837aab1" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -3363,22 +3383,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.104" +version = "0.2.126" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f07d2f20d4da7b26400c9f4a0511e6e0345b040694e8a75bd41d578fa4421d7" +checksum = "f3997c7839262f4ef12cf90b818d6340c18e80f263f1a94bf157d0ec4420380e" dependencies = [ + "bumpalo", "proc-macro2", "quote", "syn", - "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.104" +version = "0.2.126" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bad67dc8b2a1a6e5448428adec4c3e84c43e561d8c9ee8a9e5aabeb193ec41d1" +checksum = "dc1b4cb0cc549fcf58d7dfc081778139b3d283a081644e833e84682ad71cea24" dependencies = [ "unicode-ident", ] @@ -3387,14 +3407,14 @@ dependencies = [ name = "wayland-client" version = "0.0.13" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", "fxhash", "phf", "raw-window-handle", "rustix", "smallvec", "static_assertions", - "thiserror 2.0.17", + "thiserror 2.0.18", "tracing", "tracing-subscriber", "tracing-test", @@ -3414,7 +3434,7 @@ dependencies = [ "serde", "smallvec", "syn", - "thiserror 2.0.17", + "thiserror 2.0.18", "tracing", "tracing-subscriber", "wayland-sys", @@ -3426,7 +3446,7 @@ name = "wayland-server" version = "0.0.13" dependencies = [ "rustix", - "thiserror 2.0.17", + "thiserror 2.0.18", "tracing", "wayland-sys", ] @@ -3437,7 +3457,7 @@ version = "0.0.13" dependencies = [ "libc", "static_assertions", - "thiserror 2.0.17", + "thiserror 2.0.18", "va_list", ] @@ -3450,7 +3470,7 @@ dependencies = [ "file-format", "image", "rustix", - "thiserror 2.0.17", + "thiserror 2.0.18", "tracing", "tracing-subscriber", "transmute-extra", @@ -3474,7 +3494,7 @@ dependencies = [ "rustix", "scopeguard", "smallvec", - "thiserror 2.0.17", + "thiserror 2.0.18", "tokio", "toml", "tracing", @@ -3510,11 +3530,11 @@ dependencies = [ "bytemuck", "glam", "libc", - "rand 0.9.2", + "rand 0.9.5", "rustix", "serde", "smallvec", - "thiserror 2.0.17", + "thiserror 2.0.18", "toml", "tracing", ] @@ -3524,7 +3544,7 @@ name = "waywe-runtime" version = "0.0.13" dependencies = [ "ash", - "bitflags 2.9.4", + "bitflags 2.13.1", "box_into_inner", "bytemuck", "derive_more", @@ -3537,7 +3557,7 @@ dependencies = [ "rustix", "smallvec", "static_assertions", - "thiserror 2.0.17", + "thiserror 2.0.18", "tracing", "video", "wayland-client", @@ -3551,7 +3571,7 @@ version = "0.0.13" dependencies = [ "ash", "bevy_ecs", - "bitflags 2.9.4", + "bitflags 2.13.1", "box_into_inner", "bytemuck", "crossbeam", @@ -3561,7 +3581,7 @@ dependencies = [ "itertools 0.14.0", "smallvec", "static_assertions", - "thiserror 2.0.17", + "thiserror 2.0.18", "tracing", "transmute-extra", "variadics_please", @@ -3582,9 +3602,9 @@ dependencies = [ [[package]] name = "web-sys" -version = "0.3.81" +version = "0.3.103" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9367c417a924a74cae129e6a2ae3b47fabb1f8995595ab474029da749a8be120" +checksum = "8622dcb61c0bcc9fffa6938bed81210af2da9a7e4a1a834b2e37a59b6dfb6141" dependencies = [ "js-sys", "wasm-bindgen", @@ -3592,9 +3612,9 @@ dependencies = [ [[package]] name = "weezl" -version = "0.1.10" +version = "0.1.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a751b3277700db47d3e574514de2eced5e54dc8a5436a3bf7a0b248b2cee16f3" +checksum = "a28ac98ddc8b9274cb41bb4d9d4d5c425b6020c50c46f25559911905610b4a88" [[package]] name = "wgpu" @@ -3603,11 +3623,11 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bfe68bac7cde125de7a731c3400723cadaaf1703795ad3f4805f187459cd7a77" dependencies = [ "arrayvec", - "bitflags 2.9.4", + "bitflags 2.13.1", "cfg-if", "cfg_aliases", "document-features", - "hashbrown 0.16.0", + "hashbrown 0.16.1", "js-sys", "log", "naga", @@ -3627,18 +3647,18 @@ dependencies = [ [[package]] name = "wgpu-core" -version = "27.0.1" +version = "27.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3d654c0b6c6335edfca18c11bdaed964def641b8e9997d3a495a2ff4077c922" +checksum = "27a75de515543b1897b26119f93731b385a19aea165a1ec5f0e3acecc229cae7" dependencies = [ "arrayvec", "bit-set", "bit-vec", - "bitflags 2.9.4", + "bitflags 2.13.1", "bytemuck", "cfg_aliases", "document-features", - "hashbrown 0.16.0", + "hashbrown 0.16.1", "indexmap", "log", "naga", @@ -3649,7 +3669,7 @@ dependencies = [ "raw-window-handle", "rustc-hash 1.1.0", "smallvec", - "thiserror 2.0.17", + "thiserror 2.0.18", "wgpu-core-deps-apple", "wgpu-core-deps-emscripten", "wgpu-core-deps-windows-linux-android", @@ -3686,15 +3706,15 @@ dependencies = [ [[package]] name = "wgpu-hal" -version = "27.0.2" +version = "27.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2618a2d6b8a5964ecc1ac32a5db56cb3b1e518725fcd773fd9a782e023453f2b" +checksum = "5b21cb61c57ee198bc4aff71aeadff4cbb80b927beb912506af9c780d64313ce" dependencies = [ "android_system_properties", "arrayvec", "ash", "bit-set", - "bitflags 2.9.4", + "bitflags 2.13.1", "block", "bytemuck", "cfg-if", @@ -3705,7 +3725,7 @@ dependencies = [ "gpu-alloc", "gpu-allocator", "gpu-descriptor", - "hashbrown 0.16.0", + "hashbrown 0.16.1", "js-sys", "khronos-egl", "libc", @@ -3725,7 +3745,7 @@ dependencies = [ "raw-window-handle", "renderdoc-sys", "smallvec", - "thiserror 2.0.17", + "thiserror 2.0.18", "wasm-bindgen", "web-sys", "wgpu-types 27.0.1", @@ -3739,12 +3759,12 @@ version = "26.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eca7a8d8af57c18f57d393601a1fb159ace8b2328f1b6b5f80893f7d672c9ae2" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", "bytemuck", "js-sys", "log", "serde", - "thiserror 2.0.17", + "thiserror 2.0.18", "web-sys", ] @@ -3754,11 +3774,11 @@ version = "27.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "afdcf84c395990db737f2dd91628706cb31e86d72e53482320d368e52b5da5eb" dependencies = [ - "bitflags 2.9.4", + "bitflags 2.13.1", "bytemuck", "js-sys", "log", - "thiserror 2.0.17", + "thiserror 2.0.18", "web-sys", ] @@ -3800,7 +3820,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dd04d41d93c4992d421894c18c8b43496aa748dd4c081bac0dc93eb0489272b6" dependencies = [ "windows-core", - "windows-targets 0.52.6", + "windows-targets", ] [[package]] @@ -3813,7 +3833,7 @@ dependencies = [ "windows-interface", "windows-result", "windows-strings", - "windows-targets 0.52.6", + "windows-targets", ] [[package]] @@ -3850,7 +3870,7 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1d1043d8214f791817bab27572aaa8af63732e11bf84aa21a45a78d6c317ae0e" dependencies = [ - "windows-targets 0.52.6", + "windows-targets", ] [[package]] @@ -3860,16 +3880,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4cd9b125c486025df0eabcb585e62173c6c9eddcec5d117d3b6e8c30e2ee4d10" dependencies = [ "windows-result", - "windows-targets 0.52.6", -] - -[[package]] -name = "windows-sys" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" -dependencies = [ - "windows-targets 0.52.6", + "windows-targets", ] [[package]] @@ -3878,16 +3889,7 @@ version = "0.59.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" dependencies = [ - "windows-targets 0.52.6", -] - -[[package]] -name = "windows-sys" -version = "0.60.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2f500e4d28234f72040990ec9d39e3a6b950f9f22d3dba18416c35882612bcb" -dependencies = [ - "windows-targets 0.53.5", + "windows-targets", ] [[package]] @@ -3905,31 +3907,14 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" dependencies = [ - "windows_aarch64_gnullvm 0.52.6", - "windows_aarch64_msvc 0.52.6", - "windows_i686_gnu 0.52.6", - "windows_i686_gnullvm 0.52.6", - "windows_i686_msvc 0.52.6", - "windows_x86_64_gnu 0.52.6", - "windows_x86_64_gnullvm 0.52.6", - "windows_x86_64_msvc 0.52.6", -] - -[[package]] -name = "windows-targets" -version = "0.53.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3" -dependencies = [ - "windows-link", - "windows_aarch64_gnullvm 0.53.1", - "windows_aarch64_msvc 0.53.1", - "windows_i686_gnu 0.53.1", - "windows_i686_gnullvm 0.53.1", - "windows_i686_msvc 0.53.1", - "windows_x86_64_gnu 0.53.1", - "windows_x86_64_gnullvm 0.53.1", - "windows_x86_64_msvc 0.53.1", + "windows_aarch64_gnullvm", + "windows_aarch64_msvc", + "windows_i686_gnu", + "windows_i686_gnullvm", + "windows_i686_msvc", + "windows_x86_64_gnu", + "windows_x86_64_gnullvm", + "windows_x86_64_msvc", ] [[package]] @@ -3938,116 +3923,74 @@ version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9d8416fa8b42f5c947f8482c43e7d89e73a173cead56d044f6a56104a6d1b53" - [[package]] name = "windows_aarch64_msvc" version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" -[[package]] -name = "windows_aarch64_msvc" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9d782e804c2f632e395708e99a94275910eb9100b2114651e04744e9b125006" - [[package]] name = "windows_i686_gnu" version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" -[[package]] -name = "windows_i686_gnu" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "960e6da069d81e09becb0ca57a65220ddff016ff2d6af6a223cf372a506593a3" - [[package]] name = "windows_i686_gnullvm" version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" -[[package]] -name = "windows_i686_gnullvm" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa7359d10048f68ab8b09fa71c3daccfb0e9b559aed648a8f95469c27057180c" - [[package]] name = "windows_i686_msvc" version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" -[[package]] -name = "windows_i686_msvc" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e7ac75179f18232fe9c285163565a57ef8d3c89254a30685b57d83a38d326c2" - [[package]] name = "windows_x86_64_gnu" version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" -[[package]] -name = "windows_x86_64_gnu" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c3842cdd74a865a8066ab39c8a7a473c0778a3f29370b5fd6b4b9aa7df4a499" - [[package]] name = "windows_x86_64_gnullvm" version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ffa179e2d07eee8ad8f57493436566c7cc30ac536a3379fdf008f47f6bb7ae1" - [[package]] name = "windows_x86_64_msvc" version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" -[[package]] -name = "windows_x86_64_msvc" -version = "0.53.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6bbff5f0aada427a1e5a6da5f1f98158182f26556f345ac9e04d36d0ebed650" - [[package]] name = "winnow" -version = "0.7.13" +version = "0.7.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21a0236b59786fed61e2a80582dd500fe61f18b5dca67a4a067d0bc9039339cf" +checksum = "df79d97927682d2fd8adb29682d1140b343be4ac0f08fd68b7765d9c059d3945" dependencies = [ "memchr", ] +[[package]] +name = "winnow" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23b97319f7b8343df12cc98938e5c3eb436064524c8d2b4e30a1d3a36eecdf81" + [[package]] name = "wit-bindgen" -version = "0.46.0" +version = "0.57.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f17a85883d4e6d00e8a97c586de764dabcc06133f7f1d55dce5cdc070ad7fe59" +checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e" [[package]] name = "xml-rs" -version = "0.8.27" +version = "0.8.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fd8403733700263c6eb89f192880191f1b83e332f7a20371ddcf421c4a337c7" +checksum = "3ae8337f8a065cfc972643663ea4279e04e7256de865aa66fe25cec5fb912d3f" [[package]] name = "xml_serde" @@ -4066,31 +4009,43 @@ dependencies = [ "xml-rs", ] +[[package]] +name = "y4m" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a5a4b21e1a62b67a2970e6831bc091d7b87e119e7f9791aef9702e3bef04448" + [[package]] name = "zerocopy" -version = "0.8.27" +version = "0.8.54" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0894878a5fa3edfd6da3f88c4805f4c8558e2b996227a3d864f47fe11e38282c" +checksum = "b7cbbc0a705a0fd05cc3676525980d2bf5a9bc4adac6d6475209a7887cf59d19" dependencies = [ "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.8.27" +version = "0.8.54" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88d2b8d9c68ad2b9e4340d7832716a4d21a22a1154777ad56ea55c51a9cf3831" +checksum = "e2e817b7b52d0c7358d3246da9d69935ebb18116b2b102b4230dac079b4862f5" dependencies = [ "proc-macro2", "quote", "syn", ] +[[package]] +name = "zmij" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b" + [[package]] name = "zune-core" -version = "0.4.12" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f423a2c17029964870cfaabb1f13dfab7d092a62a29a89264f4d36990ca414a" +checksum = "cb8a0807f7c01457d0379ba880ba6322660448ddebc890ce29bb64da71fb40f9" [[package]] name = "zune-inflate" @@ -4103,9 +4058,9 @@ dependencies = [ [[package]] name = "zune-jpeg" -version = "0.4.21" +version = "0.5.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29ce2c8a9384ad323cf564b67da86e21d3cfdff87908bc1223ed5c99bc792713" +checksum = "27bc9d5b815bc103f142aa054f561d9187d191692ec7c2d1e2b4737f8dbd7296" dependencies = [ "zune-core", ] diff --git a/crates/examples/waywe-test-scene/build.rs b/crates/examples/waywe-test-scene/build.rs new file mode 100644 index 00000000..a9cbdf8d --- /dev/null +++ b/crates/examples/waywe-test-scene/build.rs @@ -0,0 +1,71 @@ +use std::{ + env, + fs::{self, File}, + io, + path::{Path, PathBuf}, +}; + +const USER_AGENT: &str = + "waywe-test-scene/0.0.15 (https://github.com/hack3rmann/waywe-rs; build-script)"; + +const ASSETS: &[(&str, &str)] = &[ + ( + "test-image.jpg", + "https://upload.wikimedia.org/wikipedia/commons/1/11/003_Ringed_kingfisher_flying_with_a_fish_in_Encontro_das_%C3%81guas_State_Park_Photo_by_Giles_Laurent.jpg", + ), + ( + "test-image2.jpg", + "https://upload.wikimedia.org/wikipedia/commons/thumb/a/a9/KAP_Jasa-High_Plateau.jpg/3840px-KAP_Jasa-High_Plateau.jpg", + ), + ( + "test-video.mp4", + "https://interactive-examples.mdn.mozilla.net/media/cc0-videos/flower.mp4", + ), + // ( + // "test-video2.mp4", + // "https://download.samplelib.com/mp4/sample-5s.mp4", + // ), + // ( + // "test-video3.mp4", + // "https://download.samplelib.com/mp4/sample-10s.mp4", + // ), +]; + +fn main() { + let manifest_dir = + PathBuf::from(env::var_os("CARGO_MANIFEST_DIR").expect("CARGO_MANIFEST_DIR is not set")); + let assets_dir = manifest_dir.join("assets"); + + if !assets_dir.exists() { + fs::create_dir_all(&assets_dir).expect("failed to create assets directory"); + } + + for &(filename, url) in ASSETS { + let dest = assets_dir.join(filename); + download_if_missing(url, &dest); + } + + println!("cargo:rerun-if-changed=build.rs"); +} + +fn download_if_missing(url: &str, dest: &Path) { + if dest.exists() { + return; + } + + let response = ureq::get(url) + .set("User-Agent", USER_AGENT) + .call() + .unwrap_or_else(|error| panic!("failed to download {url}: {error}")); + + let status = response.status(); + if !(200..300).contains(&status) { + panic!("failed to download {url}: HTTP {status}"); + } + + let mut reader = response.into_reader(); + let mut file = File::create(dest) + .unwrap_or_else(|error| panic!("failed to create {}: {error}", dest.display())); + io::copy(&mut reader, &mut file) + .unwrap_or_else(|error| panic!("failed to write {}: {error}", dest.display())); +} diff --git a/crates/video/src/lib.rs b/crates/video/src/lib.rs index 7945a05b..460667ba 100644 --- a/crates/video/src/lib.rs +++ b/crates/video/src/lib.rs @@ -8,13 +8,8 @@ pub mod time; use bitflags::bitflags; use ffi::va; use ffmpeg_sys_next::{ - AV_PROFILE_UNKNOWN, AVCodecContext, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, - AVPixFmtDescriptor, AVProfile, AVSEEK_FLAG_BACKWARD, AVStream, SwsContext, SwsFlags, - av_buffer_get_ref_count, av_codec_iterate, av_find_best_stream, av_frame_alloc, av_frame_free, - av_frame_get_buffer, av_frame_unref, av_new_packet, av_packet_alloc, av_packet_free, - av_packet_ref, av_packet_unref, av_read_frame, av_seek_frame, avcodec_flush_buffers, - avdevice_register_all, avformat_close_input, avformat_find_stream_info, avformat_open_input, - sws_getContext, sws_scale, + AV_NOPTS_VALUE, AV_PROFILE_UNKNOWN, AVCodecContext, AVDiscard, AVFormatContext, AVFrame, AVMediaType, AVPacket, AVPixFmtDescriptor, AVProfile, AVStream, SWS_PARAM_DEFAULT, SWS_SRC_V_CHR_DROP_MASK, SWS_SRC_V_CHR_DROP_SHIFT, SwsContext, SwsFlags::{SWS_ACCURATE_RND, SWS_AREA, SWS_BICUBIC, SWS_BICUBLIN, SWS_BILINEAR, SWS_BITEXACT, SWS_DIRECT_BGR, SWS_ERROR_DIFFUSION, SWS_FAST_BILINEAR, + SWS_FULL_CHR_H_INP, SWS_FULL_CHR_H_INT, SWS_GAUSS, SWS_LANCZOS, SWS_POINT, SWS_PRINT_INFO, SWS_SINC, SWS_SPLINE, SWS_X}, av_buffer_get_ref_count, av_codec_iterate, av_dict_free, av_dict_set, av_find_best_stream, av_frame_alloc, av_frame_free, av_frame_get_buffer, av_frame_unref, av_new_packet, av_packet_alloc, av_packet_free, av_packet_ref, av_packet_unref, av_read_frame, avcodec_flush_buffers, avdevice_register_all, avformat_close_input, avformat_find_stream_info, avformat_open_input, avformat_seek_file, sws_getContext, sws_scale }; use glam::UVec2; use std::{ @@ -24,6 +19,10 @@ use std::{ num::{NonZeroI64, NonZeroU64}, ptr::{self, NonNull}, slice, str, + sync::{ + Mutex, + atomic::{AtomicBool, Ordering::Relaxed}, + }, }; pub use acceleration::VaError; @@ -142,16 +141,37 @@ impl FormatContext { /// If you want to use custom IO, preallocate the format context and set its pb field. pub fn from_input(url: &CStr) -> Result { let mut context_ptr = ptr::null_mut(); + let mut options = ptr::null_mut(); + + const ONE_MEGABYTE: &CStr = c"1048576"; + const ONE_SECOND: &CStr = c"1000000"; + + unsafe { + av_dict_set( + &raw mut options, + c"probesize".as_ptr(), + ONE_MEGABYTE.as_ptr(), + 0, + ); + av_dict_set( + &raw mut options, + c"analyzeduration".as_ptr(), + ONE_SECOND.as_ptr(), + 0, + ); + } BackendError::result_of(unsafe { avformat_open_input( &raw mut context_ptr, url.as_ptr(), ptr::null_mut(), - ptr::null_mut(), + &raw mut options, ) })?; + unsafe { av_dict_free(&raw mut options) }; + let mut context = unsafe { Self::from_raw(NonNull::new_unchecked(context_ptr)) }; context.find_stream_info()?; Ok(context) @@ -169,9 +189,22 @@ impl FormatContext { /// This function isn't guaranteed to open all the codecs, so /// options being non-empty at return is a perfectly normal behavior. pub fn find_stream_info(&mut self) -> Result<(), BackendError> { - BackendError::result_of(unsafe { + static MUTEX: Mutex<()> = Mutex::new(()); + static FIRST_INIT_DONE: AtomicBool = AtomicBool::new(false); + + let _guard = (!FIRST_INIT_DONE.load(Relaxed)) + .then(|| MUTEX.lock().unwrap_or_else(|err| err.into_inner())); + + // HACK(hack3rmann): something WEIRD happens when this functions is called from multiple + // threads for the first time. FFmpeg docs are saying that is MUST be thread-safe. But + // removing the mutexes produces memory errors (unaligned tcache chunk, double-free and friends). + let res = BackendError::result_of(unsafe { avformat_find_stream_info(self.as_raw().as_ptr(), ptr::null_mut()) - }) + }); + + FIRST_INIT_DONE.store(true, Relaxed); + + res } /// A list of all streams in the file. @@ -290,29 +323,41 @@ impl FormatContext { codec_context: *mut AVCodecContext, index: usize, ) -> Result<(), BackendError> { - unsafe { - let ctx = self.as_raw().as_ptr(); - - if ctx.is_null() || codec_context.is_null() { - return Err(BackendError::INVALID_DATA); - } + let ctx = self.as_raw().as_ptr(); + if ctx.is_null() || codec_context.is_null() { + return Err(BackendError::INVALID_DATA); + } - // Seek to stream start - let mut ret = av_seek_frame(ctx, index as i32, 0, AVSEEK_FLAG_BACKWARD); + let stream = unsafe { (*ctx).streams.add(index).read() }; + if stream.is_null() { + return Err(BackendError::INVALID_DATA); + } - // Fallback for containers that dislike explicit stream seek - if ret < 0 { - ret = av_seek_frame(ctx, -1, 0, AVSEEK_FLAG_BACKWARD); - } + // Stream-native start time, in the stream's own time_base — + // not AVFormatContext.start_time, which is AV_TIME_BASE-scaled + // and only meaningful when stream_index == -1. + let start_time = match (unsafe { *stream }).start_time { + AV_NOPTS_VALUE => 0, + t => t, + }; - if ret < 0 { - return BackendError::result_of(ret); - } + let ret = unsafe { + avformat_seek_file( + ctx, + index as i32, + i64::MIN, + start_time, + start_time, + 0, + ) + }; - // Reset decoder state - avcodec_flush_buffers(codec_context); - Ok(()) + if ret < 0 { + return BackendError::result_of(ret); } + + unsafe { avcodec_flush_buffers(codec_context) }; + Ok(()) } } @@ -1091,46 +1136,27 @@ pub struct ScalerFormat { bitflags! { #[derive(Copy, Clone, Debug, PartialEq, Eq)] pub struct ScalerFlags: i32 { - /// < fast bilinear filtering - const FAST_BILINEAR = SwsFlags::SWS_FAST_BILINEAR as i32; - /// < bilinear filtering - const BILINEAR = SwsFlags::SWS_BILINEAR as i32; - /// < 2-tap cubic B-spline - const BICUBIC = SwsFlags::SWS_BICUBIC as i32; - /// < experimental - const X = SwsFlags::SWS_X as i32; - /// < nearest neighbor - const POINT = SwsFlags::SWS_POINT as i32; - /// < area averaging - const AREA = SwsFlags::SWS_AREA as i32; - /// < bicubic luma, bilinear chroma - const BICUBLIN = SwsFlags::SWS_BICUBLIN as i32; - /// < gaussian approximation - const GAUSS = SwsFlags::SWS_GAUSS as i32; - /// < unwindowed sinc - const SINC = SwsFlags::SWS_SINC as i32; - /// < 3-tap sinc/sinc - const LANCZOS = SwsFlags::SWS_LANCZOS as i32; - /// < cubic Keys spline - const SPLINE = SwsFlags::SWS_SPLINE as i32; - /// Return an error on underspecified conversions. Without this flag,\n unspecified fields are defaulted to sensible values. - const STRICT = SwsFlags::SWS_STRICT as i32; - /// Emit verbose log of scaling parameters. - const PRINT_INFO = SwsFlags::SWS_PRINT_INFO as i32; - /// Perform full chroma upsampling when upscaling to RGB.\n\n For example, when converting 50x50 yuv420p to 100x100 rgba, setting this flag\n will scale the chroma plane from 25x25 to 100x100[...] - const FULL_CHR_H_INT = SwsFlags::SWS_FULL_CHR_H_INT as i32; - /// Perform full chroma interpolation when downscaling RGB sources.\n\n For example, when converting a 100x100 rgba source to 50x50 yuv444p, setting\n this flag will generate a 100x100 (4:4:4[...] - const FULL_CHR_H_INP = SwsFlags::SWS_FULL_CHR_H_INP as i32; - /// Force bit-exact output. This will prevent the use of platform-specific\n optimizations that may lead to slight difference in rounding, in favor\n of always maintaining exact bit output co[...] - const ACCURATE_RND = SwsFlags::SWS_ACCURATE_RND as i32; - /// Force bit-exact output. This will prevent the use of platform-specific\n optimizations that may lead to slight difference in rounding, in favor\n of always maintaining exact bit output co[...] - const BITEXACT = SwsFlags::SWS_BITEXACT as i32; - /// Allow using experimental new code paths. This may be faster, slower,\n or produce different output, with semantics subject to change at any\n point in time. For testing and debugging purp[...] - const UNSTABLE = SwsFlags::SWS_UNSTABLE as i32; - /// < This flag has no effect - const DIRECT_BGR = SwsFlags::SWS_DIRECT_BGR as i32; - /// < Set `SwsContext.dither` instead - const ERROR_DIFFUSION = SwsFlags::SWS_ERROR_DIFFUSION as i32; + const FAST_BILINEAR = SWS_FAST_BILINEAR as i32; + const BILINEAR = SWS_BILINEAR as i32; + const BICUBIC = SWS_BICUBIC as i32; + const X = SWS_X as i32; + const POINT = SWS_POINT as i32; + const AREA = SWS_AREA as i32; + const BICUBLIN = SWS_BICUBLIN as i32; + const GAUSS = SWS_GAUSS as i32; + const SINC = SWS_SINC as i32; + const LANCZOS = SWS_LANCZOS as i32; + const SPLINE = SWS_SPLINE as i32; + const SRC_V_CHR_DROP_MASK = SWS_SRC_V_CHR_DROP_MASK as i32; + const SRC_V_CHR_DROP_SHIFT = SWS_SRC_V_CHR_DROP_SHIFT as i32; + const PARAM_DEFAULT = SWS_PARAM_DEFAULT as i32; + const PRINT_INFO = SWS_PRINT_INFO as i32; + const FULL_CHR_H_INT = SWS_FULL_CHR_H_INT as i32; + const FULL_CHR_H_INP = SWS_FULL_CHR_H_INP as i32; + const DIRECT_BGR = SWS_DIRECT_BGR as i32; + const ACCURATE_RND = SWS_ACCURATE_RND as i32; + const BITEXACT = SWS_BITEXACT as i32; + const ERROR_DIFFUSION = SWS_ERROR_DIFFUSION as i32; } }