From e95f6d632c1de299d8b0146baba5b7672edf52cc Mon Sep 17 00:00:00 2001 From: minus1ms <75856137+minus1ms@users.noreply.github.com> Date: Mon, 24 Feb 2025 06:48:06 -0800 Subject: [PATCH] binding size fix (#7177) --- wgpu-hal/src/auxil/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wgpu-hal/src/auxil/mod.rs b/wgpu-hal/src/auxil/mod.rs index f77aeeddaf..9e06b5e708 100644 --- a/wgpu-hal/src/auxil/mod.rs +++ b/wgpu-hal/src/auxil/mod.rs @@ -53,7 +53,7 @@ pub mod db { /// Interestingly, the index itself can't reach that high, because the minimum /// element size is 4 bytes, but the compiler toolchain still computes the /// offset at some intermediate point, internally, as i32. -pub const MAX_I32_BINDING_SIZE: u32 = 1 << 31; +pub const MAX_I32_BINDING_SIZE: u32 = (1 << 31) - 1; pub fn map_naga_stage(stage: naga::ShaderStage) -> wgt::ShaderStages { match stage {