Skip to content

Conversation

@zmerp
Copy link
Member

@zmerp zmerp commented Aug 11, 2025

Tested and working on Quest3/Windows

Apparently wgpu v26 has broken pipeline overrides support

The other dependencies will be updated in another PR

@zmerp zmerp enabled auto-merge August 11, 2025 15:08
Comment on lines 7 to 11
override ENABLE_SRGB_CORRECTION: f32;
override ENCODING_GAMMA: f32;

override ENABLE_UPSCALING: bool = false;
override UPSCALE_USE_EDGE_DIRECTION: bool = true;
override UPSCALE_EDGE_THRESHOLD: f32 = 4.0/255.0;
override ENABLE_UPSCALING: f32 = 0.0;
override UPSCALE_USE_EDGE_DIRECTION: f32 = 1.0;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think these should be changed from being bools. Reading the docs it should be entirely fine to have these as bools whilst the data type given to wgpu is an f64 and it's 100% correct because all possible data types (especially bools) can be represented losslessly by f64s. Or did something start complaining??

Either way changing these from bools makes it really hacky, I really don't like it.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah i don't like it either. That was the only solution i found to fix the validation errors. Maybe something is broken inside wgpu

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you give me any info about the validation errors?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is by changing one of the ENABLE_* flags back to bool:

