mirror of
https://github.com/storytold/wgpu.git
synced 2026-11-29 09:34:09 +01:00
Add metallib passthrough (#8886)
This commit is contained in:
1 parent
1af73121f4
commit
fab57513ec
26 files changed
+891
-154
No files matched your search
+4
-4
@@ -268,10 +268,8 @@ impl Player {
|
||||
Action::CreateShaderModulePassthrough {
|
||||
id,
|
||||
data,
|
||||
entry_point,
|
||||
label,
|
||||
num_workgroups,
|
||||
runtime_checks,
|
||||
} => {
|
||||
let spirv = data.iter().find_map(|a| {
|
||||
if a.kind() == DataKind::Spv {
|
||||
@@ -289,6 +287,9 @@ impl Player {
|
||||
let hlsl = data
|
||||
.iter()
|
||||
.find_map(|a| (a.kind() == DataKind::Hlsl).then(|| loader.load_utf8(a)));
|
||||
let metallib = data
|
||||
.iter()
|
||||
.find_map(|a| (a.kind() == DataKind::MetalLib).then(|| loader.load(a)));
|
||||
let msl = data
|
||||
.iter()
|
||||
.find_map(|a| (a.kind() == DataKind::Msl).then(|| loader.load_utf8(a)));
|
||||
@@ -299,14 +300,13 @@ impl Player {
|
||||
.iter()
|
||||
.find_map(|a| (a.kind() == DataKind::Wgsl).then(|| loader.load_utf8(a)));
|
||||
let desc = wgt::CreateShaderModuleDescriptorPassthrough {
|
||||
entry_point,
|
||||
label,
|
||||
num_workgroups,
|
||||
runtime_checks,
|
||||
|
||||
spirv,
|
||||
dxil,
|
||||
hlsl,
|
||||
metallib,
|
||||
msl,
|
||||
glsl,
|
||||
wgsl,
|
||||
|
||||
Reference in new issue
Block a user