mirror of
https://github.com/vulkano-rs/vulkano.git
synced 2024-11-21 14:24:18 +00:00
Up vk version in shader compilation (#2467)
* Up vk version in shader compilation * Update test in codegen.rs * cargo +nightly fmt * Update lib.rs * clippy + fmt fixes * simplify changes * post merge
This commit is contained in:
parent
3959fb5135
commit
3bb1f125df
@ -262,6 +262,7 @@ pub(super) fn reflect(
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
use shaderc::SpirvVersion;
|
||||
use vulkano::shader::reflect;
|
||||
|
||||
fn convert_paths(root_path: &Path, paths: &[PathBuf]) -> Vec<String> {
|
||||
@ -579,11 +580,15 @@ mod tests {
|
||||
#[test]
|
||||
fn descriptor_calculation_with_multiple_functions() {
|
||||
let (comp, _) = compile(
|
||||
&MacroInput::empty(),
|
||||
&MacroInput {
|
||||
spirv_version: Some(SpirvVersion::V1_6),
|
||||
vulkan_version: Some(EnvVersion::Vulkan1_3),
|
||||
..MacroInput::empty()
|
||||
},
|
||||
None,
|
||||
Path::new(""),
|
||||
r#"
|
||||
#version 450
|
||||
#version 460
|
||||
|
||||
layout(set = 1, binding = 0) buffer Buffer {
|
||||
vec3 data;
|
||||
|
@ -618,7 +618,8 @@ impl Parse for MacroInput {
|
||||
"1.0" => EnvVersion::Vulkan1_0,
|
||||
"1.1" => EnvVersion::Vulkan1_1,
|
||||
"1.2" => EnvVersion::Vulkan1_2,
|
||||
ver => bail!(lit, "expected `1.0`, `1.1` or `1.2`, found `{ver}`"),
|
||||
"1.3" => EnvVersion::Vulkan1_3,
|
||||
ver => bail!(lit, "expected `1.0`, `1.1`, `1.2` or `1.3`, found `{ver}`"),
|
||||
});
|
||||
}
|
||||
"spirv_version" => {
|
||||
|
Loading…
Reference in New Issue
Block a user