08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]: ALVR panicked: What happened:
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]: panicked at /Users/ric/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/wgpu-hal-26.0.4/src/gles/queue.rs:1824:26:
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]: Unsupported uniform datatype: Scalar(Scalar { kind: Bool, width: 1 })!
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]: 
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]: Backtrace:
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:    0: alvr_common::logging::set_panic_hook::{{closure}}
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/MEGAsync/Ubuntu/vr/ALVR/alvr/common/src/logging.rs:191:13
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:    1: <alloc::boxed::Box<F,A> as core::ops::function::Fn<Args>>::call
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /rustc/29483883eed69d5fb4db01964cdf2af4d86e9cb2/library/alloc/src/boxed.rs:1980:9
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:       std::panicking::rust_panic_with_hook
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /rustc/29483883eed69d5fb4db01964cdf2af4d86e9cb2/library/std/src/panicking.rs:841:13
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:    2: std::panicking::begin_panic_handler::{{closure}}
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /rustc/29483883eed69d5fb4db01964cdf2af4d86e9cb2/library/std/src/panicking.rs:706:13
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:    3: std::sys::backtrace::__rust_end_short_backtrace
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /rustc/29483883eed69d5fb4db01964cdf2af4d86e9cb2/library/std/src/sys/backtrace.rs:168:18
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:    4: __rustc::rust_begin_unwind
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /rustc/29483883eed69d5fb4db01964cdf2af4d86e9cb2/library/std/src/panicking.rs:697:5
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:    5: core::panicking::panic_fmt
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /rustc/29483883eed69d5fb4db01964cdf2af4d86e9cb2/library/core/src/panicking.rs:75:14
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:    6: wgpu_hal::gles::queue::<impl wgpu_hal::gles::Queue>::process
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/wgpu-hal-26.0.4/src/gles/queue.rs:1824:26
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:    7: wgpu_hal::gles::queue::<impl wgpu_hal::Queue for wgpu_hal::gles::Queue>::submit
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/wgpu-hal-26.0.4/src/gles/queue.rs:1873:31
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:    8: <Q as wgpu_hal::dynamic::queue::DynQueue>::submit
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/wgpu-hal-26.0.4/src/dynamic/queue.rs:41:18
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:    9: wgpu_core::device::queue::Queue::submit
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/wgpu-core-26.0.1/src/device/queue.rs:1366:32
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   10: wgpu_core::device::queue::<impl wgpu_core::global::Global>::queue_submit
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/wgpu-core-26.0.1/src/device/queue.rs:1651:15
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   11: <wgpu::backend::wgpu_core::CoreQueue as wgpu::dispatch::QueueInterface>::submit
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/wgpu-26.0.1/src/backend/wgpu_core.rs:1848:42
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   12: wgpu::api::queue::Queue::submit
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/wgpu-26.0.1/src/api/queue.rs:253:32
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   13: alvr_graphics::stream::StreamRenderer::render
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/MEGAsync/Ubuntu/vr/ALVR/alvr/graphics/src/stream.rs:335:28
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   14: alvr_client_openxr::stream::StreamContext::render
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/MEGAsync/Ubuntu/vr/ALVR/alvr/client_openxr/src/stream.rs:420:23
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   15: alvr_client_openxr::entry_point
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/MEGAsync/Ubuntu/vr/ALVR/alvr/client_openxr/src/lib.rs:493:24
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   16: alvr_client_openxr::android_main::{{closure}}
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/MEGAsync/Ubuntu/vr/ALVR/alvr/client_openxr/src/lib.rs:551:9
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   17: std::sys::backtrace::__rust_begin_short_backtrace
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/src/rust/library/std/src/sys/backtrace.rs:152:18
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   18: std::thread::Builder::spawn_unchecked_::{{closure}}::{{closure}}
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/src/rust/library/std/src/thread/mod.rs:559:17
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   19: <core::panic::unwind_safe::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/src/rust/library/core/src/panic/unwind_safe.rs:272:9
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   20: std::panicking::catch_unwind::do_call
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/src/rust/library/std/src/panicking.rs:589:40
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   21: __rust_try
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   22: std::panicking::catch_unwind
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/src/rust/library/std/src/panicking.rs:552:19
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:       std::panic::catch_unwind
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/src/rust/library/std/src/panic.rs:359:14
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:       std::thread::Builder::spawn_unchecked_::{{closure}}
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/src/rust/library/std/src/thread/mod.rs:557:30
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   23: core::ops::function::FnOnce::call_once{{vtable.shim}}
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /Users/ric/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/src/rust/library/core/src/ops/function.rs:250:5
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   24: <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /rustc/29483883eed69d5fb4db01964cdf2af4d86e9cb2/library/alloc/src/boxed.rs:1966:9
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:       std::sys::pal::unix::thread::Thread::new::thread_start
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:              at /rustc/29483883eed69d5fb4db01964cdf2af4d86e9cb2/library/std/src/sys/pal/unix/thread.rs:107:17
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   25: _ZL15__pthread_startPv
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]:   26: __start_thread
08-15 03:58:31.488 12806 12833 E [ALVR NATIVE-RUST]: 

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The panic happens while executing the pipeline, otherwise the shader compilation doesn't flag using bool pipeline constants as invalid

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For some insane reason overrides get interpreted as push constants or at least taken up in the push constant table even if not updated (but then because of layout they still get touched or sth). This feels like a kinda bad bug to me and I'm not really comfortable updating into a known bug.

I'll file an issue with wgpu and we'll see if they can come up with a fix quickly.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alright. I'll check if it's v25 or v26 that introduces the bug

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just tested and I can say this happens in wgpu 26 but not 25

@zmerp zmerp changed the title refactor(graphics): ⬆️ Update wgpu refactor(graphics): ⬆️ Update wgpu to v25 Aug 15, 2025
@zmerp
Copy link
Member Author

zmerp commented Aug 15, 2025

I'd say to merge this, upgrading to wgpu v25. We'll get the fix for v26 whenever a patch to wgpu is released

