mirror of
https://github.com/gfx-rs/wgpu.git
synced 2026-04-22 03:02:01 -04:00
[Metal] Make constant composites non-constexpr (#707)
* Make constant composites non-constexpr * Update shadow test
This commit is contained in:
@@ -1531,7 +1531,7 @@ impl<W: Write> Writer<W> {
|
||||
access: crate::StorageAccess::empty(),
|
||||
first_time: false,
|
||||
};
|
||||
write!(self.out, "constexpr constant {} {} = {{", ty_name, name,)?;
|
||||
write!(self.out, "constant {} {} = {{", ty_name, name,)?;
|
||||
for (i, &sub_handle) in components.iter().enumerate() {
|
||||
let separator = if i != 0 { ", " } else { "" };
|
||||
let coco = ConstantContext {
|
||||
|
||||
@@ -18,7 +18,7 @@ typedef Light type3[1];
|
||||
struct Lights {
|
||||
type3 data;
|
||||
};
|
||||
constexpr constant metal::float3 c_ambient = {0.05, 0.05, 0.05};
|
||||
constant metal::float3 c_ambient = {0.05, 0.05, 0.05};
|
||||
|
||||
float fetch_shadow(
|
||||
metal::uint light_id,
|
||||
|
||||
Reference in New Issue
Block a user