| Crates.io | jit-spirv |
| lib.rs | jit-spirv |
| version | 0.1.1 |
| created_at | 2023-05-13 08:41:35.105552+00 |
| updated_at | 2023-05-14 05:39:06.459606+00 |
| description | Compile GLSL/HLSL/WGSL to SPIR-V just-in-time with a simple macro. |
| homepage | https://github.com/PENGUINLIONG/inline-spirv-rs |
| repository | https://github.com/PENGUINLIONG/inline-spirv-rs |
| max_upload_size | |
| id | 863627 |
| size | 16,410 |
jit-spirv helps you integrate SPIR-V shader compilers into your project with minimal amount of code.
To compile a runtime shader source just-in-time:
use jit_spirv::{jit_spirv, CompilationFeedback};
let glsl_source = r#"
#version 450
layout(binding=0) writeonly buffer _0 { float data[]; };
void main() {
data[gl_GlobalInvocationID.x] = 1.0;
}
"#;
let feedback: CompilationFeedback = jit_spirv!(glsl_source, comp).unwrap();
let spv: &[u32] = &feedback.spv;
For the full list of options please refer to the documentation of inline-spirv.
This project is licensed under either of
at your option.