@zmerp zmerp added this pull request to the merge queue Aug 17, 2025
Merged via the queue into master with commit 7589bb7 Aug 17, 2025
9 checks passed
@zmerp zmerp deleted the update-wgpu branch August 17, 2025 15:49
Jimmy32767255 added a commit to Jimmy32767255/ALVR-CN that referenced this pull request Aug 28, 2025
commit f14fbfc
Author: zmerp <merp.zee@gmail.com>
Date:   Tue Aug 26 09:09:46 2025 +1000

    refactor: :arrow_up: Update dependencies (alvr-org#2986)

commit 452452e
Author: zmerp <merp.zee@gmail.com>
Date:   Thu Aug 21 17:12:56 2025 +1000

    refactor(common): ♻️ Move popup logic out of alvr_common (alvr-org#2987)

commit c3ec94b
Author: zmerp <merp.zee@gmail.com>
Date:   Tue Aug 19 06:39:27 2025 +1000

    fix(server_core): :bug: Fix locked webserver during client handshake (alvr-org#2988)

commit 7589bb7
Author: zmerp <merp.zee@gmail.com>
Date:   Mon Aug 18 00:32:25 2025 +1000

    refactor(graphics): ⬆️ Update wgpu tp v25 (alvr-org#2982)

commit 343618b
Author: zmerp <merp.zee@gmail.com>
Date:   Wed Aug 13 03:05:49 2025 +1000

    feat(dashboard): :sparkles: Add "Clear all" button in Logs tab (alvr-org#2983)

commit f0c0516
Author: Leonhard Saam <54042101+The-personified-devil@users.noreply.github.com>
Date:   Sun Aug 10 04:05:40 2025 +0200

    ci: fully fix merge queues (alvr-org#2980)

    - disable the checks on push as the merge queue ones do their job fully

commit 93c5b43
Author: Leonhard Saam <54042101+The-personified-devil@users.noreply.github.com>
Date:   Sat Aug 9 16:46:45 2025 +0200

    ci: fix merge-queue actions (alvr-org#2978)

commit 12e6589
Author: Leonhard Saam <54042101+The-personified-devil@users.noreply.github.com>
Date:   Fri Aug 8 15:18:43 2025 +0200

    fix: bump cpal+rodio, fix os error 11 timeout (alvr-org#2944)

    - fix cpal device enumeration being extremely slow on v0.15
    - actually respect virtual audio cable search ordering
    - don't store is_output property
    - compare devices based on id
    - remove AudioDevice struct

commit 5d017a1
Author: Leonhard Saam <54042101+The-personified-devil@users.noreply.github.com>
Date:   Fri Aug 8 15:16:04 2025 +0200

    ci: make rarely triggering checks run on merge queue only (alvr-org#2973)

commit a211bad
Author: zmerp <merp.zee@gmail.com>
Date:   Fri Aug 8 03:33:32 2025 +0200

    refactor: :rotating_light: Fix Rust v1.89 lints (alvr-org#2972)

commit 7757a8b
Author: micsthepick <11528421+micsthepick@users.noreply.github.com>
Date:   Wed Aug 6 11:00:21 2025 +1000

    fix client stream.wgsl shader (alvr-org#2962)

commit 33a90ab
Author: Meister1593 <leruop@Gmail.com>
Date:   Sat Aug 2 02:43:58 2025 +0000

    fix (dashboard): Fix incorrect AV1 gpu in note alvr-org#2331, add more information about headsets (alvr-org#2949)

commit ec947a0
Author: zmerp <merp.zee@gmail.com>
Date:   Fri Aug 1 17:30:14 2025 +0200

    fix(xtask): :pushpin: Pin cargo-ndk to previous version (alvr-org#2954)

commit a67c4e3
Author: zmerp <merp.zee@gmail.com>
Date:   Thu Jul 31 23:24:52 2025 +0200

    Protocol cleanup (8): binary protocol refactoring (alvr-org#2932)

commit 6db106f
Author: zmerp <merp.zee@gmail.com>
Date:   Tue Jul 22 19:14:15 2025 +0200

    fix(dashboard): :bug: Fix unexpected version popup (alvr-org#2929)

commit 94ea7db
Author: zmerp <merp.zee@gmail.com>
Date:   Tue Jul 22 15:52:38 2025 +0200

    Protocol cleanup (7): Reserved to normal packet variants (alvr-org#2915)

commit 1fb60d1
Author: Meister1593 <leruop@Gmail.com>
Date:   Sat Jul 19 20:20:46 2025 +0000

    Pipewire implementation refactor (alvr-org#2902)

    * refactor(linux,audio): Refactor pipewire audio, exit early if pipewire is not found and inform user

    * refactor(linux,audio): simplify logic, add check for pipewire before starting receiving or sending data

    * refactor(linux,audio): leftover small refactors, remove clippy macros

    * refactor(linux,audio): add flatpak note, try initing more pipewire functions to trigger error, moved try pipewire earlier to abort all audio processing early

    * refactor(linux,audio,flatpak) Added check for pipewire early in dashboard launch, reformatting output

    * refactor(linux,audio): reduce nesting

    * revert unnecessary change

    * remove unnecessary nesting

    * reformat string

    * reformat string

    * clippy, format, macos fixes

    * clippy linux gate fixes

    * chore: Refactor pipewire impl some more

    * Address review comments; simplify pw flatpak check

    * fix: fix bug in pw playback + speed up buffer filling

    * reverse pw socket check

    * add check for pipewire being a socket or an empty file

    * light refactor to simplify

    * address comments in pr: invert logic for socket check again and simplify code, add comment related to state changes in pipewire causing cut out

    * format fix

    * fix typo

    ---------

    Co-authored-by: Leonhard Saam <leonhard.saam@yahoo.com>

commit 222ae53
Author: Dagg <dagg@kyzune.com>
Date:   Mon Jul 14 23:33:37 2025 -0700

    Implement high fidelity IOBT (XR_META_body_tracking_fidelity) for Quest 3 (alvr-org#2917)

    * Sync Files

    * Implement xrRequestBodyTrackingFidelityMETA

    * Formatting

    * Fix warnings

    * Removed maxenum value
    Probably not necessary now that i think about it

    * Cleanup and renaming

    * Add config option

    * Fix formatting

    * Explicitly set fidelity mode based on config value, don't bail on mode set fail.

    * Swap closure for if let, and_then

    * Bail if request method is missing, force Ok from mode set.

    ---------

    Co-authored-by: GitHub Action <action@github.com>

commit 80796e2
Author: Riccardo Zaglia <riccardo.zaglia5@gmail.com>
Date:   Tue Jul 15 02:19:14 2025 +1000

    fix(ci): :green_heart: Fix CI release workflow

commit 8c72354
Author: zmerp <merp.zee@gmail.com>
Date:   Sun Jul 13 16:51:54 2025 +0200

    fix(dashboard): :bug: Remove devices from Headset speaker dropdown (alvr-org#2918)

commit 8c0a815
Author: zmerp <merp.zee@gmail.com>
Date:   Fri Jul 11 15:54:48 2025 +0200

    Protocol cleanup (6) (alvr-org#2912)

    * Protocol cleanup (6)

    * Don't impl Default for BodyTrackingBDConfig

commit 6fa03e9
Author: zmerp <merp.zee@gmail.com>
Date:   Fri Jul 11 06:32:06 2025 +0200

    fix(audio): :bug: Fix input/output audio device handling (alvr-org#2911)

commit 4e08e0e
Author: zmerp <merp.zee@gmail.com>
Date:   Thu Jul 10 20:39:05 2025 +0200

    Protocol cleanup (5) (alvr-org#2907)

# Conflicts:
#	alvr/dashboard/src/dashboard/components/settings_controls/presets/builtin_schema.rs   resolved by origin/master(远端) version
#	alvr/session/src/settings.rs   resolved by origin/master(远端) version
#	wiki/Installation-guide.md   resolved by origin/master(远端) version
#	wiki/Installing-ALVR-and-using-SteamVR-on-Linux-through-Flatpak.md   resolved by origin/master(远端) version
#	wiki/Other-resources.md   resolved by origin/master(远端) version
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants