mirror of
https://github.com/gfx-rs/wgpu.git
synced 2026-04-22 03:02:01 -04:00
* Add function calling support to wgsl frontend * Fix external namespace with multiple namespaces * changes after code review * Don't re-tokenize std_namespace every time
12 lines
253 B
WebGPU Shading Language
12 lines
253 B
WebGPU Shading Language
import "GLSL.std.450" as std::glsl;
|
|
|
|
fn test_function(test: f32) -> f32 {
|
|
return test;
|
|
}
|
|
|
|
fn main_vert() -> void {
|
|
var foo: f32 = std::glsl::distance(0.0, 1.0);
|
|
var test: f32 = test_function(1.0);
|
|
}
|
|
|
|
entry_point vertex as "main" = main_vert; |