mirror of
https://github.com/storytold/wgpu.git
synced 2026-11-24 08:21:25 +01:00
Fix WGSL variable storage classes, spv-out interface
This commit is contained in:
1 parent
211bec44a1
commit
2d1006835a
2 files changed
+16
-6
No files matched your search
+10
-1
@@ -1960,7 +1960,16 @@ impl Parser {
|
||||
crate::BuiltIn::Position => crate::StorageClass::Output,
|
||||
_ => unimplemented!(),
|
||||
},
|
||||
_ => crate::StorageClass::Handle,
|
||||
Some(crate::Binding::Resource { .. }) => {
|
||||
match module.types[pvar.ty].inner {
|
||||
crate::TypeInner::Struct { .. } if pvar.access.is_empty() => {
|
||||
crate::StorageClass::Uniform
|
||||
}
|
||||
crate::TypeInner::Struct { .. } => crate::StorageClass::Storage,
|
||||
_ => crate::StorageClass::Handle,
|
||||
}
|
||||
}
|
||||
_ => crate::StorageClass::Private,
|
||||
},
|
||||
};
|
||||
let var_handle = module.global_variables.append(crate::GlobalVariable {
|
||||
|
||||
Reference in new issue
Block a user